D3613: py3: use `except error as e` instead of `except error, e`

pulkit (Pulkit Goyal) phabricator at mercurial-scm.org
Sat May 19 10:41:34 EDT 2018


pulkit created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  The latter throws SyntaxError on Python 3.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D3613

AFFECTED FILES
  tests/test-parseindex.t

CHANGE DETAILS

diff --git a/tests/test-parseindex.t b/tests/test-parseindex.t
--- a/tests/test-parseindex.t
+++ b/tests/test-parseindex.t
@@ -184,7 +184,7 @@
   >     try:
   >         f()
   >         print('uncaught buffer overflow?')
-  >     except ValueError, inst:
+  >     except ValueError as inst:
   >         print(inst)
   > EOF
 



To: pulkit, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list