Commit 642bae6f by Arun Babu Neelicattu Committed by GitHub

installer: fix upgrade support check on scm version (#4126)

parent 73ff7bcc
......@@ -415,10 +415,15 @@ class Installer:
def _is_self_upgrade_supported(x):
mx = self.VERSION_REGEX.match(x)
if mx is None:
# the version is not semver, perhaps scm or file, we assume upgrade is supported
return True
vx = tuple(int(p) for p in mx.groups()[:3]) + (mx.group(5),)
return vx >= (1, 2, 0)
if not _is_self_upgrade_supported(version):
if version and not _is_self_upgrade_supported(version):
self._write(
colorize(
"warning",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment