Tuesday, 22 August 2023

gdb python in pyenv virtualenv

I am working inside a pyenv-managed virtualenv

$ which python
/Users/theonlygusti/.pyenv/shims/python

/Users/theonlygusti/.pyenv/shims/python is a shell script and gdb doesn't work

"0x7ffeeb614570s": not in executable format: file format not recognized

How can I use gdb on a python script like here https://stackoverflow.com/a/2664232/3310334 to debug my C extension's segfault?

https://stackoverflow.com/a/53007303/3310334 suggests gdb -ex r --args bash python crash.py, but it doesn't work, same error

"0x7ffee0aa4530s": not in executable format: file format not recognized


from gdb python in pyenv virtualenv

No comments:

Post a Comment