You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In python 3.12 sometimes this exception raises, usually immediately after the server starts in the first request. SILKY_PYTHON_PROFILER = False seems to fix it.
File "/backend/python/lib/python3.12/site-packages/django/core/handlers/exception.py", line 55, in inner
response = get_response(request)
File "/backend/python/lib/python3.12/site-packages/silk/middleware.py", line 70, in __call__
self.process_request(request)
File "/backend/python/lib/python3.12/site-packages/silk/middleware.py", line 121, in process_request
DataCollector().configure(request_model, should_profile=should_profile)
File "/backend/python/lib/python3.12/site-packages/silk/collector.py", line 95, in configure
self.local.pythonprofiler.enable()
ValueError: Another profiling tool is already active
The text was updated successfully, but these errors were encountered:
Elendiar
changed the title
Python 3.12: ValueError: Another profiling tool is already active
[Python 3.12] ValueError: Another profiling tool is already active
Oct 24, 2023
Adds a sort of profiling to this page by placing some timers in some key function where I think the slowdown happens. Why is it so hacky? I tried for several hours to use werkzeug's `ProfilerMiddleware` but I think there's a bug with the implementation, as several people have reported in some other tools: django-commons/django-debug-toolbar#1875, jazzband/django-silk#682
I thought that since we didn't need the full-fledged tool and didn't want to spend more time on this, this approach would suffice.
In python 3.12 sometimes this exception raises, usually immediately after the server starts in the first request.
SILKY_PYTHON_PROFILER = False
seems to fix it.python/cpython#110770 (comment)
The text was updated successfully, but these errors were encountered: