diff --git a/benchmark.py b/benchmark.py index 7bab1c575..ef2c045fa 100644 --- a/benchmark.py +++ b/benchmark.py @@ -17,6 +17,14 @@ def executeCommand(command, stdin = None, cwd = None): return stdout.decode("utf-8"), stderr.decode("utf-8"), exitCode +def pythonVersion(config): + version, _, _ = executeCommand([config["executables"]["python"]["binary"], "--version"]) + version = version.strip() + + match = re.match(r'Python (.*?)$', version, re.M | re.I) + + return match.group(1) + def plaspVersion(config): version, _, _ = executeCommand([config["executables"]["plasp"]["binary"], "-v"]) version = version.strip() @@ -223,6 +231,7 @@ def runJob(configuration, instance, config): "workingDirectory": plannerDir, "versions": \ { + "python": pythonVersion(config), "clingo": clingoVersion(config), "plasp": plaspVersion(config), "planner": plannerVersion(config),