<type>documentation</type>
<domain>debug</domain>
<id>quick-start</id>
<title>Debugger Quick Start</title>
<date>$Date$</date>
<version>$Revision$</version>
<product>per+</product>

Wing can be used to debug all sorts of Python code, including applications written with
`wxPython <ref:howtos/wxpython>`__, Tkinter, `PyQt <ref:howtos/pyqt>`__, `PyGObject
<ref:howtos/pygobject>`__, `matplotlib <ref:howtos/matplotlib>`__, `Jupyter
<ref:howtos/jupyter>`__ and `pygame <ref:howtos/pygame>`__. Wing can also debug code
written for frameworks like `Django <ref:howtos/django>`__, `Flask <ref:howtos/flask>`__,
`Pyramid <ref:howtos/pyramid>`__, `mod_wsgi <ref:howtos/mod_wsgi>`__, `Plone
<ref:howtos/plone>`__ and `Twisted <ref:howtos/twisted>`__, and code running in an
embedded Python interpreter in the context of a larger application such as `Blender
<ref:howtos/blender>`__, `Maya <ref:howtos/maya>`__, `Nuke <ref:howtos/nuke>`__, and
`Source Filmmaker <ref:howtos/sfm>`__.

~~~if not WING101:
**Note:** This section describes how to get started with Wing's debugger when you are working
with locally stored code that can be launched from the IDE.  If you need to launch
code from outside of the IDE or on a remote host, see the options given in
`Debugger <ref:debug/index>`__.
~~~

Before debugging, you will need to install Python on your system if you have not already
done so. Python is available from `python.org <https://python.org/>`__, or you can
use a distribution like `Anaconda <https://anaconda.com>`__ to also install many
third party libraries.

To start debugging some Python code, open up the file in the editor and then select
``Start / Continue`` from the ``Debug`` menu. This will run to the first breakpoint,
unhandled exception, or until the debug program completes. Select ``Step Into`` instead to
run to the first line of code.  For details see `Starting Debug <ref:debug/starting-debug>`__.

To set breakpoints, just click on the left-most margin next to the source code in the editor.  
~~~if WINGPRO:
In Wing Pro, conditional and ignore-counted breakpoints are also
available from the ``Breakpoint Options`` group in the ``Debug`` menu, or by 
right-clicking on the breakpoints margin.
~~~
For details, see `Setting Breakpoints <ref:debug/setting-breakpoints>`__.

Use the `Debug I/O <ref:debug/debug-process-i-o>`__ tool to view your program's output, or
to enter values for input to the program you are debugging. If your program depends on
characteristics of the Windows Console or a particular Linux/Unix shell, see `External I/O
Consoles <ref:debug/external-i-o-consoles>`__ for more information.

In some cases, you may need to specify a ``Python Executable``, ``Python Path`` or other
environment using `Project Properties <script:view_project_properties>`__ in the
``Project`` menu. Setting the ``Python Executable`` is only necessary if Wing cannot find
Python on your system or if you have more than one version of Python installed. Command
line arguments to use when debugging a file may be set in `File Properties
<ref:proj/file-properties>`__ for the file. See `Debug Environment
<ref:debug/debug-properties>`__ for more options.

There are many other capabilities available in the debugger, as described in the
rest of this chapter and `Advanced Debugging Topics <ref:debug/advanced>`__.
