Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sporadic macOS CI test failures #11334

Open
ehuss opened this issue Nov 4, 2022 · 2 comments
Open

sporadic macOS CI test failures #11334

ehuss opened this issue Nov 4, 2022 · 2 comments
Labels
A-testing-cargo-itself Area: cargo's tests O-macos OS: macOS S-needs-info Status: Needs more info, such as a reproduction or more background for a feature request.

Comments

@ehuss
Copy link
Contributor

ehuss commented Nov 4, 2022

About 3 days ago it looks like rust-lang/cargo has been migrated to the macos-12 CI image. Coincidentally, there have been some unexpected test failures on macOS. This issue is for tracking any future failures and investigating the cause, in case they are related.

https://github.com/rust-lang/cargo/actions/runs/3382989341

---- cargo_add::path_inferred_name::path_inferred_name stdout ----
thread 'cargo_add::path_inferred_name::path_inferred_name' panicked at 'Expected success, was interrupted
', tests/testsuite/cargo_add/path_inferred_name/mod.rs:20:10
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

https://github.com/rust-lang/cargo/actions/runs/3387966256

---- out_dir::replaces_artifacts stdout ----
running `/Users/runner/work/cargo/cargo/target/debug/cargo build -Z unstable-options --out-dir out`
running `/Users/runner/work/cargo/cargo/target/tmp/cit/t1625/foo/out/foo`
running `/Users/runner/work/cargo/cargo/target/debug/cargo build -Z unstable-options --out-dir out`
running `/Users/runner/work/cargo/cargo/target/tmp/cit/t1625/foo/out/foo`
thread 'out_dir::replaces_artifacts' panicked at '
test failed running `/Users/runner/work/cargo/cargo/target/tmp/cit/t1625/foo/out/foo`
error: stdout did not match:
error: test failed, to rerun pass `--test testsuite`
1        -bar
    1    +foo

https://github.com/rust-lang/cargo/actions/runs/3703048561

EDIT: collision_doc_profile_split has been fixed via #11489

---- collisions::collision_doc_profile_split stdout ----
running `/Users/runner/work/cargo/cargo/target/debug/cargo build -v`
thread 'collisions::collision_doc_profile_split' panicked at '
test failed running `/Users/runner/work/cargo/cargo/target/debug/cargo build -v`
error: stderr did not match:
1   1         Updating [..]
2   2      Downloading crates ...
3   3       Downloaded common v1.0.0 [..]
4   4        Compiling common v1.0.0
5   5          Running `rustc --crate-name common [..]
6        -     Running `rustc --crate-name common [..]
7   6        Compiling pm v0.1.0 [..]
8   7          Running `rustc --crate-name pm [..]
    8    +     Running `rustc --crate-name common /Users/runner/work/cargo/cargo/target/tmp/cit/t768/home/.cargo/registry/src/-64f5ff1469e28552/common-1.0.0/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C opt-level=2 -C embed-bitcode=no -C split-debuginfo=unpacked -C debuginfo=2 -C debug-assertions=on -C metadata=863125f229193b90 -C extra-filename=-863125f229193b90 --out-dir /Users/runner/work/cargo/cargo/target/tmp/cit/t768/foo/target/debug/deps -L dependency=/Users/runner/work/cargo/cargo/target/tmp/cit/t768/foo/target/debug/deps --cap-lints allow`
9   9        Compiling foo v0.1.0 [..]
10  10         Running `rustc --crate-name foo [..]
11  11        Finished [..]

https://github.com/rust-lang/cargo/actions/runs/3917884106

---- build_script::rerun_if_directory stdout ----
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check`
error: test failed, to rerun pass `--test testsuite`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check`
running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
thread 'build_script::rerun_if_directory' panicked at '
test failed running `/Users/runner/work/cargo/cargo/target/debug/cargo check -v`
error: stderr did not match:
1        -       Dirty foo v0.1.0 ([..]): the file `somedir` has changed ([..])
2        -   Compiling foo [..]
3        -     Running `[..]build-script-build[..]`
4        -     Running `rustc --crate-name foo [..]
    1    +       Fresh foo v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t452/foo)
5   2         Finished [..]
@ehuss ehuss added the A-testing-cargo-itself Area: cargo's tests label Nov 4, 2022
bors added a commit that referenced this issue Dec 16, 2022
Fix collision_doc_profile test error

This fixes the `collision_doc_profile` test which was sporadically failing on CI. My theory is that the first `common` build finishes quickly (or the other job slot is delayed). The proc-macro `pm` starts (likely very quickly due to pipelining), and it can jump ahead before the second `common` build starts (or at least before the `Message::Run` message gets delivered).

The order isn't really important or relevant to this test (all that matters is that "common" shows up twice), so this ignores the order of the messages.

cc #11334
@ehuss
Copy link
Contributor Author

ehuss commented Apr 21, 2023

#12010: https://github.com/rust-lang/cargo/actions/runs/4760024468
#12025: https://github.com/rust-lang/cargo/actions/runs/4787910411

---- features2::pm_with_int_shared stdout ----
running `/Users/runner/work/cargo/cargo/target/debug/cargo build --workspace --all-targets --all-features -v`
running `/Users/runner/work/cargo/cargo/target/debug/cargo build --workspace --all-targets --all-features -v`
thread 'features2::pm_with_int_shared' panicked at '
test failed running `/Users/runner/work/cargo/cargo/target/debug/cargo build --workspace --all-targets --all-features -v`
error: Expected lines did not match (ignoring order):
0   3            Fresh shared v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/shared)
1        -       Fresh pm [..]
2        -       Fresh foo [..]
3   0         Finished dev [unoptimized + debuginfo] target(s) in 0.41s
    2    +   Compiling pm v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/pm)
    3    +   Compiling foo v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/foo)
    4    +       Dirty pm v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/pm): the dependency pm was rebuilt (1682036697.974183951s, 244716748ns after last build at 1682036697.729467203s)
    5    +       Dirty foo v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/foo): the dependency pm was rebuilt (1682036697.974183951s, 241786422ns after last build at 1682036697.732397529s)
    6    +     Running `rustc --crate-name pm_test pm/tests/pm_test.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C split-debuginfo=unpacked -C debuginfo=2 --test -C metadata=38afb8256524a059 -C extra-filename=-38afb8256524a059 --out-dir /Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps -L dependency=/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps --extern pm=/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps/libpm-2f26ecda83664a29.dylib --extern shared=/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps/libshared-26e84bc7d83882ec.rlib`
    7    +     Running `rustc --crate-name foo --edition=2018 foo/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C split-debuginfo=unpacked -C debuginfo=2 --test -C metadata=16eecb1b2d381513 -C extra-filename=-16eecb1b2d381513 --out-dir /Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps -L dependency=/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps --extern pm=/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps/libpm-2f26ecda83664a29.dylib --extern shared=/Users/runner/work/cargo/cargo/target/tmp/cit/t1023/foo/target/debug/deps/libshared-26e84bc7d83882ec.rlib`

', tests/testsuite/features2.rs:2287:10

@weihanglo weihanglo added O-macos OS: macOS S-needs-info Status: Needs more info, such as a reproduction or more background for a feature request. labels Apr 24, 2023
@weihanglo
Copy link
Member

#12298: https://github.com/rust-lang/cargo/actions/runs/5338877249/jobs/9676854240

---- freshness::simulated_docker_deps_stay_cached stdout ----
running `/Users/runner/work/cargo/cargo/target/debug/cargo build`
not already zero
running `/Users/runner/work/cargo/cargo/target/debug/cargo build -v`
thread 'freshness::simulated_docker_deps_stay_cached' panicked at '
test failed running `/Users/runner/work/cargo/cargo/target/debug/cargo build -v`
error: Expected lines did not match (ignoring order):
0        -       Fresh pathdep [..]
1   0            Fresh regdep v1.0.0
2   0            Fresh regdep_env v1.0.0
3   1            Fresh regdep_old_style v1.0.0
4   0            Fresh regdep_rerun v1.0.0
5        -       Dirty foo [..]: the precalculated components changed
6   1        Compiling foo v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo)
7   2          Running `/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/build/foo-9b1254648baf7d5d/build-script-build`
8   6          Running `rustc --crate-name foo src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debuginfo=2 -C split-debuginfo=unpacked -C metadata=eb551c456406f7f7 -C extra-filename=-eb551c456406f7f7 --out-dir /Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps -L dependency=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps --extern pathdep=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps/libpathdep-5b280e68ed7cfb32.rmeta --extern regdep=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps/libregdep-a504c181ac73ffa5.rmeta --extern regdep_env=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps/libregdep_env-cf60ad79c529527b.rmeta --extern regdep_old_style=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps/libregdep_old_style-d1a9c0bcab2d1939.rmeta --extern regdep_rerun=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps/libregdep_rerun-27cffe5a92c36607.rmeta`
9   0         Finished dev [unoptimized + debuginfo] target(s) in 0.56s
    8    +   Compiling pathdep v1.0.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/pathdep)
    9    +       Dirty foo v0.1.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo): the file `build.rs` has changed (1687382107.000000000s, 2s after last build at 1687382105.000000000s)
    10   +       Dirty pathdep v1.0.0 (/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/pathdep): the file `pathdep/src/lib.rs` has changed (1687382107.000000000s, 1s after last build at 1687382106.000000000s)
    11   +     Running `rustc --crate-name build_script_build build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C metadata=9b1254648baf7d5d -C extra-filename=-9b1254648baf7d5d --out-dir /Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/build/foo-9b1254648baf7d5d -L dependency=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps`
    12   +     Running `rustc --crate-name pathdep pathdep/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debuginfo=2 -C split-debuginfo=unpacked -C metadata=5b280e68ed7cfb32 -C extra-filename=-5b280e68ed7cfb32 --out-dir /Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps -L dependency=/Users/runner/work/cargo/cargo/target/tmp/cit/t1314/foo/target/debug/deps`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-testing-cargo-itself Area: cargo's tests O-macos OS: macOS S-needs-info Status: Needs more info, such as a reproduction or more background for a feature request.
Projects
None yet
Development

No branches or pull requests

2 participants