Fix html_last_updated_fmt for Python 3
The previous version returned a byte string, which caused errors on Python 3. I borrowed the fix from [1]. Change-Id: I36ea0a82af955274281a595e8a44162b8f5bc4ff 1: https://git.openstack.org/cgit/openstack/cinder/commit/?id=9dc4c8704eef2e48fbae992db094be7ac91f8c6c
This commit is contained in:
parent
25119d63eb
commit
cedf5918d8
|
@ -58,8 +58,7 @@ htmlhelp_basename = '%sdoc' % project
|
|||
git_cmd = ["git", "log", "--pretty=format:'%ad, commit %h'", "--date=local",
|
||||
"-n1"]
|
||||
try:
|
||||
html_last_updated_fmt = subprocess.Popen(
|
||||
git_cmd, stdout=subprocess.PIPE).communicate()[0]
|
||||
html_last_updated_fmt = subprocess.check_output(git_cmd).decode('utf-8')
|
||||
except Exception:
|
||||
warnings.warn('Cannot get last updated time from git repository. '
|
||||
'Not setting "html_last_updated_fmt".')
|
||||
|
|
Loading…
Reference in New Issue