mirror of
https://github.com/GNS3/gns3-server
synced 2024-11-28 11:18:11 +00:00
parent
3f61fbeb0e
commit
009ffcb4ef
@ -120,15 +120,15 @@ class Hypervisor(UBridgeHypervisor):
|
|||||||
@asyncio.coroutine
|
@asyncio.coroutine
|
||||||
def _check_ubridge_version(self):
|
def _check_ubridge_version(self):
|
||||||
"""
|
"""
|
||||||
Checks if the ubridge executable version is >= 0.9.3
|
Checks if the ubridge executable version is >= 0.9.4
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
output = yield from subprocess_check_output(self._path, "-v", cwd=self._working_dir)
|
output = yield from subprocess_check_output(self._path, "-v", cwd=self._working_dir)
|
||||||
match = re.search("ubridge version ([0-9a-z\.]+)", output)
|
match = re.search("ubridge version ([0-9a-z\.]+)", output)
|
||||||
if match:
|
if match:
|
||||||
version = match.group(1)
|
version = match.group(1)
|
||||||
if parse_version(version) < parse_version("0.9.3"):
|
if parse_version(version) < parse_version("0.9.4"):
|
||||||
raise UbridgeError("uBridge executable version must be >= 0.9.3")
|
raise UbridgeError("uBridge executable version must be >= 0.9.4")
|
||||||
else:
|
else:
|
||||||
raise UbridgeError("Could not determine uBridge version for {}".format(self._path))
|
raise UbridgeError("Could not determine uBridge version for {}".format(self._path))
|
||||||
except (OSError, subprocess.SubprocessError) as e:
|
except (OSError, subprocess.SubprocessError) as e:
|
||||||
|
Loading…
Reference in New Issue
Block a user