contrib/synthrepo.py
changeset 25660 328739ea70c3
parent 25186 80c5b2666a96
child 26587 56b2bcea2529
--- a/contrib/synthrepo.py	Tue Jun 23 22:38:21 2015 -0700
+++ b/contrib/synthrepo.py	Tue Jun 23 22:20:08 2015 -0700
@@ -253,7 +253,7 @@
     '''
     try:
         fp = hg.openpath(ui, descpath)
-    except Exception, err:
+    except Exception as err:
         raise util.Abort('%s: %s' % (descpath, err[0].strerror))
     desc = json.load(fp)
     fp.close()
@@ -285,7 +285,7 @@
     dictfile = opts.get('dict') or '/usr/share/dict/words'
     try:
         fp = open(dictfile, 'rU')
-    except IOError, err:
+    except IOError as err:
         raise util.Abort('%s: %s' % (dictfile, err.strerror))
     words = fp.read().splitlines()
     fp.close()