diff mercurial/localrepo.py @ 42135:b970fece153d

compression: only declare revlog support for available engine Even if we know that an engine support revlog compression, the Mercurial process still won't support it if the compression engine is not available.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Tue, 16 Apr 2019 15:10:16 +0200
parents 70b71421fd33
children 10a6725dca6e
line wrap: on
line diff
--- a/mercurial/localrepo.py	Mon Apr 15 19:21:41 2019 +0300
+++ b/mercurial/localrepo.py	Tue Apr 16 15:10:16 2019 +0200
@@ -643,7 +643,7 @@
     # Add derived requirements from registered compression engines.
     for name in util.compengines:
         engine = util.compengines[name]
-        if engine.revlogheader():
+        if engine.available() and engine.revlogheader():
             supported.add(b'exp-compression-%s' % name)
 
     return supported