Skip to content
Snippets Groups Projects
Commit 5e0164a76aa0 authored by Pierre-Yves David's avatar Pierre-Yves David :octopus:
Browse files

rust: fix the compatibility checks

I am not sure what the previous code was trying to achieve... but this should
work fine.
parent de5e038152f6
No related branches found
No related tags found
No related merge requests found
...@@ -330,22 +330,14 @@ ...@@ -330,22 +330,14 @@
# Don't use `subprocess.PIPE` as it can deadlock (see docs). # Don't use `subprocess.PIPE` as it can deadlock (see docs).
# We capture `stderr` because the error message from `hg log` would # We capture `stderr` because the error message from `hg log` would
# make it seem like there was a bug. # make it seem like there was a bug.
with open(os.devnull, "w") as FNULL: currentrev = self.get_asv_rev()
try: revset = "94167e701e125dce1788e19b1e1489958235e40c::"
self.hg( if not self._matchrevset(revset, currentrev):
"log", raise NotImplementedError(
"-r", "Rust modulepolicy was not implemented before "
"94167e701e125dce1788e19b1e1489958235e40c", "revision 94167e701e12"
stderr=FNULL, ", skipping."
) )
except subprocess.CalledProcessError as e:
if e.returncode == 255:
raise NotImplementedError(
"Rust modulepolicy was not implemented before "
"revision 94167e701e125dce1788e19b1e1489958235e40c"
", skipping."
)
raise
def _matchrevset(self, revset, target_rev): def _matchrevset(self, revset, target_rev):
"""return True if <target-rev> is within <revset>""" """return True if <target-rev> is within <revset>"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment