Index: sitescripts/extensions/bin/createNightlies.py |
=================================================================== |
--- a/sitescripts/extensions/bin/createNightlies.py |
+++ b/sitescripts/extensions/bin/createNightlies.py |
@@ -49,7 +49,7 @@ |
from sitescripts.extensions.utils import ( |
compareVersions, Configuration, |
- writeAndroidUpdateManifest |
+ writeAndroidUpdateManifest, |
) |
from sitescripts.utils import get_config, get_template |
@@ -98,7 +98,7 @@ |
""" |
command = [ |
'hg', 'id', '-i', '-r', self.config.revision, '--config', |
- 'defaults.id=', self.config.repository |
+ 'defaults.id=', self.config.repository, |
] |
return subprocess.check_output(command).strip() |
@@ -119,7 +119,7 @@ |
'reverse(ancestors({}))'.format(self.config.revision), '-l', '50', |
'--encoding', 'utf-8', '--template', |
'{date|isodate}\\0{author|person}\\0{rev}\\0{desc}\\0\\0', |
- '--config', 'defaults.log=' |
+ '--config', 'defaults.log=', |
] |
result = subprocess.check_output(command).decode('utf-8') |
@@ -281,7 +281,7 @@ |
writeAndroidUpdateManifest(newManifestPath, [{ |
'basename': self.basename, |
'version': self.version, |
- 'updateURL': self.updateURL |
+ 'updateURL': self.updateURL, |
}]) |
template = get_template(get_config().get('extensions', templateName), |
@@ -305,7 +305,7 @@ |
doWrite(manifestPath, [{ |
'basename': self.basename, |
'version': version, |
- 'updateURL': updateURL |
+ 'updateURL': updateURL, |
}]) |
for suffix in ['-x86.msi', '-x64.msi', '-gpo-x86.msi', '-gpo-x64.msi']: |
@@ -335,7 +335,7 @@ |
command = ['ssh', '-p', port, get_config().get('extensions', 'androidBuildHost')] |
command.extend(map(pipes.quote, [ |
'/home/android/bin/makedebugbuild.py', '--revision', |
- self.buildNum, '--version', self.version, '--stdout' |
+ self.buildNum, '--version', self.version, '--stdout', |
])) |
subprocess.check_call(command, stdout=apkFile, close_fds=True) |
except: |
@@ -409,7 +409,7 @@ |
'version': version, |
'download': packageFile, |
'mtime': os.path.getmtime(os.path.join(baseDir, packageFile)), |
- 'size': os.path.getsize(os.path.join(baseDir, packageFile)) |
+ 'size': os.path.getsize(os.path.join(baseDir, packageFile)), |
} |
if os.path.exists(os.path.join(baseDir, changelogFile)): |
link['changelog'] = changelogFile |
@@ -471,7 +471,7 @@ |
hmac_data = '{}.{}'.format( |
base64.b64encode(json.dumps(header)), |
- base64.b64encode(json.dumps(payload)) |
+ base64.b64encode(json.dumps(payload)), |
) |
signature = hmac.new(secret, msg=hmac_data, |
@@ -499,8 +499,8 @@ |
'upload': ( |
os.path.basename(self.path), |
file.read(), |
- 'application/x-xpinstall' |
- ) |
+ 'application/x-xpinstall', |
+ ), |
}) |
request = self.generate_jwt_request( |
@@ -509,7 +509,7 @@ |
upload_url, |
'PUT', |
data, |
- [('Content-Type', content_type)] |
+ [('Content-Type', content_type)], |
) |
try: |
@@ -527,7 +527,7 @@ |
'buildtype': 'devbuild', |
'app_id': self.extensionID, |
'version': self.version, |
- } |
+ }, |
) |
os.remove(self.path) |
@@ -546,7 +546,7 @@ |
self.path = os.path.join( |
config.get('extensions', 'nightliesDirectory'), |
self.basename, |
- filename |
+ filename, |
) |
necessary = ['passed_review', 'reviewed', 'processed', 'valid'] |
@@ -576,7 +576,7 @@ |
self.update_link = os.path.join( |
config.get('extensions', 'nightliesURL'), |
self.basename, |
- filename |
+ filename, |
) |
self.remove_from_downloads_lockfile(self.config.type, |
@@ -604,7 +604,7 @@ |
('client_id', self.config.clientID), |
('client_secret', self.config.clientSecret), |
('grant_type', 'refresh_token'), |
- ]) |
+ ]), |
)) |
auth_token = '%s %s' % (response['token_type'], response['access_token']) |
@@ -658,7 +658,7 @@ |
('client_id', self.config.clientID), |
('client_secret', self.config.clientSecret), |
('grant_type', 'refresh_token'), |
- ('resource', 'https://graph.windows.net') |
+ ('resource', 'https://graph.windows.net'), |
]) |
request = urllib2.Request(token_path, post_data) |
with contextlib.closing(opener.open(request)) as response: |
@@ -699,7 +699,7 @@ |
# https://docs.microsoft.com/en-us/windows/uwp/monetize/get-an-app |
api_path = '{}/v1.0/my/applications/{}'.format( |
'https://manage.devcenter.microsoft.com', |
- self.config.devbuildGalleryID |
+ self.config.devbuildGalleryID, |
) |
request = urllib2.Request(api_path, None, headers) |
@@ -846,10 +846,10 @@ |
# Update soft link to latest build |
baseDir = os.path.join( |
- self.config.nightliesDirectory, self.basename |
+ self.config.nightliesDirectory, self.basename, |
) |
linkPath = os.path.join( |
- baseDir, '00latest' + self.config.packageSuffix |
+ baseDir, '00latest' + self.config.packageSuffix, |
) |
self.symlink_or_copy(self.path, linkPath) |