Just started using the Plugin Debugger package and I'm excited about what it can do.
Unfortunately I'm encountering one fairly major snag so far, though -- when Winpdb stops at the "spdb.start() line" (which I've placed in my plugin), I'm not able to evaluate statements in Winpdb involving any kind of sublime function call.
For example, using the test plugin code at the end of this post, when Winpdb stops at spdb.start(), if I enter this into the Winpdb REPL:
then Winpdb waits a few seconds and comes back with:
The operation will continue to run in the background.
I presume this is because, while the plugin is paused, Sublime Text is also effectively blocked and can’t respond to anything?
If I allow Winpdb to continue execution, it will then evaluate these prior statements I’d entered and print results to the REPL. However, I feel this defeats the purpose a bit -- to effectively debug, ideally I'd see eval results while paused at the breakpoint.
Just wondering if anyone else has encountered a similar issue and, if so, if you might have discovered a workaround?
Using ST3 build 3142, Plugin Debugger 2014.04.19.16.30.06, Winpdb 1.4.8 (connected to an Anaconda Python 2.7 environment), Windows 10.
Here's the test plugin for the above example:
import os, sys import sublime, sublime_plugin class debugTestCommand(sublime_plugin.WindowCommand): # Constructor def __init__(self, window): sublime_plugin.WindowCommand.__init__(self, window) def run(self): view = sublime.active_window().active_view() import spdb ; spdb.start() print(view.file_name())
Many thanks in advance for the help!