From 8c610440333d27f7b9c40452c0de1dfb537f3ffc Mon Sep 17 00:00:00 2001 From: bjorn3 <17426603+bjorn3@users.noreply.github.com> Date: Sun, 27 Aug 2023 16:41:04 +0000 Subject: [PATCH] Ensure tidy never updates Cargo.lock Otherwise the results may be outdated compared to a build at a later time. Also disable checking for the backtrace workspace until Cargo.lock is committed. --- src/tools/tidy/src/deps.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/tools/tidy/src/deps.rs b/src/tools/tidy/src/deps.rs index d8ac4e94c4e2..1fbbc851df86 100644 --- a/src/tools/tidy/src/deps.rs +++ b/src/tools/tidy/src/deps.rs @@ -53,7 +53,7 @@ pub(crate) const WORKSPACES: &[(&str, ExceptionList, Option<(&[&str], &[&str])>) ), // tidy-alphabetical-start ("compiler/rustc_codegen_gcc", EXCEPTIONS_GCC, None), - ("library/backtrace", &[], None), + //("library/backtrace", &[], None), // FIXME uncomment once rust-lang/backtrace#562 lands //("library/portable-simd", &[], None), // FIXME uncomment once rust-lang/portable-simd#363 has been synced back to the rust repo //("library/stdarch", EXCEPTIONS_STDARCH, None), // FIXME uncomment once rust-lang/stdarch#1462 lands ("src/bootstrap", EXCEPTIONS_BOOTSTRAP, None), @@ -465,7 +465,8 @@ pub fn check(root: &Path, cargo: &Path, bad: &mut bool) { let mut cmd = cargo_metadata::MetadataCommand::new(); cmd.cargo_path(cargo) .manifest_path(root.join(workspace).join("Cargo.toml")) - .features(cargo_metadata::CargoOpt::AllFeatures); + .features(cargo_metadata::CargoOpt::AllFeatures) + .other_options(vec!["--locked".to_owned()]); let metadata = t!(cmd.exec()); check_license_exceptions(&metadata, exceptions, bad);