Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recursion error on getone #255

Closed
Tracked by #249
sirex opened this issue May 24, 2022 · 0 comments · Fixed by #322
Closed
Tracked by #249

Recursion error on getone #255

sirex opened this issue May 24, 2022 · 0 comments · Fixed by #322
Assignees
Labels
bug Something isn't working

Comments

@sirex
Copy link
Collaborator

sirex commented May 24, 2022

Example: https://get.data.gov.lt/datasets/gov/lsd/cl/evrk/EkonominesVeiklosRusis/aec9b4d0-20ca-41a5-a473-a783243bb8f4

Found this error in logs:

Traceback (most recent call last):
  File "spinta/api.py", line 91, in homepage
    return await create_http_response(context, params, request)
  File "spinta/utils/response.py", line 141, in create_http_response
    return await commands.getone(context, request, model, backend, action=action, params=params)
  File "spinta/backends/postgresql/commands/read.py", line 54, in getone
    return render(context, request, model, params, data, action=action)
  File "spinta/renderer.py", line 22, in render
    return commands.render(
  File "spinta/formats/html/commands.py", line 136, in render
    return _render_model(context, request, model, action, params, data, headers)
  File "spinta/formats/html/commands.py", line 240, in _render_model
    ctx = _build_template_context(
  File "spinta/formats/html/commands.py", line 215, in _build_template_context
    header = _get_model_tabular_header(context, model, action, params)
  File "spinta/formats/html/commands.py", line 196, in _get_model_tabular_header
    return get_model_tabular_header(
  File "spinta/formats/helpers.py", line 114, in get_model_tabular_header
    header = list(_get_model_header(model, names, select, reserved))
  File "spinta/formats/helpers.py", line 76, in _get_model_header
    yield from _get_dtype_header(prop.dtype, sel, prop.name)
  File "spinta/formats/helpers.py", line 57, in _get_dtype_header
    yield from _get_dtype_header(prop.dtype, sel, name_)
  File "spinta/formats/helpers.py", line 57, in _get_dtype_header
    yield from _get_dtype_header(prop.dtype, sel, name_)
  File "spinta/formats/helpers.py", line 57, in _get_dtype_header
    yield from _get_dtype_header(prop.dtype, sel, name_)
  [Previous line repeated 960 more times]
  File "spinta/formats/helpers.py", line 50, in _get_dtype_header
    for prop, sel in select_only_props(
  File "spinta/backends/helpers.py", line 170, in select_only_props
    for key, sel in select_only_keys(keys, select, reserved=reserved):
RecursionError: maximum recursion depth exceeded
@sirex sirex added the bug Something isn't working label May 24, 2022
@sirex sirex moved this to Todo in Portalo plėtra May 24, 2022
@sirex sirex removed the status in Portalo plėtra Jun 7, 2022
@sirex sirex moved this to Todo in Portalo plėtra Jun 8, 2022
@sirex sirex removed the status in Portalo plėtra Jun 8, 2022
@sirex sirex removed this from Portalo plėtra Nov 11, 2022
@sirex sirex added this to Palaikymas Nov 11, 2022
@sirex sirex moved this to In Progress in Palaikymas Nov 12, 2022
@sirex sirex self-assigned this Nov 12, 2022
@sirex sirex linked a pull request Nov 12, 2022 that will close this issue
Repository owner moved this from In Progress to Done in Palaikymas Nov 12, 2022
@sirex sirex linked a pull request Nov 12, 2022 that will close this issue
@sirex sirex removed a link to a pull request Nov 12, 2022
@sirex sirex removed this from Palaikymas Mar 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant