Skip to content

django.template:DEBUG Exception while resolving variable 'similar_count' in template 'debug_toolbar/panels/sql.html' #1374

@hnykda

Description

@hnykda

Hi,

I am facing a weird stacktrace when using debug_toolbar. Basically, when locally developing and using django_toolbar, for every request, I get a long stacktrace originating in base templates. It starts like this:

20201005 09:31:21:django.template:DEBUG Exception while resolving variable 'similar_count' in template 'debug_toolbar/panels/sql.html'.
Traceback (most recent call last):
  File "/usr/src/app/.venv/lib/python3.8/site-packages/django/template/base.py", line 829, in _resolve_lookup
    current = current[bit]
TypeError: 'SQLPanel' object is not subscriptable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/app/.venv/lib/python3.8/site-packages/django/template/base.py", line 829, in _resolve_lookup
    current = current[bit]
KeyError: 'similar_count'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/app/.venv/lib/python3.8/site-packages/django/template/base.py", line 837, in _resolve_lookup
    current = getattr(current, bit)
AttributeError: 'dict' object has no attribute 'similar_count'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/app/.venv/lib/python3.8/site-packages/django/template/base.py", line 843, in _resolve_lookup
    current = current[int(bit)]
ValueError: invalid literal for int() with base 10: 'similar_count'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/app/.venv/lib/python3.8/site-packages/django/template/base.py", line 848, in _resolve_lookup
    raise VariableDoesNotExist("Failed lookup for key "
django.template.base.VariableDoesNotExist: Failed lookup for key [similar_count] in 

and I don't really know where to start nor I am able to generate a minimal example. Can someone give me please some pointers what to try? Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy