Reputation: 861
How to check whether debugger of Python Tools for Visual Studio 2010 is attached to current process?
IsDebuggerPresent
and CheckRemoteDebuggerPresent
functions are not working, yet Visual Studio 2008 is able to say that it is already being debugged. Does VS2008 use some DTE methods to achieve that (enumerate running versions of VS, old and future(???) versions included, and check whether it is debugged already...?) or it is uses some other way I can use inside my application?
Note: As it turns out, WinDbg allows attachment to this process, so if you need a simultaneous debugging of C++ and Python you can try it out until this issue is resolved.
Upvotes: 4
Views: 1305
Reputation: 701
Weren't you asking the same question as the one here: How do I check if the python debug option is set from within a script ? The sys.flags.debug
suggested there worked for me.
Sadly, I don't know much more about the internals of debugging the Cpython interpreter. And I only guess you used that one, with ctypes
, probably.
Upvotes: 1