Auto merge of #28193 - servo:jdm-patch-46, r=jdm

Fix more python2isms
This commit is contained in:
bors-servo 2021-02-25 01:19:51 -05:00 committed by GitHub
commit 60b642968b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -241,7 +241,7 @@ def upload_docs():
import urllib, json, os import urllib, json, os
root_url = os.environ["TASKCLUSTER_PROXY_URL"] root_url = os.environ["TASKCLUSTER_PROXY_URL"]
url = root_url + "/api/secrets/v1/secret/project/servo/doc.servo.org" url = root_url + "/api/secrets/v1/secret/project/servo/doc.servo.org"
token = json.load(urlopen(url))["secret"]["token"] token = json.load(urllib.request.urlopen(url))["secret"]["token"]
open("/root/.git-credentials", "w").write("https://git:%s@github.com/" % token) open("/root/.git-credentials", "w").write("https://git:%s@github.com/" % token)
""") """)
.with_script(""" .with_script("""

View file

@ -644,7 +644,7 @@ class PackageCommands(CommandBase):
break break
sha256_digest.update(data) sha256_digest.update(data)
package_hash = sha256_digest.hexdigest() package_hash = sha256_digest.hexdigest()
package_hash_fileobj = io.BytesIO(package_hash).encode('utf-8') package_hash_fileobj = io.BytesIO(package_hash.encode('utf-8'))
latest_hash_upload_key = '{}/servo-latest.{}.sha256'.format(nightly_dir, extension) latest_hash_upload_key = '{}/servo-latest.{}.sha256'.format(nightly_dir, extension)
s3.upload_file(package, BUCKET, package_upload_key) s3.upload_file(package, BUCKET, package_upload_key)