Use breakpoint() to print out filename, line number, and data.
Project description
PrintBreakpoint
Use breakpoint() to print out filename, line number, and data. For Python 3.7+
Install printbreakpoint with pip.
pip install printbreakpoint
Update the PYTHONBREAKPOINT environment variable (available starting in Python 3.7).
export PYTHONBREAKPOINT=printbreakpoint.pb
Now when you add breakpoint() to your code, it will show the output from printbreakpoint.
def some_function(a):
breakpoint()
return a
Prints
pb | some_file.py:3 in some_function
Any data you pass to the breakpoint() will be added to the output.
Change the environment variable back to the default when you’re ready to continue using pdb.
export PYTHONBREAKPOINT=
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
printbreakpoint-0.9.8.tar.gz
(2.6 kB
view hashes)
Built Distribution
Close
Hashes for printbreakpoint-0.9.8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 06a6e5a9804a7d7b58418300c7edea2aad7a4c87877766701ab5f9dca1d6699f |
|
MD5 | b86de0e03819f3646ac529b95a391e9b |
|
BLAKE2b-256 | dbc88611de1b28297bdc31366e6a56d144b349a6ec30c55d36423673882e40d8 |