Patchwork D6614: py3: don't run source transformer on hgext3rd (extensions)

login
register
mail settings
Submitter phabricator
Date July 8, 2019, 10:04 p.m.
Message ID <51888fef0dd72fa4fb69cd8122159d06@localhost.localdomain>
Download mbox | patch
Permalink /patch/40840/
State Not Applicable
Headers show

Comments

phabricator - July 8, 2019, 10:04 p.m.
Closed by commit rHGd28d91f9f35a: py3: don&#039;t run source transformer on hgext3rd (extensions) (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D6614?vs=15794&id=15823

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D6614/new/

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

AFFECTED FILES
  mercurial/__init__.py
  relnotes/next

CHANGE DETAILS




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

Patch

diff --git a/relnotes/next b/relnotes/next
--- a/relnotes/next
+++ b/relnotes/next
@@ -73,3 +73,7 @@ 
    `addunfinished()` in `state` module.
 
  * `cmdutil.checkunfinished()` now includes detection for merge too.
+
+ * We used to automatically attempt to make extensions compatible with
+   Python 3 (by translating their source code while loading it). We no
+   longer do that.
diff --git a/mercurial/__init__.py b/mercurial/__init__.py
--- a/mercurial/__init__.py
+++ b/mercurial/__init__.py
@@ -29,7 +29,7 @@ 
         """A sys.meta_path finder that uses a custom module loader."""
         def find_spec(self, fullname, path, target=None):
             # Only handle Mercurial-related modules.
-            if not fullname.startswith(('mercurial.', 'hgext.', 'hgext3rd.')):
+            if not fullname.startswith(('mercurial.', 'hgext.')):
                 return None
             # don't try to parse binary
             if fullname.startswith('mercurial.cext.'):