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

Support rust.channel = "auto-detect" #137220

Merged
merged 1 commit into from
Feb 28, 2025
Merged

Conversation

pietroalbini
Copy link
Member

@pietroalbini pietroalbini commented Feb 18, 2025

As discussed in Zulip, this PR adds the new "auto-detect" value for rust.channel, to load the channel name from src/ci/channel.

Note that in a previous iteration of this PR the value was "ci" instead of "auto-detect".

@rustbot
Copy link
Collaborator

rustbot commented Feb 18, 2025

r? @Kobzol

rustbot has assigned @Kobzol.
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-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Feb 18, 2025
@rustbot
Copy link
Collaborator

rustbot commented Feb 18, 2025

This PR modifies src/bootstrap/src/core/config.

If appropriate, please update CONFIG_CHANGE_HISTORY in src/bootstrap/src/utils/change_tracker.rs.

This PR modifies config.example.toml.

If appropriate, please update CONFIG_CHANGE_HISTORY in src/bootstrap/src/utils/change_tracker.rs.

@pietroalbini pietroalbini changed the title Support `rust.channel = "ci"' Support rust.channel = "ci" Feb 18, 2025
@Kobzol
Copy link
Contributor

Kobzol commented Feb 18, 2025

Two (non-blocking) nits:

  • It seems a bit weird to me to call the option "ci" when it is enabled by default for tarball sources, which are not really used on CI 😆 Maybe something like "in-tree", "from-disk" or "from-file" would be more obvious? Or just spell out "src/ci/channel"?
  • If we do decide to use ci, I would prefer for the name to be more magical, to make it super obvious that it's not just another channel name (ci sounds like a reasonable channel name, actually!), e.g. by prefixing it with :, so :ci.

@bors
Copy link
Contributor

bors commented Feb 23, 2025

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

Verified

This commit was signed with the committer’s verified signature.
pietroalbini Pietro Albini
@pietroalbini pietroalbini changed the title Support rust.channel = "ci" Support rust.channel = "auto-detect" Feb 28, 2025
@pietroalbini
Copy link
Member Author

Updated the PR. Ended up choosing auto-detect as the value, since it seems more appropriate.

@Kobzol
Copy link
Contributor

Kobzol commented Feb 28, 2025

This is a great name. Thanks!

@bors r+

@bors
Copy link
Contributor

bors commented Feb 28, 2025

📌 Commit 1ccff0e has been approved by Kobzol

It is now in the queue for this repository.

@bors
Copy link
Contributor

bors commented Feb 28, 2025

🌲 The tree is currently closed for pull requests below priority 100. This pull request will be tested once the tree is reopened.

@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 Feb 28, 2025
@Kobzol
Copy link
Contributor

Kobzol commented Feb 28, 2025

@bors rollup

bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 28, 2025
Rollup of 9 pull requests

Successful merges:

 - rust-lang#136424 (fix: overflowing bin hex)
 - rust-lang#136824 (solver cycles are coinductive once they have one coinductive step)
 - rust-lang#137220 (Support `rust.channel = "auto-detect"`)
 - rust-lang#137712 (Clean up TypeckResults::extract_binding_mode)
 - rust-lang#137713 (Fix enzyme build errors)
 - rust-lang#137748 (Fix method name in `TyCtxt::hir_crate()` documentation)
 - rust-lang#137778 (update enzyme to handle range metadata)
 - rust-lang#137780 (Fix typo in query expansion documentation)
 - rust-lang#137788 (Bump `rustc_{codegen_ssa,llvm}` `cc` to 1.2.16 to fix `x86` Windows jobs on newest Windows SDK)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit dedf61a into rust-lang:master Feb 28, 2025
6 checks passed
@rustbot rustbot added this to the 1.87.0 milestone Feb 28, 2025
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Feb 28, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Rollup merge of rust-lang#137220 - ferrocene:pa-channel-ci, r=Kobzol

Support `rust.channel = "auto-detect"`

As [discussed in Zulip](https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/vibe.20check.20for.20a.20few.20config.20changes), this PR adds the new `"auto-detect"` value for `rust.channel`, to load the channel name from `src/ci/channel`.

Note that in a previous iteration of this PR the value was "ci" instead of "auto-detect".
@pietroalbini pietroalbini deleted the pa-channel-ci branch March 6, 2025 14:04
bors-ferrocene bot added a commit to ferrocene/ferrocene that referenced this pull request Mar 12, 2025
Merge #1360

Partially verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
We cannot verify signatures from co-authors, and some of the co-authors attributed to this commit require their commits to be signed.
1360: Move most of `configure.sh` to a bootstrap profile r=pietroalbini a=pietroalbini

Note: currently a draft as I needed to cherry-pick rust-lang/rust#137220 (it hasn't reached Ferrocene yet).

This PR moves most of the configuration for our CI away from `configure.sh` and into a bootstrap profile. With this change, all of the configuration about how a Ferrocene build should look like will reside in the profile, and `configure.sh` will only contain settings specific to our CI environment.

I also made a few changes:

* Added `ferrocene.channel = "auto-detect"` to load the channel from `ferrocene/ci/channel`. Before we were loading the contents of the file in the bash script, but that's not possible anymore. This mirrors the change we upstreamed in rust-lang/rust#137220.
* Added `FERROCENE_TEST_OUTCOMES_DIR` to load the test outcomes from a directory. Before this was done through the `RUST_CONFIGURE_ARGS`, but it was the only use of that environment variable. Adding `FERROCENE_TEST_OUTCOMES_DIR` removes the need to have `RUST_CONFIGURE_ARGS`.

For our CI nothing will change!

For our developers trying to reproduce CI failures locally, they will be able to set `profile = "ferrocene-dist"` at the top of their `config.toml` instead of running `configure.sh`. Note that this is not the recommended configuration to keep locally, the previous guidance of "don't use `configure.sh` day-to-day" applies to this profile as well.

For third parties building Ferrocene on their systems, instead of running `configure.sh` with the `OUTSIDE_FERROUS=1` environment variable, they'll be able to invoke `./configure --set profile=ferrocene-dist $their_flags_there`.

Co-authored-by: Pietro Albini <pietro.albini@ferrous-systems.com>
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. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants