I'm using uWSGI with the "--profiler" flag switched on but I can't seem to find the output file (if there is one), and (like many things in uWSGI) this isn't properly documented.
Where does uWSGI put its profiler file?
2.1k Views Asked by itzhaki At
2
There are 2 best solutions below
0

I just got this problem today. Here is a good project, you can use: https://github.com/what-studio/profiling
I used it from my code, like this:
from profiling.tracing import TracingProfiler
profiler = TracingProfiler()
profiler.start()
# ... run your program...
profiler.stop()
# save profile data to file
profiler.dump('path/to/file')
A useful trick is to use uWSGIs logger to filter out the profiler logs into their own file: