From 6f70a9c1de649ce38e014eaa8fa3b22f862768a9 Mon Sep 17 00:00:00 2001 From: Simon Sapin Date: Thu, 2 Jan 2020 14:48:13 +0100 Subject: [PATCH] mach: always call `ensure_bootstrapped` before `call_rustup_run` --- python/servo/command_base.py | 2 +- python/servo/testing_commands.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/python/servo/command_base.py b/python/servo/command_base.py index 23bb48050d2..f8c1bcb0610 100644 --- a/python/servo/command_base.py +++ b/python/servo/command_base.py @@ -360,7 +360,7 @@ class CommandBase(object): def call_rustup_run(self, args, **kwargs): if self.config["tools"]["use-rustup"]: - self.ensure_rustup_version() + assert self.context.bootstrapped args = ["rustup" + BIN_SUFFIX, "run", "--install", self.rust_toolchain()] + args else: args[0] += BIN_SUFFIX diff --git a/python/servo/testing_commands.py b/python/servo/testing_commands.py index 0c107a1867b..c874d5ed26e 100644 --- a/python/servo/testing_commands.py +++ b/python/servo/testing_commands.py @@ -310,6 +310,7 @@ class MachCommands(CommandBase): return 0 def install_rustfmt(self): + self.ensure_bootstrapped() with open(os.devnull, "w") as devnull: if self.call_rustup_run(["cargo", "fmt", "--version", "-q"], stderr=devnull) != 0: