Commit 94ef8879 authored by Damien George's avatar Damien George
Browse files

py/ Use returncode attr to be Python2.7 compat.

parent b7d59060
......@@ -23,7 +23,7 @@ def get_version_info_from_git():
git_tag = subprocess.check_output(["git", "describe", "--dirty", "--always"], stderr=subprocess.STDOUT, universal_newlines=True).strip()
except subprocess.CalledProcessError as er:
if er.args[0] == 128:
if er.returncode == 128:
# git exit code of 128 means no repository found
return None
git_tag = ""
Supports Markdown
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