Wing Pro's debugger provides a powerful toolset for rapidly locating and fixing bugs in single and multi-threaded Python code, and in a single or multi-processing environment. The debugger supports breakpoints, stepping through code, inspecting and changing stack or module data, watch points, expression evaluation, and command shell style interaction with the paused debug process.
There are a number of ways to use Wing's debugger. Which you use depends on where your code is running, and how it is invoked:
Local Stand-Alone Code -- Wing can debug stand-alone scripts and applications that run on your local machine and that are launched on demand from within Wing. The next documentation page describes this in more detail.
Remote Stand-Alone Code -- Wing Pro can debug stand-alone code remotely in the same way as it debugs locally running code. This is done by configuring a remote host to which Wing will connect via SSH tunnel. For details on this, see Remote Hosts.
Local Embedded or Externally Launched Code -- Wing can also debug code that runs within a web server, in an embedded Python instance (for example as a script that controls a larger application), and other code that cannot be directly launched from the IDE. For details, see Debugging Externally Launched Code.
Remote Embedded or Externally Launched Code -- Finally, Wing can debug externally launched or embedded code that is running on another host. For details, see Remote Debugging.
Because the debugger core is written in optimized C, debug overhead is relatively low. However, you should expect your programs to run 25-50% slower within the debugger in more code. Overhead is proportional to number of Python byte codes executed, so code that does a lot of work in Python and very little in support libraries will incur more overhead.
Wing Personal and Wing 101 omit some of the above features.
12.0. Quick Start
12.1. Specifying Main Entry Point
12.1.0. Named Entry Points
12.2. Debug Properties
12.3. Setting Breakpoints
12.4. Starting Debug
12.5. Debugger Status
12.6. Flow Control
12.7. Viewing the Stack
12.8. Viewing Debug Data
12.8.0. Stack Data View
18.104.22.168. Popup Menu Options
22.214.171.124. Filtering Value Display
12.8.1. Watching Values
12.8.2. Evaluating Expressions
12.8.3. Problems Handling Values
12.9. Debug Process I/O
12.9.0. External I/O Consoles
12.9.1. Disabling Debug Process I/O Multiplexing
12.10. Interactive Debug Probe
12.10.0. Managing Program State
12.10.1. Debugging Code Recursively
12.10.2. Debug Probe Options
12.11. Multi-Process Debugging
12.12. Debugging Multi-threaded Code
12.13. Managing Exceptions
12.14. Running Without Debug