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

Add more begin_panic normalizations to panic backtrace tests #134781

Merged
merged 1 commit into from
Dec 26, 2024

Conversation

Zalathar
Copy link
Contributor

@Zalathar Zalathar commented Dec 26, 2024

Since #123244, these tests have started failing locally on some systems (#133997) due to minor variations in how begin_panic is printed in the backtrace.

The variation appears to occur on macOS when rust.debuginfo-level = "line-tables-only" is set, which is the default in config.compiler.toml. It does not occur when the debuginfo level is set to 1.

The variation doesn't seem relevant to these tests, so this PR simply adds another custom normalization rule to account for the variation.


Will conflict with #134759.

@rustbot
Copy link
Collaborator

rustbot commented Dec 26, 2024

r? @SparrowLii

rustbot has assigned @SparrowLii.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Dec 26, 2024
@Zalathar Zalathar added the A-testsuite Area: The testsuite used to check the correctness of rustc label Dec 26, 2024
@SparrowLii
Copy link
Member

cc @Mark-Simulacrum @jieyouxu since this related with #133997

@jieyouxu
Copy link
Member

It seems reasonable if only to suppress the local failures (but which are not super important for the tests themselves). I don't know the precise reason for the variations, but one possible cause is that the share generics could possibly induce platform-specific behavior in what gets shared and what doesn't (leading to backtrace differences).

@Zalathar
Copy link
Contributor Author

I was able to isolate the difference to rust.debuginfo-level = "line-tables-only" (diff).

I don't know precisely why that triggers it, or why it only appears to affect macOS, but backtraces are subject to so much platform-specific behaviour that I don't feel much need to dig further than that.

@jieyouxu
Copy link
Member

Yeah, I think that's very reasonable.

@jieyouxu
Copy link
Member

@bors r=SparrowLii,jieyouxu rollup

@bors
Copy link
Contributor

bors commented Dec 26, 2024

📌 Commit 1511de3 has been approved by SparrowLii,jieyouxu

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 26, 2024
jieyouxu added a commit to jieyouxu/rust that referenced this pull request Dec 26, 2024
…ieyouxu

Add more `begin_panic` normalizations to panic backtrace tests

Since rust-lang#123244, these tests have started failing locally on some systems (rust-lang#133997) due to minor variations in how `begin_panic` is printed in the backtrace.

The variation appears to occur on macOS when `rust.debuginfo-level = "line-tables-only"` is set, which is the default in `config.compiler.toml`. It does not occur when the debuginfo level is set to 1.

The variation doesn't seem relevant to these tests, so this PR simply adds another custom normalization rule to account for the variation.

---

Will conflict with rust-lang#134759.
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 26, 2024
Rollup of 4 pull requests

Successful merges:

 - rust-lang#134664 (Account for removal of multiline span in suggestion)
 - rust-lang#134774 (fix default-backtrace-ice test)
 - rust-lang#134781 (Add more `begin_panic` normalizations to panic backtrace tests)
 - rust-lang#134784 (Miri subtree update)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 26, 2024
…llaumeGomez

Rollup of 4 pull requests

Successful merges:

 - rust-lang#134656 (Migrate `incr-add-rust-src-component` to rmake)
 - rust-lang#134664 (Account for removal of multiline span in suggestion)
 - rust-lang#134772 (Improve/cleanup rustdoc code)
 - rust-lang#134781 (Add more `begin_panic` normalizations to panic backtrace tests)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 3d50eba into rust-lang:master Dec 26, 2024
6 checks passed
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Dec 26, 2024
Rollup merge of rust-lang#134781 - Zalathar:backtrace, r=SparrowLii,jieyouxu

Add more `begin_panic` normalizations to panic backtrace tests

Since rust-lang#123244, these tests have started failing locally on some systems (rust-lang#133997) due to minor variations in how `begin_panic` is printed in the backtrace.

The variation appears to occur on macOS when `rust.debuginfo-level = "line-tables-only"` is set, which is the default in `config.compiler.toml`. It does not occur when the debuginfo level is set to 1.

The variation doesn't seem relevant to these tests, so this PR simply adds another custom normalization rule to account for the variation.

---

Will conflict with rust-lang#134759.
@rustbot rustbot added this to the 1.85.0 milestone Dec 26, 2024
@Zalathar Zalathar deleted the backtrace branch December 27, 2024 00:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-testsuite Area: The testsuite used to check the correctness of rustc S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants