mirror of
https://github.com/python/cpython.git
synced 2025-10-14 18:59:46 +00:00
handle class exceptions
This commit is contained in:
parent
cebfa70a79
commit
c7acf2a106
4 changed files with 26 additions and 10 deletions
|
@ -74,7 +74,10 @@ def browserexec(tb, cmd):
|
|||
exec(cmd+'\n', globals, locals)
|
||||
except:
|
||||
print '*** Exception:',
|
||||
print sys.exc_type,
|
||||
if type(sys.exc_type) == type(''):
|
||||
print sys.exc_type,
|
||||
else:
|
||||
print sys.exc_type.__name__,
|
||||
if sys.exc_value <> None:
|
||||
print ':', sys.exc_value,
|
||||
print
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue