From b940e113bf90ff71b0ef57414ea2beea9d2a4bc0 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Wed, 10 Jan 2007 16:19:56 +0000 Subject: SF patch 1631942 by Collin Winter: (a) "except E, V" -> "except E as V" (b) V is now limited to a simple name (local variable) (c) V is now deleted at the end of the except block --- Lib/test/test_strptime.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Lib/test/test_strptime.py') diff --git a/Lib/test/test_strptime.py b/Lib/test/test_strptime.py index ba65649857e..df94f7b5f6d 100644 --- a/Lib/test/test_strptime.py +++ b/Lib/test/test_strptime.py @@ -206,7 +206,7 @@ class StrptimeTests(unittest.TestCase): _strptime.strptime("2005", bad_format) except ValueError: continue - except Exception, err: + except Exception as err: self.fail("'%s' raised %s, not ValueError" % (bad_format, err.__class__.__name__)) else: -- cgit v1.2.3