Error setting a breakpoint when not using an editor (hook synchronize_with_editor)

Bug #401686 reported by schettino72
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
IPython
Fix Committed
Undecided
Unassigned

Bug Description

When I put a breakpoint in my application using:

        from IPython.Debugger import Tracer;
        Tracer()()

I get the following breakpoint:
...
 File "/usr/lib/python2.4/site-packages/ipython-0.9.1-py2.4.egg/IPython/Debugger.py", line 288, in interaction
    OldPdb.interaction(self, frame, traceback)
  File "pdb.py", line 157, in interaction
    self.print_stack_entry(self.stack[self.curindex])
  File "/usr/lib/python2.4/site-packages/ipython-0.9.1-py2.4.egg/IPython/Debugger.py", line 339, in print_stack_entry
    __IPYTHON__.hooks.synchronize_with_editor(filename, lineno, 0)
AttributeError: 'function' object has no attribute 'synchronize_with_editor'

I guess it can be easily fixed. You just need to check if "hooks" has the method "syncronize_with_editor".

Related branches

Revision history for this message
Fernando Perez (fdo.perez) wrote :

Fixed in the 0.10 branch, as best as I can see right now.

I should add though that things on this front have changed quite a bit for the 0.11 one, so I'm sure we have still some work to do there for robust use of the ipython debug facilities when embedded elsewhere.

Changed in ipython:
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.