View Single Post
Old 08-20-2014, 01:54 PM   #10
auspex
Addict
auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.auspex ought to be getting tired of karma fortunes by now.
 
auspex's Avatar
 
Posts: 201
Karma: 1071756
Join Date: Sep 2012
Location: Nova Scotia
Device: Kobo Aura, Nexus 5x
I really didn't think this could be too difficult.

The way I've done it is no doubt not the best way (I'm forgetting how to force python to pick up an additional library for PYTHONPATH [ETA: no I'm not, it's just that calibre ignores PYTHONPATH in your environment!]), but instead of just:
Code:
import pydevd;pydevd.settrace()
I use:
Code:
if '/opt/eclipse-4.3/plugins/org.python.pydev_2.7.0.2013032300/pysrc' not in sys.path:
    sys.path.append('/opt/eclipse-4.3/plugins/org.python.pydev_2.7.0.2013032300/pysrc')
import pydevd;pydevd.settrace()
Obviously, your path to pydev is probably different.

Remember to start the external debugger in Eclipse before starting calibre.
auspex is offline   Reply With Quote