Closed
Conversation
…ns after last build at 1719325877.466399602s`
… snapbox to isolate https://github.com/rust-lang/cargo/pull/14161/files#r1660080269" This reverts commit c826531.
fb743a2 to
3b2dd16
Compare
Caching hit seems to be causing this new test failure for all platforms
```
failures:
---- freshness::changing_bin_features_caches_targets stdout ----
error: test failed, to rerun pass `-p cargo --test testsuite`
running `/Users/runner/work/cargo/cargo/target/debug/cargo build`
thread 'freshness::changing_bin_features_caches_targets' panicked at tests/testsuite/freshness.rs:525:10:
test failed running `/Users/runner/work/cargo/cargo/target/debug/cargo build`
error: stderr did not match:
1 -tests/testsuite/freshness.rs:520:22
1 + Compiling foo v0.0.1 (/Users/runner/work/cargo/cargo/target/tmp/cit/t4/foo)
2 + Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.75s
```
https://github.com/choznerol/cargo/actions/runs/9780417859/job/27002033639
This reverts commit 3b2dd16.
choznerol
commented
Jul 3, 2024
Comment on lines
-576
to
+638
| .with_stderr_contains("[..]cannot find function `foo`[..]") | ||
| .with_stderr_data(str![[r#" | ||
| [DIRTY] foo v0.0.1 ([ROOT]/foo): the dependency foo was rebuilt ([TIME_DIFF_AFTER_LAST_BUILD]) | ||
| [COMPILING] foo v0.0.1 ([ROOT]/foo) | ||
| [RUNNING] `rustc --crate-name foo [..] | ||
| [RUNNING] `rustc --crate-name foo [..] | ||
| error[E0425]: cannot find function `foo` in crate `foo` | ||
| ... | ||
| [WARNING] build failed, waiting for other jobs to finish... | ||
|
|
||
| "#]]) |
Owner
Author
There was a problem hiding this comment.
By the way another flaky test rebuild_tests_if_lib_changes
thread 'freshness::rebuild_tests_if_lib_changes' panicked at tests\testsuite\freshness.rs:635:10:
---- expected: tests\testsuite\freshness.rs:625:27
++++ actual: stderr
1 1 | [DIRTY] foo v0.0.1 ([ROOT]/foo): the dependency foo was rebuilt ([TIME_DIFF_AFTER_LAST_BUILD])
2 2 | [COMPILING] foo v0.0.1 ([ROOT]/foo)
3 3 | [RUNNING] `rustc --crate-name foo [..]
4 4 | [RUNNING] `rustc --crate-name foo [..]
5 5 | error[E0425]: cannot find function `foo` in crate `foo`
- 6 - ...
- 7 - [WARNING] build failed, waiting for other jobs to finish...
+ 6 + --> tests/foo.rs:4:34
+ 7 + |
+ 8 + 4 | fn test() { foo::foo(); }
+ 9 + | ^^^ not found in `foo`
+ 10 +
+ 11 + For more information about this error, try `rustc --explain E0425`.
+ 12 + [ERROR] could not compile `foo` (test "foo") due to 1 previous error
+ 13 +
+ 14 + Caused by:
+ 15 + process didn't exit successfully: `rustc --crate-name foo --edition=2015 tests/foo.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --test --check-cfg cfg(docsrs) --check-cfg "cfg(feature, values())" -C metadata=5cb8c046256c0d51 -C extra-filename=-5cb8c046256c0d51 --out-dir [ROOT]/foo/target/debug/deps -L dependency=[ROOT]/foo/target/debug/deps --extern foo=[ROOT]/foo/target/debug/deps/libfoo-[HASH].rlib` ([EXIT_STATUS]: 1)https://github.com/choznerol/cargo/actions/runs/9780417859/job/27002034359
Let me edit a better snapshot to avoid this.
Fix #2 (comment) Full snapshot when running locally: ``` [DIRTY] foo v0.0.1 ([ROOT]/foo): the dependency foo was rebuilt ([TIME_DIFF_AFTER_LAST_BUILD]) [COMPILING] foo v0.0.1 ([ROOT]/foo) [RUNNING] `rustc --crate-name foo --edition=2015 tests/foo.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 -C split-debuginfo=unpacked --test --check-cfg 'cfg(docsrs)' --check-cfg 'cfg(feature, values())' -C metadata=f8f4b1ccd5eb53e0 -C extra-filename=-f8f4b1ccd5eb53e0 --out-dir [ROOT]/foo/target/debug/deps -L dependency=[ROOT]/foo/target/debug/deps --extern foo=[ROOT]/foo/target/debug/deps/libfoo-[HASH].rlib` [RUNNING] `rustc --crate-name foo --edition=2015 src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 -C split-debuginfo=unpacked --test --check-cfg 'cfg(docsrs)' --check-cfg 'cfg(feature, values())' -C metadata=56205d785c25fa8c -C extra-filename=-56205d785c25fa8c --out-dir [ROOT]/foo/target/debug/deps -L dependency=[ROOT]/foo/target/debug/deps` error[E0425]: cannot find function `foo` in crate `foo` --> tests/foo.rs:4:34 | 4 | fn test() { foo::foo(); } | ^^^ not found in `foo` For more information about this error, try `rustc --explain E0425`. [ERROR] could not compile `foo` (test "foo") due to 1 previous error Caused by: process didn't exit successfully: `rustc --crate-name foo --edition=2015 tests/foo.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 -C split-debuginfo=unpacked --test --check-cfg 'cfg(docsrs)' --check-cfg 'cfg(feature, values())' -C metadata=f8f4b1ccd5eb53e0 -C extra-filename=-f8f4b1ccd5eb53e0 --out-dir [ROOT]/foo/target/debug/deps -L dependency=[ROOT]/foo/target/debug/deps --extern foo=[ROOT]/foo/target/debug/deps/libfoo-[HASH].rlib` ([EXIT_STATUS]: 1) [WARNING] build failed, waiting for other jobs to finish... ``` Turns out the `[WARNING]` line may not show every time. Matching the `[ERROR] could not compile ...` line is a better choice.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Experimenting with CI for rust-lang#14161