mirror of
https://github.com/python/cpython.git
synced 2025-11-02 03:01:58 +00:00
PEP 553 built-in breakpoint() function (bpo-31353) (#3355)
Implement PEP 553, built-in breakpoint() with support from sys.breakpointhook(), along with documentation and tests. Closes bpo-31353
This commit is contained in:
parent
4d07189788
commit
36c1d1f1e5
9 changed files with 324 additions and 23 deletions
|
|
@ -502,6 +502,18 @@ conflict.
|
|||
:option:`-O` multiple times.
|
||||
|
||||
|
||||
.. envvar:: PYTHONBREAKPOINT
|
||||
|
||||
If this is set, it names a callable using dotted-path notation. The module
|
||||
containing the callable will be imported and then the callable will be run
|
||||
by the default implementation of :func:`sys.breakpointhook` which itself is
|
||||
called by built-in :func:`breakpoint`. If not set, or set to the empty
|
||||
string, it is equivalent to the value "pdb.set_trace". Setting this to the
|
||||
string "0" causes the default implementation of :func:`sys.breakpointhook`
|
||||
to do nothing but return immediately.
|
||||
|
||||
.. versionadded:: 3.7
|
||||
|
||||
.. envvar:: PYTHONDEBUG
|
||||
|
||||
If this is set to a non-empty string it is equivalent to specifying the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue