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

Move rustfmt downloads from bootstrap.py to rustbuild #97507

Merged
merged 5 commits into from
Jun 8, 2022

Conversation

jyn514
Copy link
Member

@jyn514 jyn514 commented May 29, 2022

  • Allow verifying CI downloads using src/stage0.json
  • Change download functions not to hard-code ci-artifacts.rust-lang.org
  • Change format::format to take a Builder so it has access to download_component. I think we may want to reconsider the distinction between Build and Builder at some point; I don't think it's particularly useful.
  • Move rustfmt downloads out of bootstrap.py

Fixes #95136. Helps with #94829. This is based on #96687 for simplicity.

@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 May 29, 2022
@jyn514 jyn514 force-pushed the download-rustfmt branch from d3bd080 to 603d7f9 Compare May 29, 2022 05:10
@rust-log-analyzer

This comment has been minimized.

src/bootstrap/bootstrap.py Outdated Show resolved Hide resolved
@bors
Copy link
Contributor

bors commented May 29, 2022

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

@jyn514 jyn514 force-pushed the download-rustfmt branch from 9fe9d79 to 9974c26 Compare May 29, 2022 19:41
@bors
Copy link
Contributor

bors commented May 30, 2022

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

self.verbose(&format!("verifying {}", path.display()));
let mut hasher = sha2::Sha256::new();
// FIXME: this is ok for rustfmt (4.1 MB large at time of writing), but it seems memory-intensive for rustc and larger components.
// Consider using streaming IO instead?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 I do think we can wait though, ultimately even our larger components aren't that large compared to memory usage during std/rustc compilation.

@Mark-Simulacrum
Copy link
Member

r=me with conflicts resolved

@Mark-Simulacrum Mark-Simulacrum 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-review Status: Awaiting review from the assignee but also interested parties. labels Jun 2, 2022
jyn514 added 2 commits June 7, 2022 09:24
It was confusing to have two functions with the same name but different behavior.
@jyn514 jyn514 force-pushed the download-rustfmt branch from 9974c26 to 9950dec Compare June 7, 2022 14:30
@jyn514
Copy link
Member Author

jyn514 commented Jun 7, 2022

@bors r=Mark-Simulacrum rollup=iffy

@bors
Copy link
Contributor

bors commented Jun 7, 2022

📌 Commit 9950dec28edde71695ba101481201ae7b43c7323 has been approved by Mark-Simulacrum

@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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 7, 2022
jyn514 added 3 commits June 7, 2022 10:16
This simplifies the arguments to `download_component` in config.rs.

It also moves stage0.json metadata handling to `Build::new`, making it easier to download the stage0
compiler in rustbuild later if necessary.
@jyn514 jyn514 force-pushed the download-rustfmt branch from 9950dec to 6115f4e Compare June 7, 2022 15:18
@jyn514
Copy link
Member Author

jyn514 commented Jun 7, 2022

@bors r- r=Mark-Simulacrum rollup=iffy

@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 Jun 7, 2022
@bors
Copy link
Contributor

bors commented Jun 7, 2022

📌 Commit 6115f4e has been approved by Mark-Simulacrum

@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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 7, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Jun 8, 2022
…askrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#97507 (Move rustfmt downloads from bootstrap.py to rustbuild)
 - rust-lang#97813 (Sync rustc_codegen_gcc)
 - rust-lang#97878 (Add regression test for anonymous lifetimes)
 - rust-lang#97879 (remove unneeded code)
 - rust-lang#97880 (Fix typo: fo->for)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 07f1c16 into rust-lang:master Jun 8, 2022
@rustbot rustbot added this to the 1.63.0 milestone Jun 8, 2022
@jyn514 jyn514 deleted the download-rustfmt branch June 8, 2022 20:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Using cargo run with bootstrap uses the host rustfmt, not nightly rustfmt
7 participants