Python crashes when debugging C++ Library through CLion since 2017
Hi,
I want to debug a C++ Library which is used by Python through CLion. I can build the lib from CLion, and prior to upgrading I could just press Debug to launch python and then run into my breakpoints in the C++ code. (I set the Run/Debug Configuration to launch the executable "/System/Frameworks/Python.framework/Versions/2.7/bin/python2.7" with the python parameters).
With the current version, Python just immediately crashes at the very beginning:
Crashed Thread: 0
Exception Type: EXC_CRASH (SIGTRAP)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
External Modification Warnings:
Debugger attached to process.
Thread 0 Crashed: 0 ??? 0x0000000117795000 _dyld_start + 0
and then the CLion debugging console just tells me
Terminated due to signal 5
Process finished with exit code 0
I am aware of the Python debugging support in CLion, but I dont care about the python code - I want my breakpoints in the C++ Library to be hit! (Which worked fine with the previous CLion)
any ideas? any steps I can take to debug this problem?
Cheers,
Martin
请先登录再写评论。
Does that happen if you run without a debugger (Run action)?
no, then it runs fine. sorry - forgot to mention that in the first place.
I have the same problem. I wrote a c++ package and expose it using pybind11. I would like to step through the python script and be able to dive into the c++ code while debugging. How do I do it? I am using CLion.2013.1.4
Ny2292000 please see this article - https://www.jetbrains.com/help/clion/debugging-python-extensions.html