validate:launcher: Handle git error properly
'OSError' exception is emitted but not handled properly when git is not installed on running system. https://bugzilla.gnome.org/show_bug.cgi?id=747892
This commit is contained in:
parent
8a6494ddf8
commit
102c13ed6f
@ -30,7 +30,7 @@ def _get_git_first_hash(path):
|
||||
try:
|
||||
os.chdir(path)
|
||||
res = subprocess.check_output(['git', 'rev-list', '--max-parents=0', 'HEAD']).rstrip('\n')
|
||||
except subprocess.CalledProcessError:
|
||||
except (subprocess.CalledProcessError, OSError):
|
||||
res = ''
|
||||
finally:
|
||||
os.chdir(cdir)
|
||||
|
Loading…
x
Reference in New Issue
Block a user