inducer / inducer/pudb

pudb, when run on a Python 3.x invoked with -bb, tracebacks

Open
#570 1 comment 0 reactions 0 assignees View on GitHub
Bug
Dominant language
Python
Stars
3.2k
Forks
245
Avg merge
13m
Merged PRs (30d)
5

Description

**Describe the bug**
python3 -bb is for finding comparisons between str and bytes. I am using it to assist with porting some old code from CPython 2.7 to CPython 3.10. pudb appears to be doing at least one such comparison that interferes with its operation when used with python3 -bb. That may or may not be intentional.

The traceback looks like:
```
lqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqk
x Pudb Internal Exception Encountered x
x x
xPudb has encountered and safely caught an internal exception. < OK >x
x < Save >x
xThe full traceback and some other information can be found below. Please report this information, along with details on what you were traceback x
xdoing at the time the exception occurred, at: https://github.com/inducer/pudb/issues x
x x
xpython version: 3.10.2 (main, Mar 2 2022, 03:29:23) [GCC 10.2.1 20210110] x
xpudb version: 2022.1.2 x
xurwid version: 2.1.2 x
xTraceback (most recent call last): x
x File "/usr/local/lib/python3.10/site-packages/pudb/debugger.py", line 460, in user_line x
x self.interaction(frame) x
x File "/usr/local/lib/python3.10/site-packages/pudb/debugger.py", line 426, in interaction x
x self.ui.call_with_ui(self.ui.interaction, exc_tuple, x
x File "/usr/local/lib/python3.10/site-packages/pudb/debugger.py", line 2428, in call_with_ui x
x self.hide() x
x File "/usr/local/lib/python3.10/site-packages/pudb/debugger.py", line 2421, in hide x
x self.screen.stop() x
x File "/usr/local/lib/python3.10/site-packages/urwid/display_common.py", line 821, in stop x
x self._stop() x
x File "/usr/local/lib/python3.10/site-packages/urwid/raw_display.py", line 275, in _stop x
x self.tty_signal_keys(*(self._old_signal_keys + (fd,))) x
x File "/usr/local/lib/python3.10/site-packages/urwid/display_common.py", line 761, in tty_signal_keys x
x if intr == 'undefined': intr = 0 x
xBytesWarning: Comparison between bytes and string x
x x
x x
x x
x x
x x
x x
x x
mqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqj
```
**To Reproduce**
Steps to reproduce the behavior:
1. Debug code with python3 -bb and a pudb.set_trace()
2. Unfortunately, I cannot share the code that is triggering this, but there's a good chance pudb does it frequently

**Expected behavior**
A debugging session that doesn't give a Pudb Internal Exception.

**Screenshots**

**Additional context**

**Versions**

What version of pudb? What version of Python?
pudb v2022.1.2, CPython 3.10.8.

Thanks for the great tool!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.