score:1

Accepted answer

so, i finally found out the right configuration for my setup. to sum it up:

  • the application i want to debug runs on a linux machine with pydevd installed (pip install pydevd)
  • my eclipse+pydev setup is running on my windows 7 workstation
  • the debug server is running inside eclipse and listens on it's default port 5678

apparently one has to configure the path mappings on the target machine (the one hosting the application you want to debug, so in my case this would be the linux machine). this can be done in two ways (on linux):

  1. pasting them directly into pydevd_file_utils.py (on my linux system it's residing inside /usr/local/lib/python2.7/dist-packages/) in the form:

    paths_from_eclipse_to_python = [ ('remote path 1', 'local path 1'), ('remote path 2', 'local path 2'), ... ]

  2. passing them as an environment variable (e.g. like export paths_from_eclipse_to_python='[["remote path 1", "local path 1"], ["remote path 2", "local path 2"], ...]') before launching your application

in my case remote path would be the project path on my windows machine (e.g. c:\\users\\workspace\\project\\) and local path the one on my linux host (/home/user/project/). notice the trailing backslashes i had to add to the paths because otherwise pydev would translate the paths to something like /home/user/project\file.py which results in an unknown file. as a consequence i additionally had to escape the backslashes in the windows paths.

hope this helps anyone who runs into similar difficulties like mine.


Related Query

More Query from same tag