Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

Commit ecbca35

Browse files
committed
Closes python#28713 uses OSError in the tutorial
1 parent df66b9c commit ecbca35

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Doc/tutorial/errors.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ example::
174174
for arg in sys.argv[1:]:
175175
try:
176176
f = open(arg, 'r')
177-
except IOError:
177+
except OSError:
178178
print('cannot open', arg)
179179
else:
180180
print(arg, 'has', len(f.readlines()), 'lines')

0 commit comments

Comments
 (0)