py-spy icon indicating copy to clipboard operation
py-spy copied to clipboard

analyze dump

Open whyzdev opened this issue 7 years ago • 2 comments

As mentioned in the case #40, please consider add a feature to allow py-spy analyze dump files. Rather than use --pid pid or run live target process, add an argument for loading windows dump or core dump on linux/mac. Thanks!

whyzdev avatar Sep 20 '18 11:09 whyzdev

this could be useful, but will only let you get a single stack trace (like the output you get from passing --dump on the command line) instead of something like flamegraphs.

fwiw, rbspy does testing like this - it grabs some core dumps and verifies that it can extract the correct stack trace from them, which is a pretty neat way of testing.

benfred avatar Sep 20 '18 18:09 benfred

i think this would be useful. i've been thinking about using py-spy to create a thread stack dump tool,but it was a little unclear if that fit into the goals of py-spy.

kapilt avatar Sep 21 '18 02:09 kapilt

Ability to do this with Linux has been added with https://github.com/benfred/py-spy/pull/538 -

benfred avatar Feb 12 '23 00:02 benfred