Error reported when exiting iPython and returning to UI on Mac OS X
- Dominant language
- Python
- Stars
- 3.2k
- Forks
- 245
- Avg merge
- 13m
- Merged PRs (30d)
- 5
Description
**Describe the bug**
I enter iPython terminal from the debugger UI by pressing !. When I exit (ctrl+d) it returns to the UI.
Upon the second exit from iPython, the following error is shown, which I can then dismiss:
```
The full traceback and some other information can be found below. Please report this information, along with details on what you were < OK
doing at the time the exception occurred, at: https://github.com/inducer/pudb/issues < Save
traceback
python version: 3.11.2 (main, Feb 16 2023, 02:55:59) [Clang 14.0.0 (clang-1400.0.29.202)]
pudb version: 2022.1.3
urwid version: 2.1.2
Traceback (most recent call last):
File "/Users/stephenknox/venv/lib/python3.11/site-packages/pudb/debugger.py", line 2704, in event_loop
toplevel.keypress(self.size, k)
File "/Users/stephenknox/venv/lib/python3.11/site-packages/pudb/ui_tools.py", line 124, in keypress 1
return handler(self, size, key) 50
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/stephenknox/venv/lib/python3.11/site-packages/pudb/debugger.py", line 2071, in run_cmdline
return run_external_cmdline(w, size, key)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/stephenknox/venv/lib/python3.11/site-packages/pudb/debugger.py", line 2063, in run_external_cmdline
runner(curframe.f_globals, curframe.f_locals)
File "/Users/stephenknox/venv/lib/python3.11/site-packages/pudb/shell.py", line 244, in run_ipython_shell
return run_ipython_shell_v11(globals, locals)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/stephenknox/venv/lib/python3.11/site-packages/pudb/shell.py", line 232, in run_ipython_shell_v11
shell.mainloop(*args)
File "/Users/stephenknox/venv/lib/python3.11/site-packages/IPython/terminal/interactiveshell.py", line 900, in mainloop
self.restore_term_title()
File "/Users/stephenknox/venv/lib/python3.11/site-packages/IPython/terminal/interactiveshell.py", line 602, in restore_term_title
restore_term_title()
File "/Users/stephenknox/venv/lib/python3.11/site-packages/IPython/utils/terminal.py", line 115, in restore_term_title
_restore_term_title()
File "/Users/stephenknox/venv/lib/python3.11/site-packages/IPython/utils/terminal.py", line 83, in _restore_term_title_xterm
assert _xterm_term_title_saved
AssertionError
```
**To Reproduce**
Steps to reproduce the behavior:
1. Go to a breakpoint at any part of the code
2. Enter the terminal with '!'
3. exit terminal (ctrl+d)
4. Re-enter terminal (!)
5. Exit terminal again (ctrl + d)
**Expected behavior**
Returns to the debugger without error
**Screenshots**
**Additional context**
Add any other context about the problem here.
**Versions**
What version of pudb? What version of Python?
System: Mac OS X Ventura 13.3.1
python version: 3.11.2
pudb version: 2022.1.3
iPython version: 8.12.0
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.