Patchwork setup: ignore message about disabling 3rd party extensions because of version

login
register
mail settings
Submitter Matt Harbison
Date Oct. 3, 2018, 2:45 a.m.
Message ID <37e915597429089cdb9c.1538534756@Envy>
Download mbox | patch
Permalink /patch/35344/
State Accepted
Headers show

Comments

Matt Harbison - Oct. 3, 2018, 2:45 a.m.
# HG changeset patch
# User Matt Harbison <matt_harbison@yahoo.com>
# Date 1538534401 14400
#      Tue Oct 02 22:40:01 2018 -0400
# Node ID 37e915597429089cdb9c0a2e609d10ba55278b4f
# Parent  731961d972ba9ff5e3d473846e711b609121b496
setup: ignore message about disabling 3rd party extensions because of version

I started getting into a bind recently when switching between py2 and py3
because switching requires a `make clean`, which kills __version__.py.  But then
when running `make local`, it picks up the local hg.exe (MSYS seems to prefix
$PATH with '.'), which doesn't know its version.  That causes it to emit a
warning about needing at least 4.3 to load evolve, which caused setup.py to fail
saying there is no working hg executable to figure out the version.  If we can
ignore general extension import failures, we should be able to ignore this too.
Yuya Nishihara - Oct. 3, 2018, 11:43 a.m.
On Tue, 02 Oct 2018 22:45:56 -0400, Matt Harbison wrote:
> # HG changeset patch
> # User Matt Harbison <matt_harbison@yahoo.com>
> # Date 1538534401 14400
> #      Tue Oct 02 22:40:01 2018 -0400
> # Node ID 37e915597429089cdb9c0a2e609d10ba55278b4f
> # Parent  731961d972ba9ff5e3d473846e711b609121b496
> setup: ignore message about disabling 3rd party extensions because of version

Queued, thanks.

Patch

diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -262,7 +262,9 @@  def filterhgerr(err):
                and not e.startswith(b'warning: Not importing')
                and not e.startswith(b'obsolete feature not enabled')
                and not e.startswith(b'*** failed to import extension')
-               and not e.startswith(b'devel-warn:'))]
+               and not e.startswith(b'devel-warn:')
+               and not (e.startswith(b'(third party extension')
+                        and e.endswith(b'or newer of Mercurial; disabling)')))]
     return b'\n'.join(b'  ' + e for e in err)
 
 def findhg():