Created
July 18, 2021 12:53
-
-
Save jaraco/f302fc468d4fd48b647490d79f787a3a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cpython bpo-44461-refactor-targets $ git diff | |
diff --git a/Lib/pdb.py b/Lib/pdb.py | |
index b1f0c7fab0..ca0bbbbd8f 100755 | |
--- a/Lib/pdb.py | |
+++ b/Lib/pdb.py | |
@@ -1566,6 +1566,7 @@ def lookupmodule(self, filename): | |
@functools.singledispatchmethod | |
def _run(self, target: 'ModuleTarget'): | |
+ raise ValueError('module!') | |
self._wait_for_mainpyfile = True | |
self._user_requested_quit = False | |
mod_name, mod_spec, code = target.details | |
@@ -1601,6 +1602,7 @@ def _(self, filename: 'ScriptTarget'): | |
# events depends on python version). So we take special measures to | |
# avoid stopping before we reach the main script (see user_line and | |
# user_call for details). | |
+ raise ValueError('script!') | |
self._wait_for_mainpyfile = True | |
self.mainpyfile = self.canonic(filename) | |
self._user_requested_quit = False | |
cpython bpo-44461-refactor-targets $ ./python.exe Lib/test/regrtest.py test_pdb -v | |
== CPython 3.11.0a0 (heads/bpo-44461:125a17caa4, Jun 30 2021, 17:53:34) [Clang 12.0.5 (clang-1205.0.22.11)] | |
== macOS-11.4-x86_64-i386-64bit little-endian | |
== cwd: /Users/jaraco/code/public/cpython/build/test_python_49822æ | |
== CPU count: 8 | |
== encodings: locale=UTF-8, FS=utf-8 | |
0:00:00 load avg: 1.70 Run tests sequentially | |
0:00:00 load avg: 1.70 [1/1] test_pdb | |
test_blocks_at_first_code_line (test.test_pdb.PdbTestCase) ... FAIL | |
test_breakpoint (test.test_pdb.PdbTestCase) ... FAIL | |
test_errors_in_command (test.test_pdb.PdbTestCase) ... FAIL | |
test_find_function_empty_file (test.test_pdb.PdbTestCase) ... ok | |
test_find_function_found (test.test_pdb.PdbTestCase) ... ok | |
test_find_function_found_with_bom (test.test_pdb.PdbTestCase) ... ok | |
test_find_function_found_with_encoding_cookie (test.test_pdb.PdbTestCase) ... ok | |
test_header (test.test_pdb.PdbTestCase) ... ok | |
test_issue13120 (test.test_pdb.PdbTestCase) ... ok | |
test_issue13183 (test.test_pdb.PdbTestCase) ... FAIL | |
test_issue16180 (test.test_pdb.PdbTestCase) ... FAIL | |
test_issue26053 (test.test_pdb.PdbTestCase) ... FAIL | |
test_issue36250 (test.test_pdb.PdbTestCase) ... ok | |
test_issue42383 (test.test_pdb.PdbTestCase) ... FAIL | |
test_issue42384 (test.test_pdb.PdbTestCase) | |
When running `python foo.py` sys.path[0] is an absolute path. `python -m pdb foo.py` should behave the same ... FAIL | |
test_issue42384_symlink (test.test_pdb.PdbTestCase) | |
When running `python foo.py` sys.path[0] resolves symlinks. `python -m pdb foo.py` should behave the same ... FAIL | |
test_issue7964 (test.test_pdb.PdbTestCase) ... ok | |
test_module_is_run_as_main (test.test_pdb.PdbTestCase) ... FAIL | |
test_module_without_a_main (test.test_pdb.PdbTestCase) ... FAIL | |
test_readrc_homedir (test.test_pdb.PdbTestCase) ... ok | |
test_readrc_kwarg (test.test_pdb.PdbTestCase) ... ok | |
test_relative_imports (test.test_pdb.PdbTestCase) ... FAIL | |
test_relative_imports_on_plain_module (test.test_pdb.PdbTestCase) ... FAIL | |
test_run_module (test.test_pdb.PdbTestCase) ... FAIL | |
test_run_pdb_with_pdb (test.test_pdb.PdbTestCase) ... FAIL | |
test_checkline_after_reset (test.test_pdb.ChecklineTests) ... ok | |
test_checkline_before_debugging (test.test_pdb.ChecklineTests) ... ok | |
test_checkline_is_not_executable (test.test_pdb.ChecklineTests) ... End of file | |
*** Blank or comment | |
*** Blank or comment | |
*** Blank or comment | |
*** Blank or comment | |
*** Blank or comment | |
End of file | |
ok | |
test_list_commands (test.test_pdb) | |
Doctest: test.test_pdb.test_list_commands ... ok | |
test_next_until_return_at_return_event (test.test_pdb) | |
Doctest: test.test_pdb.test_next_until_return_at_return_event ... ok | |
test_pdb_basic_commands (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_basic_commands ... ok | |
test_pdb_breakpoint_commands (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_breakpoint_commands ... ok | |
test_pdb_breakpoints_preserved_across_interactive_sessions (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_breakpoints_preserved_across_interactive_sessions ... ok | |
test_pdb_continue_in_bottomframe (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_continue_in_bottomframe ... ok | |
test_pdb_displayhook (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_displayhook ... ok | |
test_pdb_issue_20766 (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_issue_20766 ... ok | |
test_pdb_issue_43318 (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_issue_43318 ... ok | |
test_pdb_next_command_for_asyncgen (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_next_command_for_asyncgen ... ok | |
test_pdb_next_command_for_coroutine (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_next_command_for_coroutine ... ok | |
test_pdb_next_command_for_generator (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_next_command_for_generator ... ok | |
test_pdb_next_command_in_generator_for_loop (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_next_command_in_generator_for_loop ... ok | |
test_pdb_next_command_subiterator (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_next_command_subiterator ... ok | |
test_pdb_pp_repr_exc (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_pp_repr_exc ... ok | |
test_pdb_return_command_for_coroutine (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_return_command_for_coroutine ... ok | |
test_pdb_return_command_for_generator (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_return_command_for_generator ... ok | |
test_pdb_run_with_code_object (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_run_with_code_object ... ok | |
test_pdb_run_with_incorrect_argument (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_run_with_incorrect_argument ... ok | |
test_pdb_skip_modules (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_skip_modules ... ok | |
test_pdb_skip_modules_with_callback (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_skip_modules_with_callback ... ok | |
test_pdb_until_command_for_coroutine (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_until_command_for_coroutine ... ok | |
test_pdb_until_command_for_generator (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_until_command_for_generator ... ok | |
test_pdb_whatis_command (test.test_pdb) | |
Doctest: test.test_pdb.test_pdb_whatis_command ... ok | |
test_post_mortem (test.test_pdb) | |
Doctest: test.test_pdb.test_post_mortem ... ok | |
====================================================================== | |
FAIL: test_blocks_at_first_code_line (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1708, in test_blocks_at_first_code_line | |
self.assertTrue(any("__main__.py(4)<module>()" | |
AssertionError: False is not true : Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run() | |
-> raise ValueError('module!') | |
(Pdb) (Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1148, in do_quit | |
self.set_quit() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 358, in set_quit | |
self.stopframe = self.botframe | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
====================================================================== | |
FAIL: test_breakpoint (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1672, in test_breakpoint | |
self.assertTrue(any("Breakpoint 1 at" in l for l in stdout.splitlines()), stdout) | |
AssertionError: False is not true : Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run() | |
-> raise ValueError('module!') | |
(Pdb) (Pdb) *** Blank or comment | |
(Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1148, in do_quit | |
self.set_quit() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 358, in set_quit | |
self.stopframe = self.botframe | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
====================================================================== | |
FAIL: test_errors_in_command (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1788, in test_errors_in_command | |
self.assertEqual(stdout.splitlines()[1:], [ | |
AssertionError: Lists differ: [' File "/Users/jaraco/code/public/cpython[2287 chars]GER'] != ['-> pass', "(Pdb) *** SyntaxError: '(' was[283 chars]b) '] | |
First differing element 0: | |
' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main' | |
'-> pass' | |
First list contains 36 additional elements. | |
First extra element 10: | |
"-> raise ValueError('script!')" | |
Diff is 2862 characters long. Set self.maxDiff to None to see it. | |
====================================================================== | |
FAIL: test_issue13183 (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1498, in test_issue13183 | |
self.assertTrue( | |
AssertionError: False is not true : Fail to step into the caller after a return | |
====================================================================== | |
FAIL: test_issue16180 (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1566, in test_issue16180 | |
self.assertIn(expected, stdout, | |
AssertionError: 'SyntaxError:' not found in 'Traceback (most recent call last):\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main\n pdb._run(target)\n File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method\n return method.__get__(obj, cls)(*args, **kwargs)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1605, in _\n raise ValueError(\'script!\')\nValueError: script!\nUncaught exception. Entering post mortem debugging\nRunning \'cont\' or \'step\' will restart the program\n> /Users/jaraco/code/public/cpython/Lib/pdb.py(1605)_()\n-> raise ValueError(\'script!\')\n(Pdb) Traceback (most recent call last):\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main\n pdb._run(target)\n File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method\n return method.__get__(obj, cls)(*args, **kwargs)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1605, in _\n raise ValueError(\'script!\')\nValueError: script!\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main\n return _run_code(code, main_globals, None,\n File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code\n exec(code, run_globals)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module>\n pdb.main()\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main\n pdb.interaction(None, t)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction\n self._cmdloop()\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop\n self.cmdloop()\n File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop\n stop = self.onecmd(line)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd\n return cmd.Cmd.onecmd(self, line)\n File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd\n return func(arg)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1160, in do_EOF\n self.set_quit()\n File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 358, in set_quit\n self.stopframe = self.botframe\nAttributeError: \'Pdb\' object has no attribute \'botframe\'. Did you mean: \'curframe\'?\n\n' : | |
Expected: | |
SyntaxError: | |
Got: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1605, in _ | |
raise ValueError('script!') | |
ValueError: script! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1605)_() | |
-> raise ValueError('script!') | |
(Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1605, in _ | |
raise ValueError('script!') | |
ValueError: script! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1160, in do_EOF | |
self.set_quit() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 358, in set_quit | |
self.stopframe = self.botframe | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
Fail to handle a syntax error in the debuggee. | |
====================================================================== | |
FAIL: test_issue26053 (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1582, in test_issue26053 | |
self.assertRegex(res, "Restarting .* with arguments:\na b c") | |
AssertionError: Regex didn't match: 'Restarting .* with arguments:\na b c' not found in 'Traceback (most recent call last):\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main\npdb._run(target)\nFile "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method\nreturn method.__get__(obj, cls)(*args, **kwargs)\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1605, in _\nraise ValueError(\'script!\')\nValueError: script!\nUncaught exception. Entering post mortem debugging\nRunning \'cont\' or \'step\' will restart the program\n> /Users/jaraco/code/public/cpython/Lib/pdb.py(1605)_()\n-> raise ValueError(\'script!\')\n(Pdb) (Pdb) Traceback (most recent call last):\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main\npdb._run(target)\nFile "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method\nreturn method.__get__(obj, cls)(*args, **kwargs)\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1605, in _\nraise ValueError(\'script!\')\nValueError: script!\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\nFile "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main\nreturn _run_code(code, main_globals, None,\nFile "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code\nexec(code, run_globals)\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module>\npdb.main()\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main\npdb.interaction(None, t)\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction\nself._cmdloop()\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop\nself.cmdloop()\nFile "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop\nstop = self.onecmd(line)\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd\nreturn cmd.Cmd.onecmd(self, line)\nFile "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd\nreturn func(arg)\nFile "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1088, in do_continue\nself.set_continue()\nFile "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 344, in set_continue\nself._set_stopinfo(self.botframe, None, -1)\nAttributeError: \'Pdb\' object has no attribute \'botframe\'. Did you mean: \'curframe\'?' | |
====================================================================== | |
FAIL: test_issue42383 (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1865, in test_issue42383 | |
self.assertEqual(stdout.split('\n')[6].rstrip('\r'), expected) | |
AssertionError: " raise ValueError('script!')" != '(Pdb) The correct file was executed' | |
- raise ValueError('script!') | |
+ (Pdb) The correct file was executed | |
====================================================================== | |
FAIL: test_issue42384 (test.test_pdb.PdbTestCase) | |
When running `python foo.py` sys.path[0] is an absolute path. `python -m pdb foo.py` should behave the same | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1817, in test_issue42384 | |
self.assertEqual(stdout.split('\n')[2].rstrip('\r'), expected) | |
AssertionError: ' pdb._run(target)' != '(Pdb) sys.path[0] is /Users/jaraco/code/p[42 chars]pcwd' | |
- pdb._run(target) | |
+ (Pdb) sys.path[0] is /Users/jaraco/code/public/cpython/build/test_python_49822æ/tempcwd | |
====================================================================== | |
FAIL: test_issue42384_symlink (test.test_pdb.PdbTestCase) | |
When running `python foo.py` sys.path[0] resolves symlinks. `python -m pdb foo.py` should behave the same | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1842, in test_issue42384_symlink | |
self.assertEqual(stdout.split('\n')[2].rstrip('\r'), expected) | |
AssertionError: ' pdb._run(target)' != '(Pdb) sys.path[0] is /Users/jaraco/code/p[50 chars]_one' | |
- pdb._run(target) | |
+ (Pdb) sys.path[0] is /Users/jaraco/code/public/cpython/build/test_python_49822æ/tempcwd/dir_one | |
====================================================================== | |
FAIL: test_module_is_run_as_main (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1658, in test_module_is_run_as_main | |
self.assertTrue(any("SUCCESS" in l for l in stdout.splitlines()), stdout) | |
AssertionError: False is not true : Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run() | |
-> raise ValueError('module!') | |
(Pdb) (Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1088, in do_continue | |
self.set_continue() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 344, in set_continue | |
self._set_stopinfo(self.botframe, None, -1) | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
====================================================================== | |
FAIL: test_module_without_a_main (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1695, in test_module_without_a_main | |
self.assertIn("ImportError: No module named t_main.__main__", | |
AssertionError: 'ImportError: No module named t_main.__main__' not found in ['Traceback (most recent call last):', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main', ' pdb._run(target)', ' File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method', ' return method.__get__(obj, cls)(*args, **kwargs)', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run', " raise ValueError('module!')", 'ValueError: module!', 'Uncaught exception. Entering post mortem debugging', "Running 'cont' or 'step' will restart the program", '> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run()', "-> raise ValueError('module!')", '(Pdb) Traceback (most recent call last):', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main', ' pdb._run(target)', ' File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method', ' return method.__get__(obj, cls)(*args, **kwargs)', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run', " raise ValueError('module!')", 'ValueError: module!', '', 'During handling of the above exception, another exception occurred:', '', 'Traceback (most recent call last):', ' File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main', ' return _run_code(code, main_globals, None,', ' File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code', ' exec(code, run_globals)', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module>', ' pdb.main()', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main', ' pdb.interaction(None, t)', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction', ' self._cmdloop()', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop', ' self.cmdloop()', ' File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop', ' stop = self.onecmd(line)', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd', ' return cmd.Cmd.onecmd(self, line)', ' File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd', ' return func(arg)', ' File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1160, in do_EOF', ' self.set_quit()', ' File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 358, in set_quit', ' self.stopframe = self.botframe', "AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'?", ''] | |
====================================================================== | |
FAIL: test_relative_imports (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1744, in test_relative_imports | |
self.assertTrue(any("VAR from module" in l for l in stdout.splitlines()), stdout) | |
AssertionError: False is not true : Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run() | |
-> raise ValueError('module!') | |
(Pdb) (Pdb) Breakpoint 1 at /Users/jaraco/code/public/cpython/Lib/pdb.py:5 | |
(Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1088, in do_continue | |
self.set_continue() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 344, in set_continue | |
self._set_stopinfo(self.botframe, None, -1) | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
====================================================================== | |
FAIL: test_relative_imports_on_plain_module (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1777, in test_relative_imports_on_plain_module | |
self.assertTrue(any("VAR from module" in l for l in stdout.splitlines()), stdout) | |
AssertionError: False is not true : Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run() | |
-> raise ValueError('module!') | |
(Pdb) (Pdb) *** Blank or comment | |
(Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1088, in do_continue | |
self.set_continue() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 344, in set_continue | |
self._set_stopinfo(self.botframe, None, -1) | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
====================================================================== | |
FAIL: test_run_module (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1646, in test_run_module | |
self.assertTrue(any("SUCCESS" in l for l in stdout.splitlines()), stdout) | |
AssertionError: False is not true : Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
Uncaught exception. Entering post mortem debugging | |
Running 'cont' or 'step' will restart the program | |
> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run() | |
-> raise ValueError('module!') | |
(Pdb) (Pdb) Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main | |
pdb._run(target) | |
File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method | |
return method.__get__(obj, cls)(*args, **kwargs) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run | |
raise ValueError('module!') | |
ValueError: module! | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main | |
return _run_code(code, main_globals, None, | |
File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code | |
exec(code, run_globals) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module> | |
pdb.main() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main | |
pdb.interaction(None, t) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction | |
self._cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop | |
self.cmdloop() | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop | |
stop = self.onecmd(line) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd | |
return cmd.Cmd.onecmd(self, line) | |
File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd | |
return func(arg) | |
File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1088, in do_continue | |
self.set_continue() | |
File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 344, in set_continue | |
self._set_stopinfo(self.botframe, None, -1) | |
AttributeError: 'Pdb' object has no attribute 'botframe'. Did you mean: 'curframe'? | |
====================================================================== | |
FAIL: test_run_pdb_with_pdb (test.test_pdb.PdbTestCase) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/Users/jaraco/code/public/cpython/Lib/test/test_pdb.py", line 1681, in test_run_pdb_with_pdb | |
self.assertIn( | |
AssertionError: 'usage: pdb.py [-c command] ... [-m module | pyfile] [arg] ...\n\nDebug the Python program given by pyfile. Alternatively,\nan executable module or package to debug can be specified using\nthe -m switch.\n\nInitial commands are read from .pdbrc files in your home directory\nand in the current directory, if they exist. Commands supplied with\n-c are executed after commands from .pdbrc files.\n\nTo let the script run until an exception occurs, use "-c continue".\nTo let the script run up to a given line X in the debugged file, use\n"-c \'until X\'".' not found in 'Traceback (most recent call last):\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main\n pdb._run(target)\n File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method\n return method.__get__(obj, cls)(*args, **kwargs)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run\n raise ValueError(\'module!\')\nValueError: module!\nUncaught exception. Entering post mortem debugging\nRunning \'cont\' or \'step\' will restart the program\n> /Users/jaraco/code/public/cpython/Lib/pdb.py(1569)_run()\n-> raise ValueError(\'module!\')\n(Pdb) (Pdb) Traceback (most recent call last):\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1733, in main\n pdb._run(target)\n File "/Users/jaraco/code/public/cpython/Lib/functools.py", line 915, in _method\n return method.__get__(obj, cls)(*args, **kwargs)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1569, in _run\n raise ValueError(\'module!\')\nValueError: module!\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 196, in _run_module_as_main\n return _run_code(code, main_globals, None,\n File "/Users/jaraco/code/public/cpython/Lib/runpy.py", line 86, in _run_code\n exec(code, run_globals)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1760, in <module>\n pdb.main()\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1752, in main\n pdb.interaction(None, t)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 387, in interaction\n self._cmdloop()\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 352, in _cmdloop\n self.cmdloop()\n File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 138, in cmdloop\n stop = self.onecmd(line)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 452, in onecmd\n return cmd.Cmd.onecmd(self, line)\n File "/Users/jaraco/code/public/cpython/Lib/cmd.py", line 217, in onecmd\n return func(arg)\n File "/Users/jaraco/code/public/cpython/Lib/pdb.py", line 1088, in do_continue\n self.set_continue()\n File "/Users/jaraco/code/public/cpython/Lib/bdb.py", line 344, in set_continue\n self._set_stopinfo(self.botframe, None, -1)\nAttributeError: \'Pdb\' object has no attribute \'botframe\'. Did you mean: \'curframe\'?\n' | |
---------------------------------------------------------------------- | |
Ran 53 tests in 1.099s | |
FAILED (failures=15) | |
test_pdb failed | |
== Tests result: FAILURE == | |
1 test failed: | |
test_pdb | |
Total duration: 1.2 sec | |
Tests result: FAILURE | |
test test_pdb failed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment