-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Fix instrument-coverage tests by using Python to sort instantiation groups #111179
Conversation
(rustbot has picked a reviewer for you, use r? to override) |
This comment was marked as resolved.
This comment was marked as resolved.
9e18099
to
159e54f
Compare
@rustbot label +A-code-coverage +A-testsuite |
@bors r+ |
…acrum Fix instrument-coverage tests by using Python to sort instantiation groups rust-lang#110942 was intended to fix a set of `-Cinstrument-coverage` tests, but it ended up silently *breaking* those tests on Linux, for annoying reasons detailed at rust-lang#111171. Dealing with `diff --ignore-matching-lines` across multiple platforms has been such a hassle that I've instead written a simple Python script that can detect instantiation groups in the output of `llvm-cov show`, and sort them in a predictable order so that they can be used as snapshots for an ordinary invocation of `diff`. This approach should be much less error-prone, because it can't accidentally ignore the wrong lines, and any unforeseen problems will tend to result in a Python exception or a failing diff.
…acrum Fix instrument-coverage tests by using Python to sort instantiation groups rust-lang#110942 was intended to fix a set of `-Cinstrument-coverage` tests, but it ended up silently *breaking* those tests on Linux, for annoying reasons detailed at rust-lang#111171. Dealing with `diff --ignore-matching-lines` across multiple platforms has been such a hassle that I've instead written a simple Python script that can detect instantiation groups in the output of `llvm-cov show`, and sort them in a predictable order so that they can be used as snapshots for an ordinary invocation of `diff`. This approach should be much less error-prone, because it can't accidentally ignore the wrong lines, and any unforeseen problems will tend to result in a Python exception or a failing diff.
@rustbot label -T-bootstrap -T-infra (Just temporarily changing CI settings to run the necessary tests for this PR; those changes won't get merged.) |
This comment has been minimized.
This comment has been minimized.
This should be good to go now. I had thought I could get away with re-enabling two previously-disabled tests, but it turns out they had been disabled for good reason, beyond the scope of just sorting coverage report output. So those two tests remain disabled, which was already the status quo. @rustbot label -S-waiting-on-author +S-waiting-on-review |
@bors r+ |
⌛ Testing commit 27a3ce2 with merge bfb69532ea3d505d1d92e436b6af47173c475293... |
💔 Test failed - checks-actions |
This comment was marked as outdated.
This comment was marked as outdated.
@Zalathar: 🔑 Insufficient privileges: not in try users |
@bors retry |
…iaskrgr Rollup of 6 pull requests Successful merges: - rust-lang#111179 (Fix instrument-coverage tests by using Python to sort instantiation groups) - rust-lang#111393 (bump windows crate 0.46 -> 0.48) - rust-lang#111441 (Verify copies of mutable pointers in 2 stages in ReferencePropagation) - rust-lang#111456 (Update cargo) - rust-lang#111490 (Don't ICE in layout computation for placeholder types) - rust-lang#111492 (use by ref TokenTree iterator to avoid a few clones) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Re-enable some coverage tests on Linux These tests were originally disabled (on all platforms) in rust-lang#110393, because those changes had made them start failing on Linux for unclear reasons. I tried to re-enable them unconditionally in rust-lang#111179, since they worked locally on my Mac, but I found that they were still failing on Linux, so I gave up at that time. Later while working on rust-lang#112300 I was able to re-enable them on Windows and Mac, since those changes made it possible to add specific `ignore-` directives to individual tests. I noticed at the time that the tests actually seemed to be working again on Linux, but by that point I didn't want to risk more CI failures, so I left them disabled on Linux with an intention to re-enable them later. Now I'm going back to re-enable them on Linux too, since they seem to work fine. --- Because `run-coverage` tests are sensitive to line numbers, and `x test tidy` doesn't like leading blank lines, I've replaced the old comment/ignore with an informative comment that occupies the same number of lines.
#110942 was intended to fix a set of
-Cinstrument-coverage
tests, but it ended up silently breaking those tests on Linux, for annoying reasons detailed at #111171.Dealing with
diff --ignore-matching-lines
across multiple platforms has been such a hassle that I've instead written a simple Python script that can detect instantiation groups in the output ofllvm-cov show
, and sort them in a predictable order so that they can be used as snapshots for an ordinary invocation ofdiff
.This approach should be much less error-prone, because it can't accidentally ignore the wrong lines, and any unforeseen problems will tend to result in a Python exception or a failing diff.