Skip to content

Commit 0a6c0cd

Browse files
author
Marc Hartmayer
committed
pkgutil: fix Python3 compatibility
Starting with Python3 the `as` clause must be used to associate a name to the exception being passed.
1 parent 444b7d6 commit 0a6c0cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mitogen/compat/pkgutil.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,7 @@ def extend_path(path, name):
542542
if os.path.isfile(pkgfile):
543543
try:
544544
f = open(pkgfile)
545-
except IOError, msg:
545+
except IOError as msg:
546546
sys.stderr.write("Can't open %s: %s\n" %
547547
(pkgfile, msg))
548548
else:

0 commit comments

Comments
 (0)