common: use standard format tags when generating the log name

This commit is contained in:
Hans-Christoph Steiner 2019-11-01 17:36:49 +01:00
parent 2cbde77798
commit 3354e66bd3
No known key found for this signature in database
GPG key ID: 3E177817BA1B9BFA

View file

@ -3261,8 +3261,9 @@ def deploy_build_log_with_rsync(appid, vercode, log_content):
# gzip compress log file # gzip compress log file
log_gz_path = os.path.join('repo', log_gz_path = os.path.join('repo',
'{pkg}_{ver}.log.gz'.format(pkg=appid, '{appid}_{versionCode}.log.gz'.format(appid=appid,
ver=vercode)) versionCode=vercode))
with gzip.open(log_gz_path, 'wb') as f: with gzip.open(log_gz_path, 'wb') as f:
if isinstance(log_content, str): if isinstance(log_content, str):
f.write(bytes(log_content, 'utf-8')) f.write(bytes(log_content, 'utf-8'))