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

Set deny-warnings = false in contributor defaults #77492

Closed
wants to merge 1 commit into from

Conversation

jyn514
Copy link
Member

@jyn514 jyn514 commented Oct 3, 2020

This makes it easier to make rapid changes without having to constantly
fix warnings.

@jyn514 jyn514 added C-enhancement Category: An issue proposing an enhancement or a PR with one. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Oct 3, 2020
@rust-highfive
Copy link
Collaborator

r? @Mark-Simulacrum

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 3, 2020
This makes it easier to make rapid changes without having to constantly
fix warnings.
@jyn514 jyn514 added the A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself label Oct 3, 2020
@nagisa
Copy link
Member

nagisa commented Oct 3, 2020

@bors r+

@bors
Copy link
Contributor

bors commented Oct 3, 2020

📌 Commit b22e039 has been approved by nagisa

@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 Oct 3, 2020
@joshtriplett
Copy link
Member

@jyn514 If we're going to change this default, can we make sure there's some indication at the end of a build that a warning occurred, so it doesn't get lost?

@jyn514
Copy link
Member Author

jyn514 commented Oct 3, 2020

@joshtriplett rustc will already print 'x warnings generated' at the end, won't it? Are you asking to collect all of those messages per-crate together into a single message? That seems like it would need cargo support.

@joshtriplett
Copy link
Member

@jyn514 x warnings generated is fine, as long as that appears in the last few lines of output from ./x.py build or ./x.py test or similar. I wouldn't want it to get pushed off the screen by other builds.

@jyn514
Copy link
Member Author

jyn514 commented Oct 3, 2020

Currently, rustc will print that once for each crate that's built, but like you said it might get pushed off the screen if there are a lot of crates. Printing the sum at the very end sounds useful but I'd rather not try to parse diagnostics. I think cargo already uses --error-format=json --json=diagnostic-rendered-ansi, could we add this in cargo instead?

@joshtriplett
Copy link
Member

@jyn514 I'd be fine with that, but I think that needs to happen before allowing warnings by default, or contributors will miss warnings entirely.

@jyn514
Copy link
Member Author

jyn514 commented Oct 3, 2020

CI denies warnings, so it will be picked up by the test suite. Are you worried people will push changes without looking at the warnings and have to spend time fixing it after the fact? That's a valid concern but it's no worse than forgetting to run x.py fmt IMO.

@jyn514
Copy link
Member Author

jyn514 commented Oct 3, 2020

Also, to be clear - all of these defaults are opt-in, not opt-out. Even if you opt-in with profile = "compiler" you can always override specific settings in config.toml.

@joshtriplett
Copy link
Member

joshtriplett commented Oct 3, 2020 via email

@jyn514
Copy link
Member Author

jyn514 commented Oct 3, 2020

Okay, that's reasonable.

@bors r-

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Oct 3, 2020
@jyn514 jyn514 added S-blocked Status: Blocked on something else such as an RFC or other implementation work. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Oct 3, 2020
@jyn514
Copy link
Member Author

jyn514 commented Oct 3, 2020

Blocked on rust-lang/cargo#8749

@bors
Copy link
Contributor

bors commented Oct 6, 2020

☔ The latest upstream changes (presumably #77606) made this pull request unmergeable. Please resolve the merge conflicts.

Note that reviewers usually do not review pull requests until merge conflicts are resolved! Once you resolve the conflicts, you should change the labels applied by bors to indicate that your PR is ready for review. Post this as a comment to change the labels:

@rustbot modify labels: +S-waiting-on-review -S-waiting-on-author

@apiraino apiraino added the T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. label Oct 14, 2021
@jyn514
Copy link
Member Author

jyn514 commented Feb 7, 2022

I am not planning to follow up on the cargo side of this.

@jyn514 jyn514 closed this Feb 7, 2022
@jyn514 jyn514 deleted the no-deny branch February 7, 2022 00:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-contributor-roadblock Area: Makes things more difficult for new contributors to rust itself C-enhancement Category: An issue proposing an enhancement or a PR with one. S-blocked Status: Blocked on something else such as an RFC or other implementation work. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants