TypeError at /core/config/ #9270

Closed
opened 2025-12-29 20:47:42 +01:00 by adam · 0 comments
Owner

Originally created by @francois-vincent on GitHub (Feb 19, 2024).

Originally assigned to: @arthanson on GitHub.

Deployment Type

Self-hosted

NetBox Version

3.7.3-dev

Python Version

3.10

Steps to Reproduce

git clone git@github.com:netbox-community/netbox.git
copy netbox/configuration_example.py netbox/configuration.py
basic editing of configuration.py (ALLOWED_HOSTS = ['*'], DEBBUG=True)
./manage.py collectstatic
./manage.py migrate
./manage.py createsuperuser
python manage.py runserver 0.0.0.0:8000 --insecure

then goto http://localhost:8000/core/config/ in a browser (firefox on ubuntu 20.04)

Expected Behavior

a netbox view

Observed Behavior

Traceback (most recent call last):
File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner
response = get_response(request)
File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/graphiql_debug_toolbar/middleware.py", line 70, in call
response = super().call(request)
File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/debug_toolbar/middleware.py", line 69, in call
panel.generate_stats(request, response)
File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/debug_toolbar/panels/templates/panel.py", line 196, in generate_stats
template_data["context_list"] = self.process_context_list(
File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/debug_toolbar/panels/templates/panel.py", line 137, in process_context_list
if hasattr(value, "_wrapped"):
File "/home/francois/Source/Python/netbox/netbox/core/models/config.py", line 47, in getattr
if item in self.data:

Exception Type: TypeError at /core/config/
Exception Value: argument of type 'Config' is not iterable

Originally created by @francois-vincent on GitHub (Feb 19, 2024). Originally assigned to: @arthanson on GitHub. ### Deployment Type Self-hosted ### NetBox Version 3.7.3-dev ### Python Version 3.10 ### Steps to Reproduce git clone git@github.com:netbox-community/netbox.git copy netbox/configuration_example.py netbox/configuration.py basic editing of configuration.py (ALLOWED_HOSTS = ['*'], DEBBUG=True) ./manage.py collectstatic ./manage.py migrate ./manage.py createsuperuser python manage.py runserver 0.0.0.0:8000 --insecure then goto http://localhost:8000/core/config/ in a browser (firefox on ubuntu 20.04) ### Expected Behavior a netbox view ### Observed Behavior Traceback (most recent call last): File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner response = get_response(request) File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/graphiql_debug_toolbar/middleware.py", line 70, in __call__ response = super().__call__(request) File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/debug_toolbar/middleware.py", line 69, in __call__ panel.generate_stats(request, response) File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/debug_toolbar/panels/templates/panel.py", line 196, in generate_stats template_data["context_list"] = self.process_context_list( File "/home/francois/.pyenv/versions/netbox/lib/python3.10/site-packages/debug_toolbar/panels/templates/panel.py", line 137, in process_context_list if hasattr(value, "_wrapped"): File "/home/francois/Source/Python/netbox/netbox/core/models/config.py", line 47, in __getattr__ if item in self.data: Exception Type: TypeError at /core/config/ Exception Value: argument of type 'Config' is not iterable
adam added the type: bugstatus: acceptedseverity: medium labels 2025-12-29 20:47:42 +01:00
adam closed this issue 2025-12-29 20:47:42 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#9270