dash icon indicating copy to clipboard operation
dash copied to clipboard

[BUG] Unable to run werkzeug profiler on python 3.12

Open Farkites opened this issue 10 months ago • 1 comments

Describe your context

I'm following the instructions posted in this Community forum blog post to run werkzeug profiler in my Dash application to identify performance bottlenecks.

It doesn't work with python version 3.12, receiving error:ValueError: Another profiling tool is already active. I'm not running any other profiler in the application and I've tried disabling Linux profiler (python app.py -X perf 0) It works fine with python <=3.11

  • pip list | grep dash:
dash                    2.18.0
dash-core-components    2.0.0
dash-html-components    2.0.0
dash-iconify            0.1.2
dash-table              5.0.0

Describe the bug

I receiving the error ValueError: Another profiling tool is already active when running the application with python version 3.12.

Expected behavior

It should work as it does with python<=3.11

Farkites avatar Jan 31 '25 11:01 Farkites

This issue would need to be fixed upstream in Werkzeug (https://github.com/pallets/werkzeug/issues/2909 ) or cpython (https://github.com/python/cpython/issues/110770 ). As in both cases it's not planned, we might consider updating our recommendations for profiling instead of trying to change anything in core Dash.

ndrezn avatar Jan 31 '25 13:01 ndrezn