Winpdb Reborn - A GPL Python Debugger, reborn from the unmaintained Winpdb

Overview

Note from Philippe Fremy

The port of winpdb-reborn to Python 3 / WxPython 4 is unfortunately not working very well. So Winpdb for Python 3 does not really work. Feel free to submit Pull Requests to improve the situation. At the moment, this project is stopped.


Build Status Linux

Winpdb Reborn - A GPL Python Debugger, reborn from the unmaintained Winpdb

by Philippe Fremy as maintainer, and Nir Aides as initial author

Website: https://github.com/bluebird75/winpdb

Description

Winpdb Reborn is a portable (Windows / Linux / macOS) standalone graphical debugger for Python. It focuses on making debugging easy and does not include any IDE features. It has very little dependencies (only wxPython for the GUI).

Features:

  • graphical interface with stack/variable inspection, breakpoints and more
  • breakpoints: on lines or functions, with possible conditions, load/save breakpoint info
  • multi-threaded debugging
  • smart handling of fork, follow parent or child
  • remote debugging: GUI on one computer, program to debug on another computer with encrypted communication
  • up to 20 times quicker than pdb, the default Python debugger (on which many other debuggers are built)
  • debug PyPy scripts

Note: The original Winpdb was no longer maintained since the v1.4.8 release in 2010. With the agreement of the author (Nir Aides), I (Philippe Fremy) am providing a maintained version with new functionality under the Winpdb Reborn name.

Requirements

Platform supported:

  • Linux
  • Windows XP and above
  • macOS is probably working but not tested

To run Winpdb Reborn:

  • CPython 3.5 or above and wxPython 4

This version is for Python 3 only. A stable version of Winpdb for Python 2 is available on PyPi: https://pypi.org/project/winpdb-reborn/1.5.0/ and in the branch winpdb-reborn-python2 . You will need Python 2.7 and WxPython 3 to run it.

Note that running Winpdb with PyPy is possible, by launching rpdb2.py with pypy and using the Winpdb GUI to connect to it.

Winpdb Reborn is NOT compatible with Jython or IronPython.

Release history

Version 2.0.0.1

  • fix packaging mistake which prevented winpdb to run

Version 2.0.0

  • port Winpdb to wxPython 4 / Python 3
  • the effort is still in progress

Version 1.5.0

  • First official release by Philippe Fremy
  • Add support for Python 3 GUI (using wxPython Phoenix)
  • Allow installation of all dependencies with pip
  • Add support for Python 2.7, 3.5 and 3.6
  • Drop support for Python 2.5 and wxPython 2.6, min versions are now Python 2.6 and wxPython 3.0
  • rpdb2.py is now compatible with Python 3
  • Add support for PyPy to Rpdb2
  • Can now specify a different Python interpreter for the program under debug, allowing PyPy support
  • Avoid crash on Windows when closing debugger
  • Support drag’n drop of files to load source code
  • Add unit-tests and a functional test suite
  • Add a Continuous Integration server with travis CI
  • Can adjust behavior of debugger to activate/deactivate the breakpoint before exit
  • fix for launching Gnome Terminal properly

Version 1.4.8

Last stable version released by Nir Aides.

Installation

(not working yet until the new version is released).

The standard way to install Winpdb Reborn is with pip, as administrator/root::

# python -m pip install winpdb-reborn

You must also install the wxPython for your version of Python:

Winpdb Reborn is not packaged yet by any Linux distro. If your package manager proposes to install Winpdb, that’s the old unmaintained Winpdb which works neither with Python 2.7 nor with Python 3.

Additional installation methods

To install from a checkout or from an archive::

# python setup.py install -f

No install mode

If you don’t want to install Winpdb Reborn, you can still try it by calling it explicitly with your program to debug::

$ python /the/path/to/winpdb.py my_program.py 

Where do the files go ?

The setup script copies rpdb2.py and winpdb.py modules to the Python site-packages folder. The scripts rpdb2 and winpdb are copied to the Python binaries (scripts) folder. On Linux, this folder is usually /usr/bin and is in the path by default. On Windows, this folder is %PYTHONHOME%\Scripts, where you should see a winpdb.exe and rpdb2.exe .

Usage

If you have installed Winpdb Reborn, the simplest way to launch it is::

$ python -m winpdb my_program.py

or even::

$ winpdb my_program.py

Find out about the other command-line options with –-help .

Documentation

Use the -h or --help command-line flag for command-line help.

Inside Winpdb/Rpdb2 console, use the help command for detailed description of debugger commands.

Online documentation is available at: https://web.archive.org/web/20180724122042/http://www.winpdb.org/docs

An introduction to Winpdb usage, by Pr Norm Matloff: http://heather.cs.ucdavis.edu/%7Ematloff/winpdb.html

A detailed Winpdb tutorial is also available at: https://code.google.com/archive/p/winpdb/wikis/DebuggingTutorial.wiki

Community

You can ask questions about Winpdb Reborn on the dedicated Google group: https://groups.google.com/forum/#!forum/winpdb

Feel free to raise issues or propose improvements on the GitHub repository: https://github.com/bluebird75/winpdb/issues

Comments
  • Pypi winpdb 1.4.8

    Pypi winpdb 1.4.8

    If you try to install pypi with

    pip install winpdb

    You get version 1.3.8. This version has never worked for me with rpdb2. I have to install 1.4.8 manually.

    Looking at your pypi page: https://pypi.python.org/pypi/winpdb

    It looks it has 1.4.8 but the actual download link links to http://winpdb.googlecode.com/files/winpdb-1.4.8.tar.gz Which 404s.

    It seems like it should point to http://code.google.com/p/winpdb/downloads/detail?name=winpdb-1.4.8.tar.gz&can=1&q=

    opened by Blanen 6
  • No longer available from pip

    No longer available from pip

    $ python -m pip install winpdb-reborn
    Collecting winpdb-reborn
      Could not find a version that satisfies the requirement winpdb-reborn (from versions: )
    No matching distribution found for winpdb-reborn
    

    install instructions no longer work

    opened by voidplayer 5
  • RPDBTERM not defined error

    RPDBTERM not defined error

    I've tried several ways to debug file with winpdb running like this: $ winpdb a.py but I've always had this undeclared variable error. Couldn't google anything. I see it's declared in "rpdb2.py" file, outside the "rpdb/" folder Here's my traceback:

    Traceback (most recent call last):
      File "/usr/lib/python3.8/site-packages/winpdb.py", line 1288, in __wrapper
        self.m_f(*args, **kwargs)
      File "/usr/lib/python3.8/site-packages/rpdb/session_manager.py", line 197, in launch
        return self.__smi.launch(fchdir, command_line, interpreter, fload_breakpoints)
      File "/usr/lib/python3.8/site-packages/rpdb/session_manager.py", line 1160, in launch
        self._spawn_server(fchdir, ExpandedFilename, args, rid, interpreter)
      File "/usr/lib/python3.8/site-packages/rpdb/session_manager.py", line 1269, in _spawn_server
        terminal_command = CalcTerminalCommand()
      File "/usr/lib/python3.8/site-packages/rpdb/session_manager.py", line 2385, in CalcTerminalCommand
        if RPDBTERM in os.environ:
    NameError: name 'RPDBTERM' is not defined
    

    Btw. I think there will also be problems with the others global variables in the CalcTerminalCommand() function inside session_maneger.py

    opened by ILoveMuffins 4
  • Incompatibilities with wxpython 4.0.7

    Incompatibilities with wxpython 4.0.7

    It seems that the current git head is not compatible to the wxpython 4.0.7 version. Description: When attaching to a remote session the debugger works find but all control buttons and inspection areas stay disabled. The shortcuts (e.g. F6/F5 work just fine). This leads to exceptions.

    Reason: At least the current version of wxPython (4.1.0 and 4.0.7) do not have the type rectS and the type rect does not provide any function inside(). These functions are called as wx.rectS(...) and r.inside(...) in winpdb.py.

    Solution: Replacing wx.rectS by wx.rect and r.inside by r.contains(...) solves the bug and remote debugging works like a charm ;-)

    Unfortunately I am not familiar with wxWidgets. Thus I do not know wheter any version ever supported these statements and if so since when this has changed.

    If the fix is needed as a patch, please let me know.

    opened by UEWiebelitz 3
  • fails to install on Rasapbian Stretch

    fails to install on Rasapbian Stretch

    Installed and used winpdb-reborn on Windows 10: I like its threads debug UI. Now I hit Linux specific code and have to continue debug on the target host, a Raspberry Pi running Raspbian stretch. When I tried to install it via "python3 -m pip install winpdb-reborn" it failed to build the wheels for all three components (wxpython, Pillow, and six). So I tried to install just wxpython via "pip3 install -U wxPython" and it also failed. Suggestions?

    Here's the log: =============================================================================================== pi@RPI4m:~/Desktop $ pip3 install -U wxPython Collecting wxPython Using cached https://files.pythonhosted.org/packages/17/74/7c3ced03c3c76b9f98e4a0edae1801755a7599ebf481c04d9f77dfff17e3/wxPython-4.0.4.tar.gz Collecting Pillow (from wxPython) Using cached https://files.pythonhosted.org/packages/81/1a/6b2971adc1bca55b9a53ed1efa372acff7e8b9913982a396f3fa046efaf8/Pillow-6.0.0.tar.gz Collecting six (from wxPython) Using cached https://files.pythonhosted.org/packages/73/fb/00a976f728d0d1fecfe898238ce23f502a721c0ac0ecfedb80e0d88c64e9/six-1.12.0-py2.py3-none-any.whl Building wheels for collected packages: wxPython, Pillow Running setup.py bdist_wheel for wxPython ... error Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-j5r19rr5/wxPython/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" bdist_wheel -d /tmp/tmps1nar3q4pip-wheel- --python-tag cp35: running bdist_wheel running build WARNING: Building this way assumes that all generated files have been generated already. If that is not the case then use build.py directly to generate the source and perform the build stage. You can use --skip-build with the bdist_* or install commands to avoid this message and the wxWidgets and Phoenix build steps in the future.

    "/usr/bin/python3" -u build.py build Will build using: "/usr/bin/python3" 3.5.3 (default, Jan 19 2017, 14:11:04) [GCC 6.3.0 20170124] Python's architecture is 32bit cfg.VERSION: 4.0.4

    Running command: build Running command: build_wx wxWidgets build options: ['--wxpython', '--unicode', '--gtk3'] Configure options: ['--enable-unicode', '--with-gtk=3', '--with-opengl', '--enable-sound', '--enable-graphics_ctx', '--enable-mediactrl', '--enable-display', '--enable-geometry', '--enable-debug_flag', '--enable-optimise', '--disable-debugreport', '--enable-uiactionsim', '--enable-autoidman', '--with-sdl'] /tmp/pip-build-j5r19rr5/wxPython/ext/wxWidgets/configure --enable-unicode --with-gtk=3 --with-opengl --enable-sound --enable-graphics_ctx --enable-mediactrl --enable-display --enable-geometry --enable-debug_flag --enable-optimise --disable-debugreport --enable-uiactionsim --enable-autoidman --with-sdl checking build system type... armv7l-unknown-linux-gnueabihf checking host system type... armv7l-unknown-linux-gnueabihf checking for --disable-gui... no

    <...> No package 'gtk+-3.0' found Package gthread-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing `gthread-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'gthread-2.0' found no *** Could not run GTK+ test program, checking why... *** The test program failed to compile or link. See the file config.log for the *** exact error that occured. This usually means GTK+ is incorrectly installed. configure: error: The development files for GTK+ were not found. For GTK+ 2, please ensure that pkg-config is in the path and that gtk+-2.0.pc is installed. For GTK+ 1.2 please check that gtk-config is in the path, and that the version is 1.2.3 or above. Also check that the libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config --libs' are in the LD_LIBRARY_PATH or equivalent.

    Error running configure ERROR: failed building wxWidgets Traceback (most recent call last): File "build.py", line 1321, in cmd_build_wx wxbuild.main(wxDir(), build_options) File "/tmp/pip-build-j5r19rr5/wxPython/buildtools/build_wxwidgets.py", line 375, in main "Error running configure") File "/tmp/pip-build-j5r19rr5/wxPython/buildtools/build_wxwidgets.py", line 85, in exitIfError raise builder.BuildError(msg) buildtools.builder.BuildError: Error running configure Finished command: build_wx (0m30.592s) Finished command: build (0m30.592s) Command '"/usr/bin/python3" -u build.py build' failed with exit code 1.


    Failed building wheel for wxPython Running setup.py clean for wxPython Running setup.py bdist_wheel for Pillow ... error Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-j5r19rr5/Pillow/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" bdist_wheel -d /tmp/tmp0r7t2sijpip-wheel- --python-tag cp35: running bdist_wheel running build running build_py creating build creating build/lib.linux-armv7l-3.5 creating build/lib.linux-armv7l-3.5/PIL copying src/PIL/ImageCms.py -> build/lib.linux-armv7l-3.5/PIL

    <...> running egg_info writing dependency_links to src/Pillow.egg-info/dependency_links.txt writing top-level names to src/Pillow.egg-info/top_level.txt writing src/Pillow.egg-info/PKG-INFO reading manifest file 'src/Pillow.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' warning: no files found matching '.c' warning: no files found matching '.h' warning: no files found matching '.sh' no previously-included directories found matching 'docs/_static' warning: no previously-included files found matching '.appveyor.yml' warning: no previously-included files found matching '.coveragerc' warning: no previously-included files found matching '.codecov.yml' warning: no previously-included files found matching '.editorconfig' warning: no previously-included files found matching '.landscape.yaml' warning: no previously-included files found matching '.readthedocs.yml' warning: no previously-included files found matching 'azure-pipelines.yml' warning: no previously-included files found matching 'tox.ini' warning: no previously-included files matching '.git' found anywhere in distribution warning: no previously-included files matching '.pyc' found anywhere in distribution warning: no previously-included files matching '.so' found anywhere in distribution no previously-included directories found matching '.azure-pipelines' no previously-included directories found matching '.travis' writing manifest file 'src/Pillow.egg-info/SOURCES.txt' running build_ext

    The headers or library files could not be found for jpeg, a required dependency when compiling Pillow from source.

    Please see the install instructions at: https://pillow.readthedocs.io/en/latest/installation.html

    Traceback (most recent call last): File "/tmp/pip-build-j5r19rr5/Pillow/setup.py", line 792, in zip_safe=not (debug_build() or PLATFORM_MINGW), ) File "/usr/lib/python3.5/distutils/core.py", line 148, in setup dist.run_commands() File "/usr/lib/python3.5/distutils/dist.py", line 955, in run_commands self.run_command(cmd) File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/usr/lib/python3/dist-packages/wheel/bdist_wheel.py", line 179, in run self.run_command('build') File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command self.distribution.run_command(command) File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/usr/lib/python3.5/distutils/command/build.py", line 135, in run self.run_command(cmd_name) File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command self.distribution.run_command(command) File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/usr/lib/python3.5/distutils/command/build_ext.py", line 339, in run self.build_extensions() File "/tmp/pip-build-j5r19rr5/Pillow/setup.py", line 606, in build_extensions raise RequiredDependencyException(f) main.RequiredDependencyException: jpeg

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last): File "", line 1, in File "/tmp/pip-build-j5r19rr5/Pillow/setup.py", line 804, in raise RequiredDependencyException(msg) main.RequiredDependencyException:

    The headers or library files could not be found for jpeg, a required dependency when compiling Pillow from source.

    Please see the install instructions at: https://pillow.readthedocs.io/en/latest/installation.html


    Failed building wheel for Pillow Running setup.py clean for Pillow Failed to build wxPython Pillow Installing collected packages: Pillow, six, wxPython Running setup.py install for Pillow ... error Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-j5r19rr5/Pillow/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /tmp/pip-e3eckqgz-record/install-record.txt --single-version-externally-managed --compile --user --prefix=: running install running build running build_py creating build creating build/lib.linux-armv7l-3.5 creating build/lib.linux-armv7l-3.5/PIL copying src/PIL/ImageCms.py -> build/lib.linux-armv7l-3.5/PIL

    <...> running egg_info writing src/Pillow.egg-info/PKG-INFO writing top-level names to src/Pillow.egg-info/top_level.txt writing dependency_links to src/Pillow.egg-info/dependency_links.txt reading manifest file 'src/Pillow.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' warning: no files found matching '.c' warning: no files found matching '.h' warning: no files found matching '.sh' no previously-included directories found matching 'docs/_static' warning: no previously-included files found matching '.appveyor.yml' warning: no previously-included files found matching '.coveragerc' warning: no previously-included files found matching '.codecov.yml' warning: no previously-included files found matching '.editorconfig' warning: no previously-included files found matching '.landscape.yaml' warning: no previously-included files found matching '.readthedocs.yml' warning: no previously-included files found matching 'azure-pipelines.yml' warning: no previously-included files found matching 'tox.ini' warning: no previously-included files matching '.git' found anywhere in distribution warning: no previously-included files matching '.pyc' found anywhere in distribution warning: no previously-included files matching '.so' found anywhere in distribution no previously-included directories found matching '.azure-pipelines' no previously-included directories found matching '.travis' writing manifest file 'src/Pillow.egg-info/SOURCES.txt' running build_ext

    The headers or library files could not be found for jpeg,
    a required dependency when compiling Pillow from source.
    
    Please see the install instructions at:
       https://pillow.readthedocs.io/en/latest/installation.html
    
    Traceback (most recent call last):
      File "/tmp/pip-build-j5r19rr5/Pillow/setup.py", line 792, in <module>
        zip_safe=not (debug_build() or PLATFORM_MINGW), )
      File "/usr/lib/python3.5/distutils/core.py", line 148, in setup
        dist.run_commands()
      File "/usr/lib/python3.5/distutils/dist.py", line 955, in run_commands
        self.run_command(cmd)
      File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/lib/python3/dist-packages/setuptools/command/install.py", line 61, in run
        return orig.install.run(self)
      File "/usr/lib/python3.5/distutils/command/install.py", line 583, in run
        self.run_command('build')
      File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/lib/python3.5/distutils/command/build.py", line 135, in run
        self.run_command(cmd_name)
      File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/lib/python3.5/distutils/command/build_ext.py", line 339, in run
        self.build_extensions()
      File "/tmp/pip-build-j5r19rr5/Pillow/setup.py", line 606, in build_extensions
        raise RequiredDependencyException(f)
    __main__.RequiredDependencyException: jpeg
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-j5r19rr5/Pillow/setup.py", line 804, in <module>
        raise RequiredDependencyException(msg)
    __main__.RequiredDependencyException:
    
    The headers or library files could not be found for jpeg,
    a required dependency when compiling Pillow from source.
    
    Please see the install instructions at:
       https://pillow.readthedocs.io/en/latest/installation.html
    
    
    ----------------------------------------
    

    Command "/usr/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-j5r19rr5/Pillow/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /tmp/pip-e3eckqgz-record/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-build-j5r19rr5/Pillow/ pi@RPI4m:~/Desktop $ ===============================================================================================

    opened by MTVS2 3
  • More hotkeys

    More hotkeys

    Added more hotkeys for the File menu actions and changed the Alt-X to Ctrl-X to quit winpdb 😃 List of hotkeys added/changed: Ctrl-P: Password Ctrl-L: Launch Ctrl-A: Attach Ctrl-D: Detach Ctrl-S: Stop Ctrl-R: Restart Ctrl-O: Open Source Ctrl-X (Command-Q on Mac): Exit

    opened by dlordi 3
  • add hotkeys for common actions

    add hotkeys for common actions

    Hi, I use winpdb mainly for remote debugging and keyboard is way faster than using mouse, so I added some hotkeys for the actions I repeatedly need. Hope this helps also other users!

    opened by dlordi 2
  • py3.6, cannot attach to remote

    py3.6, cannot attach to remote

      File "/work/proj/ve/lib/python3.6/site-packages/rpdb2.py", line 10395, in ConnectNoThrow
        self.Connect()
      File "/work/proj/ve/lib/python3.6/site-packages/rpdb2.py", line 10406, in Connect
        server_info = server.server_info()
      File "/usr/lib/python3.6/xmlrpc/client.py", line 1112, in __call__
        return self.__send(self.__name, args)
      File "/work/proj/ve/lib/python3.6/site-packages/rpdb2.py", line 9673, in __request
        (fcompress, digest, msg) = self.m_crypto.do_crypto(args, fencrypt)
      File "/work/proj/ve/lib/python3.6/site-packages/rpdb2.py", line 4833, in do_crypto
        s = self.__encrypt(s)
      File "/work/proj/ve/lib/python3.6/site-packages/rpdb2.py", line 4873, in __encrypt
        d = DES.new(key_padded, DES.MODE_CBC, iv)
      File "/work/proj/ve/lib/python3.6/site-packages/Crypto/Cipher/DES.py", line 145, in new
        return _create_cipher(sys.modules[__name__], key, mode, *args, **kwargs)
      File "/work/proj/ve/lib/python3.6/site-packages/Crypto/Cipher/__init__.py", line 79, in _create_cipher
        return modes[mode](factory, **kwargs)
      File "/work/proj/ve/lib/python3.6/site-packages/Crypto/Cipher/_mode_cbc.py", line 293, in _create_cbc_cipher
        return CbcMode(cipher_state, iv)
      File "/work/proj/ve/lib/python3.6/site-packages/Crypto/Cipher/_mode_cbc.py", line 97, in __init__
        c_uint8_ptr(iv),
      File "/work/proj/ve/lib/python3.6/site-packages/Crypto/Util/_raw_api.py", line 144, in c_uint8_ptr
        raise TypeError("Object type %s cannot be passed to C code" % type(data))
    TypeError: Object type <class 'str'> cannot be passed to C code
    
    
    opened by agroszer 2
  • minor fixes to make it work in osx, locale detection, calling to wx.Font, commented out call to wx.MenuBar.SetAutoWindowMenu(False)

    minor fixes to make it work in osx, locale detection, calling to wx.Font, commented out call to wx.MenuBar.SetAutoWindowMenu(False)

    Hi, i was trying your fork of winpdb but don't run at first... the modifications work with python 3.6 & wxPython 4.0.1 on OS X El Capitan (10.11.6)

    opened by juancrobles 2
  • DeprecationWarning from rpdb2.py

    DeprecationWarning from rpdb2.py

    This warning is a little annoying, particularly when I am scanning/testing for the absence of stderr output:

    >>> import rpdb2
    rpdb2.py:308: DeprecationWarning: the sets module is deprecated
      import sets
    rpdb2.py:313: DeprecationWarning: The popen2 module is deprecated.  Use the subprocess module.
      import popen2
    

    Here is a fix. Note - this may be needed only for 2.6, as I do not see the DeprecationWarning for the CPython 2.7 and 3.4 versions I have tried the original on

    --- rpdb2.py.orig	2010-08-17 15:12:52.000000000 -0400
    +++ rpdb2.py	2017-06-29 21:01:06.751002237 -0400
    @@ -305,14 +305,21 @@
     
     try:
         import compiler
    -    import sets
     except:
         pass
     
    -try:
    -    import popen2
    -except:
    -    pass
    +if sys.version_info[:2] >= (2, 6):
    +    import warnings
    +    with warnings.catch_warnings():
    +        warnings.filterwarnings("ignore", category=DeprecationWarning)
    +        import sets
    +        import popen2
    +else:
    +    try:
    +        import sets
    +        import popen2
    +    except:
    +        pass
     
     try:
         from Crypto.Cipher import DES
    
    
    opened by pourhouse 2
  • rpdb folder not installed when using pip

    rpdb folder not installed when using pip

    Hi,

    the rpdb folder with the different scripts was not installed when i used pip to install the new 2.0.0.0 version so i got the following error: Traceback (most recent call last): File "winpdb.py", line 26, in <module> import rpdb.const ModuleNotFoundError: No module named 'rpdb'

    after manually downloading the folder from here and putting it into the site-packages folder it works normally.

    Thanks for the great work!

    opened by domingoO-jones 1
  • Get wrong line (16) when setting a breakpoint at line 29

    Get wrong line (16) when setting a breakpoint at line 29

    It runs under Python 3.8 and Windows 8.1 x64. Although it's running a previous version here, but the same result in ver 2.0.0.1 too. The followings are the result of after adding print() in the function CalcScopeLine() to show what errors I had got:

    def CalcScopeLine(self, lineno):
        print(lineno)
        rvl = copy.copy(self.m_valid_lines)  # m_valid_lines has strange result
        rvl.reverse()
        print(rvl)
    
        for l in rvl:  # JF@21DEC2022, this will cause a correct lineno (29) changes to an incorrect l (16)?
            if lineno >= l:
                break
        return l
    

    -----the main window e:\Works\Python\ttkwidgets-master\examples>py ....\rpdb2.py example_calendar.py ....\rpdb2.py:296: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses import imp RPDB2 - The Remote Python Debugger, version RPDB_2_5_0, Copyright (C) 2005-2009 Nir Aides, 2013-2017 Philippe Fremy Type "help", "copyright", "license", "credits" for more information.

    *** Password has been set to a random password. *** Starting debuggee... *** Attaching to debuggee... *** Debug Channel is NOT encrypted. *** Successfully attached to *** 'e:\works\python\ttkwidgets-master\examples\example_calendar.py'. *** Debuggee is waiting at break point for further commands. bl List of breakpoints:

    Id State Line Filename-Scope-Condition-Encoding

    bp 29

    bl List of breakpoints:

    Id State Line Filename-Scope-Condition-Encoding

    0 enabled 16 ...\examples\example_calendar.py

    list Source lines for thread 111776 from file 'e:\works\python\ttkwidgets-master\examples\example_calendar.py':

          1  # -*- coding: utf-8 -*-
          2
          3  # Copyright (c) Juliette Monsel 2018
          4  # For license see LICENSE
          5
    

    C> 6 from ttkwidgets import Calendar 7 import tkinter as tk 8 9 def validate(): 10 sel = calendar.selection 11 if sel is not None: 12 label.configure(text='Selected date: %s' % sel.st... 13 14 window = tk.Tk() 15 calendar = Calendar(window, year=2022, month=10, selectfo... B 16 selectbackground='red') 17 calendar.pack() 18 19 tk.Button(window, text='Select', command=validate).pack() 20 label = tk.Label(window, text='Selected date:')


    -----the other window e:\Works\Python\rpdb2.py:296: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses import imp 6 [285, 284, 277, 276, 275, 273, 271, 16, 15, 14, 9, 7, 6] 29 [285, 284, 277, 276, 275, 273, 271, 16, 15, 14, 9, 7, 6]

    The example_calendar.py file has only 30 lines long. What is the line 271 and aboves? and line 29 is missing obviously

    opened by jfongattw 1
  • can't open file 'session_manager\..\rpdb2.py': [Errno 2] No such file or directory

    can't open file 'session_manager\..\rpdb2.py': [Errno 2] No such file or directory

    Hi,

    I am developing software with Python 3.7 on WIndows 10.

    I freshly installed windpb 👍

    J:\Dropbox\cff\Python\PhoneBotV3>python -m pip install --upgrade winpdb-reborn
    Requirement already up-to-date: winpdb-reborn in c:\users\nino\appdata\local\programs\python\python37\lib\site-packages (2.0.0.1)
    Requirement already satisfied, skipping upgrade: wxpython>=4 in c:\users\nino\appdata\local\programs\python\python37\lib\site-packages (from winpdb-reborn) (4.1.1)
    Requirement already satisfied, skipping upgrade: pillow in c:\users\nino\appdata\local\programs\python\python37\lib\site-packages (from wxpython>=4->winpdb-reborn) (6.0.0)
    Requirement already satisfied, skipping upgrade: numpy; python_version >= "3.0" in c:\users\nino\appdata\local\programs\python\python37\lib\site-packages (from wxpython>=4->winpdb-reborn) (1.18.2)
    Requirement already satisfied, skipping upgrade: six in c:\users\nino\appdata\local\programs\python\python37\lib\site-packages (from wxpython>=4->winpdb-reborn) (1.15.0)
    

    Then I run it with this command :

    winpdb MySoft.py

    Nothing happen.

    So I run this one:

    python -m winpdb MySoft.py

    The GUI is open and empty. No file, no code. So I tried to attach a file by running the command again

    python -m winpdb MySoft.py

    The first time it opens a cmd window with this message:

    C:\Users\Nino\AppData\Local\Programs\Python\Python37\python.exe: can't open file 'session_manager\..\rpdb2.py': [Errno 2] No such file or directory

    The 2nd time when I attached a command (Menu>File>Attach), I get another cmd window with exact same message: C:\Users\Nino\AppData\Local\Programs\Python\Python37\python.exe: can't open file 'session_manager\..\rpdb2.py': [Errno 2] No such file or directory

    Then I searched for this file and this issue on StackOverflow, google, and more.... NOTHING!?

    So what did I do wrong?

    Can anyone help me please?

    opened by gauthierbuttez 3
  • error message on windwos

    error message on windwos

    When i run winpdg on windows i have this message 👍

    La syntaxe du nom de fichier, de répertoire ou de volume est incorrecte.

    Current directory: c:\Users\Benoit\projets\tproj

    Command to be executed: "C:\WINDOWS\system32\cmd.exe" /C """C:\Python37\python.exe" "session_manager..\rpdb2.py" --debugee --pwd="i3ELQQAm" --rid=9823679 "c:\users\benoit\projets\tproj\tdebug.py" ""

    ConEmuC: Root process was alive less than 10 sec, ExitCode=1. Press Enter or Esc to close console... I think the tools does find the file session_manager..\rpdb2.py. I work on Windows 10 Python 3.7 and the last version of winpdb winpdb_reborn-2.0.0.1 Successfully installed Winpdb-reborn-2.0.0.1 numpy-1.19.4 pillow-8.0.1 wxpython-4.1.0

    opened by Ben8565 5
  • In Windows XP 32 bits Home (Python 3.4.3)

    In Windows XP 32 bits Home (Python 3.4.3)

    Hello. Saved the test case from here http://onreader.mdl.ru/PythonParallelProgrammingCookbook.2nd/content/Ch09.html (Chapter 9. Python Debugging and Testing from "The Book of Python Parallel Programming Recipes", 2nd ed. In Russian) along the path C:/1 in the winpdb_reborn_code_example.py file. `import time import os from random import randint from threading import Thread

    class MyThreadClass (Thread): def init(self, name, duration): Thread.init(self) self.name = name self.duration = duration def run(self): print ("---> " + self.name +
    " running, belonging to process ID "
    + str(os.getpid()) + "\n") time.sleep(self.duration) print ("---> " + self.name + " over\n") def main(): start_time = time.time()

    # Thread Creation
    thread1 = MyThreadClass("Thread#1 ", randint(1,10))
    thread2 = MyThreadClass("Thread#2 ", randint(1,10))
    thread3 = MyThreadClass("Thread#3 ", randint(1,10))
    
    # Thread Running
    thread1.start()
    thread2.start()
    thread3.start()
    
    # Thread joining
    thread1.join()
    thread2.join()
    thread3.join()
    
    # End 
    print("End")
    
    #Execution Time
    print("--- %s seconds ---" % (time.time() - start_time))
    

    if name == "main": main()`

    `

    Successfully installed winpdb-reborn-2.0.0.1

    C:\Documents and Settings\ia>cd C:\1

    C:\1>python -m winpdb .\winpdb_reborn_code_example.py 23:59:47.844 rpdb2.py:6148 MainThread/2328 __setrecursionlimit(): rl = 1000 00:00:00.657 winpdb.py:3006 MainThread/2328 set_font(): Using font "Courier New" for Console 00:00:00.688 winpdb.py:3006 MainThread/2328 set_font(): Using font "Courier New" for Console 00:00:11.203 session_manager.py:1282 Thread-2/2196 _spawn_server(): Terminal ope n string: 'start "rpdb2 - Version RPDB_1_5_0 - Debuggee Console" cmd.exe /K ""C: \Python34\python.exe" "session_manager\..\rpdb2.py" --debugee --pwd="q2G_A2L M" --rid=6268676 "c:\1\winpdb_reborn_code_example.py" "' 00:00:12.938 session_manager.py:1094 Thread-2/2196 __wait_for_debuggee(): Scanni ng for debuggee... 00:00:17.016 session_manager.py:1094 Thread-2/2196 __wait_for_debuggee(): Scanni ng for debuggee... 00:00:20.047 session_manager.py:1094 Thread-2/2196 __wait_for_debuggee(): Scanni ng for debuggee...

    `

    Another console window started up with this text: `

    C:\Python34\python.exe: can't open file 'session_manager..\rpdb2.py': [Errno 2] No such file or directory

    C:\1>

    `

    https://s8.hostingkartinok.com/uploads/images/2020/09/93502ddefe8ff570043a997eb5f4eb66.jpg

    opened by tellts 2
  • Mismatched Passwords

    Mismatched Passwords

    Hi,

    when I try to debug with Python3 and Version 2.0.0.1 I get the following error:

    While attempting to find a debugee, at least one debugee denied connection because of mismatched passwords. Please verify your password.

    With python2 and version 1.5.0 everything is working fine.

    Greetings

    opened by domingoO-jones 2
Owner
Philippe F
Passionated Software Developer and SCRUM Master, with a strong love for Python and Qt.
Philippe F
Debugger capable of attaching to and injecting code into python processes.

DISCLAIMER: This is not an official google project, this is just something I wrote while at Google. Pyringe What this is Pyringe is a python debugger

Google 1.6k Dec 15, 2022
pdb++, a drop-in replacement for pdb (the Python debugger)

pdb++, a drop-in replacement for pdb What is it? This module is an extension of the pdb module of the standard library. It is meant to be fully compat

null 1k Jan 2, 2023
Graphical Python debugger which lets you easily view the values of all evaluated expressions

birdseye birdseye is a Python debugger which records the values of expressions in a function call and lets you easily view them after the function exi

Alex Hall 1.5k Dec 24, 2022
Voltron is an extensible debugger UI toolkit written in Python.

Voltron is an extensible debugger UI toolkit written in Python. It aims to improve the user experience of various debuggers (LLDB, GDB, VDB an

snare 5.9k Dec 30, 2022
NoPdb: Non-interactive Python Debugger

NoPdb: Non-interactive Python Debugger Installation: pip install nopdb Docs: https://nopdb.readthedocs.io/ NoPdb is a programmatic (non-interactive) d

Ondřej Cífka 67 Oct 15, 2022
Tracing instruction in lldb debugger.Just a python-script for lldb.

lldb-trace Tracing instruction in lldb debugger. just a python-script for lldb. How to use it? Break at an address where you want to begin tracing. Im

null 156 Jan 1, 2023
Visual Interaction with Code - A portable visual debugger for python

VIC Visual Interaction with Code A simple tool for debugging and interacting with running python code. This tool is designed to make it easy to inspec

Nathan Blank 1 Nov 16, 2021
An improbable web debugger through WebSockets

wdb - Web Debugger Description wdb is a full featured web debugger based on a client-server architecture. The wdb server which is responsible of manag

Kozea 1.6k Dec 9, 2022
PINCE is a front-end/reverse engineering tool for the GNU Project Debugger (GDB), focused on games.

PINCE is a front-end/reverse engineering tool for the GNU Project Debugger (GDB), focused on games. However, it can be used for any reverse-engi

Korcan Karaokçu 1.5k Jan 1, 2023
Little helper to run Steam apps under Proton with a GDB debugger

protongdb A small little helper for running games with Proton and debugging with GDB Requirements At least Python 3.5 protontricks pip package and its

Joshie 21 Nov 27, 2022
Full featured multi arch/os debugger built on top of PyQt5 and frida

Full featured multi arch/os debugger built on top of PyQt5 and frida

iGio90 1.1k Dec 26, 2022
Arghonaut is an interactive interpreter, visualizer, and debugger for Argh! and Aargh!

Arghonaut Arghonaut is an interactive interpreter, visualizer, and debugger for Argh! and Aargh!, which are Befunge-like esoteric programming language

Aaron Friesen 2 Dec 10, 2021
A simple rubber duck debugger

Rubber Duck Debugger I found myself many times asking a question on StackOverflow or to one of my colleagues just for finding the solution simply by d

null 1 Nov 10, 2021
Hdbg - Historical Debugger

hdbg - Historical Debugger This is in no way a finished product. Do not use this

Fivreld 2 Jan 2, 2022
Trashdbg - TrashDBG the world's worse debugger

The world's worse debugger Over the course of multiple OALABS Twitch streams we

OALabs 21 Jun 17, 2022
The official code of LM-Debugger, an interactive tool for inspection and intervention in transformer-based language models.

LM-Debugger is an open-source interactive tool for inspection and intervention in transformer-based language models. This repository includes the code

Mor Geva 110 Dec 28, 2022
Trace any Python program, anywhere!

lptrace lptrace is strace for Python programs. It lets you see in real-time what functions a Python program is running. It's particularly useful to de

Karim Hamidou 687 Nov 20, 2022
Debugging manhole for python applications.

Overview docs tests package Manhole is in-process service that will accept unix domain socket connections and present the stacktraces for all threads

Ionel Cristian Mărieș 332 Dec 7, 2022
(OLD REPO) Line-by-line profiling for Python - Current repo ->

line_profiler and kernprof line_profiler is a module for doing line-by-line profiling of functions. kernprof is a convenient script for running either

Robert Kern 3.6k Jan 6, 2023