An add-on for Plone that provides remote debugging via debugpy for developers.
- Remote debugging — activates
debugpyat import time when theDEBUGPY_ENABLEDenvironment variable is set. Supports listening on a configurable host:port and optionally waiting for a debugger client to attach.
No Plone configuration is needed — the add-on reacts to environment variables when the Python process starts.
Set DEBUGPY_ENABLED to 1, true, or y to activate:
DEBUGPY_ENABLED=1 ./bin/instance fg
Use the following env vars to control the debug server:
DEBUGPY_ENABLED- Set to
1,true, oryto enable debugpy. Default: unset (off). DEBUGPY_HOST- Host to bind. Default:
localhost. DEBUGPY_PORT- Port to listen on. Default:
5678. DEBUGPY_WAIT_FOR_CLIENT- Set to
1,true, oryto halt Plone start-up until a debugger client connects. Default: unset (no wait).
Example enabling debugpy with wait-for-client:
DEBUGPY_ENABLED=1 DEBUGPY_WAIT_FOR_CLIENT=1 ./bin/instance fg
Any debugpy-compatible client (VS Code, PyCharm, ptvsd, etc.) can then
connect to localhost:5678.
Add collective.debugtools to your buildout:
[buildout]
...
eggs =
collective.debugtools
Then run bin/buildout and install the add-on in Plone's Add-ons control
panel.
Alternatively, install via pip in a Plone environment:
pip install collective.debugtools
- Issue Tracker: https://github.com/collective/collective.debugtools/issues
- Source Code: https://github.com/collective/collective.debugtools
The project is licensed under the GPLv2.