[New-bugs-announce] [issue1151] "TypeError: expected string, bytes found" instead of KeyboardInterrupt
Eduardo Padoan
report at bugs.python.org
Tue Sep 11 21:26:07 CEST 2007
New submission from Eduardo Padoan:
On revision 54803, interactive mode, on linux: if type ctrl+c you type
ctrl+c, it should raise KeyboardInterrupt, but "TypeError: expected
string, bytes found" printed. Also, I could *not* catch it doing:
>>> try:
... while True: pass
... except KeyboardInterrupt:
... print('Ok')
... except TypeError:
... print('Ops')
Ok
To reproduce:
>>> # press ctrl+c...
TypeError: expected string, bytes found
>>>
It seems that it is simply printing the wrong error...
----------
components: Interpreter Core
messages: 55833
nosy: eopadoan
severity: normal
status: open
title: "TypeError: expected string, bytes found" instead of KeyboardInterrupt
type: behavior
versions: Python 3.0
__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1151>
__________________________________
More information about the New-bugs-announce
mailing list