From ecbca357c95ff1808fd3cca30253af3f34bc6ffa Mon Sep 17 00:00:00 2001 From: Kushal Das Date: Wed, 16 Nov 2016 21:13:43 +0530 Subject: Closes #28713 uses OSError in the tutorial --- Doc/tutorial/errors.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/tutorial/errors.rst b/Doc/tutorial/errors.rst index 759588f..aba61da 100644 --- a/Doc/tutorial/errors.rst +++ b/Doc/tutorial/errors.rst @@ -174,7 +174,7 @@ example:: for arg in sys.argv[1:]: try: f = open(arg, 'r') - except IOError: + except OSError: print('cannot open', arg) else: print(arg, 'has', len(f.readlines()), 'lines') -- cgit v0.12