Issue #16261: Converted some bare except statements to except statements

with specified exception type.  Original patch by Ramchandra Apte.
This commit is contained in:
Serhiy Storchaka 2015-05-20 10:33:40 +03:00
parent 492f027793
commit ba9ac5b5c4
7 changed files with 13 additions and 13 deletions

View file

@ -127,7 +127,7 @@ def hexrepr(t, precision=4):
return 'None'
try:
len(t)
except:
except TypeError:
return '0x%0*X' % (precision, t)
try:
return '(' + ', '.join(['0x%0*X' % (precision, item)