bpo-44348: Move trace-info to thread-state (GH-26623)

* Move trace-info to thread state.

* Correct output for pdb when turning on tracing in middle of line
This commit is contained in:
Mark Shannon 2021-06-10 08:46:59 +01:00 committed by GitHub
parent e117c02837
commit 54cb63863f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 73 additions and 85 deletions

View file

@ -1288,8 +1288,8 @@ def test_pdb_issue_20766():
-> print('pdb %d: %s' % (i, sess._previous_sigint_handler))
(Pdb) continue
pdb 1: <built-in function default_int_handler>
> <doctest test.test_pdb.test_pdb_issue_20766[0]>(5)test_function()
-> sess.set_trace(sys._getframe())
> <doctest test.test_pdb.test_pdb_issue_20766[0]>(6)test_function()
-> print('pdb %d: %s' % (i, sess._previous_sigint_handler))
(Pdb) continue
pdb 2: <built-in function default_int_handler>
"""