HOWTO: python remote debugging in Komodo IDE

24.01.2010 0 Debug Python

workstation: windows; Komodo IDE; PuTTY

server: linux (it can have paranoid firewall rules - all you need is SSH access)

  1. download debugger from
    $ wget ""
    $ tar -xvf Komodo-PythonRemoteDebugging-5.2.4-37659-linux-x86_64.tar.gz
    $ cd Komodo-PythonRemoteDebugging-5.2.4-37659-linux-x86_64
  2. copy dbgp to $PYTHONPATH or add it to PYTHONPATH
    $ cp -R dbgp/ /local/modules/
    copy debugger bin/* someshere to PATH
    $ cp bin/* ~/bin
    (why ActiveState do not provide
  3. Setup tunnel between workstation and server
    putty: Connection > SSH > Tunnels
    R9000 ->
    "R" mean that putty will send everything send to server port 9000 to workstation port 9000
  4. Run Komodo IDE
    Edit > Preferences > Debugging > Connection
    (x) a specific port [ 9000 ]
    Enshure "Debugger > Listen for Debugging connections" is checked
  5. on server run debugger test
    pydbgp -d
  6. Komodo will alert about incoming debug connection
    Also, it will say it have no uri-mapping
    Add mapping between local and remote work copies

In case if workstation run linux or macosx tunnel on step (4) should be done using native *nix utils.
Komodo itself is available for all platforms, so other steps do not change.

Server can run scripts under mod_python or mod_wsgi. To set software break-point use:

from dbgp.client import brk
brk(host='', port=9000)

To manage uncaught exceptions:

from dbgp.client import brkOnExcept
brkOnExcept(host='', port=9000)

More info: Remote Debugging in Komodo IDE, Debugging Python in Komodo IDE.

PS. Happy debugging!

Написать комментарий

Вы представились как:   e-mail: email (изменить)

Ссылки запрещены.

Copyright © DPP, 2008-2009