core (tools): fixed bad call to "hg id" when hg is not working to guest revision, which was the cause of an Exception

This commit is contained in:
Goffi 2016-02-28 01:57:51 +01:00
commit 00f47f8181

View file

@ -80,10 +80,10 @@ def getRepositoryData(module, as_string=True):
hg_data = {}
else:
hg_data = dict(zip(KEYS, hg_data_raw.split('\n')))
try:
hg_data['modified'] = '+' in subprocess.check_output(["hg","id","-i"])
except subprocess.CalledProcessError:
pass
try:
hg_data['modified'] = '+' in subprocess.check_output(["hg","id","-i"])
except subprocess.CalledProcessError:
pass
else:
hg_data = {}