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
This issue is related to, but not the same as #110770.
Running two profilers in parallel threads raises an unexpected error.
It's not clear at all that the profiler will not work in parallel.
Either this is a bug or there should be a prominent warning in the docs.
This was a new behavior for 3.12, but even before 3.12, this code would not "work" - it wouldn't raise an error either. Anyway, I believe we should document it somewhere in cProfile's doc. @AA-Turner is great with the docs so I'll leave the review to him.
Activity
ZeroIntensity commentedon Sep 27, 2024
Yeah, you can't use multiple profilers at once. This is sort of documented, see sys.monitoring.use_tool_id:
I guess it's not explicitly mentioned in the
cProfiledocumentation, though.AA-Turner commentedon Sep 27, 2024
Recategorising as a documentation problem, a PR is welcome.
A
gaogaotiantian commentedon Sep 27, 2024
This was a new behavior for 3.12, but even before 3.12, this code would not "work" - it wouldn't raise an error either. Anyway, I believe we should document it somewhere in cProfile's doc. @AA-Turner is great with the docs so I'll leave the review to him.