[Pydev-users] [Users] Alternate approach to debugging OmniORB-Py
Brought to you by:
fabioz
From: SourceForge.net <no...@so...> - 2012-01-09 22:44:15
|
The following forum message was posted by mikeihde at http://sourceforge.net/projects/pydev/forums/forum/293649/topic/4937755: On the PyDev FAQ there is an approach for debugging OmniORB-Py programs. One downside is that it requires modification to the program that is being debugged. As an alternative, I tried this and it seemed to work [code] class PyDB: ... def omniorb_trace(self, flag=0, wt=None): if flag == 0: pydevd_tracing.SetTrace(self.trace_dispatch) def run(self, file, globals=None, locals=None): ... try: threading.settrace(self.trace_dispatch) except: pass # Hack for omniORB try: from omniORB import addWThreadHook except ImportError: pass else: addWThreadHook(self.dbg_trace) ... [/code] The benefit of this approach is that only pydevd.py needs to be modified. In my testing this seems to work correctly, but I have a few questions: 1. Is there anything that might catch me that I'm not aware of currently? 2. Is there any possibility that this would be incorporated into pydevd.py so that users wouldn't have to make the modifications themselves? Thanks, ~Michael |