From 10e0c842120c660703a82fe56754d759e0084f51 Mon Sep 17 00:00:00 2001 From: Rachel Barker Date: Tue, 30 Jun 2026 14:13:22 +0100 Subject: [PATCH] Fix error message when rejecting implicit stage != 2 in CI The previous error message made it sound like stage != 2 was entirely disallowed under CI. But actually it was only *implicit* stage != 2 which is disallowed - an explicit `--stage 1` is permitted and is sometimes correct. Minimal command to trigger the error message: `GITHUB_ACTIONS=true ./x test ui` --- src/bootstrap/src/core/config/config.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/bootstrap/src/core/config/config.rs b/src/bootstrap/src/core/config/config.rs index 5a9c7264c006f..1db44c2c8b39c 100644 --- a/src/bootstrap/src/core/config/config.rs +++ b/src/bootstrap/src/core/config/config.rs @@ -1206,7 +1206,9 @@ impl Config { | Subcommand::Install => { assert_eq!( stage, 2, - "x.py should be run with `--stage 2` on CI, but was run with `--stage {stage}`", + "\ +x.py was run under CI with an implicit `--stage {stage}`. This is probably wrong and you want stage 2. +NOTE: Please add `--stage 2` to your command line, or if you're sure you want to run stage {stage} then add `--stage {stage}` explicitly" ); } Subcommand::Clean { .. }