Port some code to Python3

This commit is contained in:
Vincent Ricard 2020-12-28 22:31:49 +01:00 committed by Josh Matthews
parent f73370088b
commit a627dde0d0
24 changed files with 1439 additions and 2341 deletions

View file

@ -749,7 +749,7 @@ install them, let us know by filing a bug!")
# Shorten hash
# NOTE: Partially verifies the hash, but it will still pass if it's, e.g., a tree
git_sha = subprocess.check_output([
'git', 'rev-parse', '--short', git_sha
'git', 'rev-parse', '--short', git_sha.decode('ascii')
])
else:
# This is a regular commit
@ -999,7 +999,7 @@ install them, let us know by filing a bug!")
toolchain = self.rust_toolchain()
status = subprocess.call(
["rustup", "run", toolchain.encode("utf-8"), "rustc", "--version"],
["rustup", "run", toolchain, "rustc", "--version"],
stdout=open(os.devnull, "wb"),
stderr=subprocess.STDOUT,
)