Alphare created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REVISION SUMMARY
  Pierre Augier signaled on the mailing list that this fails on Pypy and pointed
  out the correct solution.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  mercurial/pycompat.py

CHANGE DETAILS

diff --git a/mercurial/pycompat.py b/mercurial/pycompat.py
--- a/mercurial/pycompat.py
+++ b/mercurial/pycompat.py
@@ -44,6 +44,7 @@
     FileNotFoundError = OSError
 
 else:
+    import builtins
     import concurrent.futures as futures
     import http.cookiejar as cookielib
     import http.client as httplib
@@ -55,7 +56,7 @@
     def future_set_exception_info(f, exc_info):
         f.set_exception(exc_info[0])
 
-    FileNotFoundError = __builtins__['FileNotFoundError']
+    FileNotFoundError = builtins.FileNotFoundError
 
 
 def identity(a):



To: Alphare, #hg-reviewers
Cc: mercurial-patches, mercurial-devel
_______________________________________________
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel

Reply via email to