Skip to content

Pin Rust nightly 2025-02-28#164

Merged
Wenzel merged 3 commits intointel:mainfrom
Wenzel:pin_rust_nightly
May 19, 2025
Merged

Pin Rust nightly 2025-02-28#164
Wenzel merged 3 commits intointel:mainfrom
Wenzel:pin_rust_nightly

Conversation

@Wenzel
Copy link
Copy Markdown
Contributor

@Wenzel Wenzel commented May 7, 2025

Use rust-toolchain.toml as single source of truth

@Wenzel Wenzel force-pushed the pin_rust_nightly branch from cb575d0 to 246de24 Compare May 7, 2025 17:31
@Wenzel Wenzel force-pushed the pin_rust_nightly branch 2 times, most recently from 1906d9e to ff749c9 Compare May 16, 2025 23:48
@Wenzel Wenzel requested a review from Copilot May 17, 2025 00:32
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Centralize the Rust nightly version in rust-toolchain.toml and update CI to consume that single source of truth

  • Added rust-toolchain.toml with channel = "nightly-2025-02-28"
  • Removed hardcoded RUST_NIGHTLY_VERSION and the dedicated dtolnay/rust-toolchain step
  • Introduced extraction of the channel from TOML and changed the Windows installer to use --default-toolchain none

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.

File Description
rust-toolchain.toml Pin nightly channel to 2025-02-28
.github/workflows/ci.yml Remove hardcoded version, adjust Windows install command, extract version from TOML
Files not reviewed (1)
  • Dockerfile: Language not supported
Comments suppressed due to low confidence (1)

.github/workflows/ci.yml:473

  • Removing this action also removed component installation (rustfmt, clippy, miri), which could break formatting and lint checks. Consider re-adding component installation via rustup component add or an equivalent step.
-        - uses: dtolnay/rust-toolchain@83bdede770b06329615974cf8c786f845d824dfb # nightly

Copy link
Copy Markdown
Contributor Author

@Wenzel Wenzel left a comment

Choose a reason for hiding this comment

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

@brandonmarken can i have you review on this one too ?

This PR propagates the rust nightly pinning everywhere, through a rust-toolchain.toml

@Wenzel Wenzel force-pushed the pin_rust_nightly branch from ff749c9 to a4748ca Compare May 17, 2025 00:37
@Wenzel Wenzel requested a review from Copilot May 17, 2025 00:38
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR centralizes the pinned Rust nightly version in rust-toolchain.toml and updates the CI workflow to read from that file instead of an env var.

  • Add rust-toolchain.toml with channel = "nightly-2025-02-28"
  • Remove hardcoded RUST_NIGHTLY_VERSION and the dtolnay/rust-toolchain step from CI
  • Update Windows install and add a script snippet to extract the nightly date from the toolchain file

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.

File Description
rust-toolchain.toml Add [toolchain] channel pinned to nightly-2025-02-28
.github/workflows/ci.yml Remove hardcoded version, adjust rustup invocation, extract version from TOML
Files not reviewed (1)
  • Dockerfile: Language not supported
Comments suppressed due to low confidence (2)

.github/workflows/ci.yml:473

  • Removing the dtolnay/rust-toolchain step also drops installation of rustfmt, clippy, and miri. CI will no longer run formatting or lint checks—re-add component installation or replace it with another action that installs these tools.
-        uses: dtolnay/rust-toolchain@83bdede770b06329615974cf8c786f845d824dfb # nightly

.github/workflows/ci.yml:578

  • The --default-toolchain flag was removed from the Windows install command, so the nightly toolchain won’t be set and default to stable. Add --default-toolchain $(grep '^channel' rust-toolchain.toml | cut -d '"' -f 2) or similar to ensure the correct toolchain is installed.
C:\rustup-init.exe --default-host x86_64-pc-windows-gnu -y

@Wenzel Wenzel force-pushed the pin_rust_nightly branch from a4748ca to b4f9a6f Compare May 19, 2025 13:01
@Wenzel Wenzel force-pushed the pin_rust_nightly branch from b4f9a6f to 92b3368 Compare May 19, 2025 13:01
@Wenzel Wenzel requested a review from Copilot May 19, 2025 13:02
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR centralizes the Rust toolchain version in rust-toolchain.toml and updates the CI workflow to read from that file rather than hardcoding the nightly date.

  • Adds rust-toolchain.toml with the pinned nightly channel.
  • Removes hardcoded RUST_NIGHTLY_VERSION in CI and replaces it by parsing rust-toolchain.toml.
  • Adjusts Windows setup and build steps to use the extracted channel.

Reviewed Changes

Copilot reviewed 3 out of 5 changed files in this pull request and generated 2 comments.

File Description
rust-toolchain.toml Introduced as single source of truth for Rust channel.
.github/workflows/ci.yml Removed hardcoded nightly env and action; added Python parsing of TOML and updated steps to use extracted channel.
Files not reviewed (2)
  • .github/builder/common.sh: Language not supported
  • Dockerfile: Language not supported
Comments suppressed due to low confidence (1)

.github/workflows/ci.yml:660

  • GitHub Actions does not natively support Python as a shell using this syntax. Consider running the parser via a standard shell step, e.g.: run: python3 - <<EOF ... EOF or an external script file.
shell: python3 {0}

@Wenzel Wenzel force-pushed the pin_rust_nightly branch from 92b3368 to b644e68 Compare May 19, 2025 13:10
@Wenzel Wenzel requested a review from Copilot May 19, 2025 13:25
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR centralizes the Rust nightly channel in rust-toolchain.toml and updates the CI workflow to extract and use that single source of truth.

  • Add rust-toolchain.toml with pinned nightly date
  • Remove hard-coded nightly version from CI and introduce Python parsing of the toolchain file
  • Update CI steps to pass the extracted nightly date into the build process

Reviewed Changes

Copilot reviewed 3 out of 5 changed files in this pull request and generated 1 comment.

File Description
rust-toolchain.toml Pin nightly channel to 2025-02-28
.github/workflows/ci.yml Remove hard-coded version, parse rust-toolchain.toml, adjust setup steps
Files not reviewed (2)
  • .github/builder/common.sh: Language not supported
  • Dockerfile: Language not supported
Comments suppressed due to low confidence (2)

.github/workflows/ci.yml:473

  • Removing the Rust toolchain setup action drops installation of required components (rustfmt, clippy, miri) in CI. Consider adding a setup step that installs these using the channel from rust-toolchain.toml.
-        uses: dtolnay/rust-toolchain@83bdede770b06329615974cf8c786f845d824dfb # nightly

.github/workflows/ci.yml:671

  • [nitpick] The output key nightly_date doesn’t align with the other CI variable naming (RUST_*). Consider renaming it to rust_nightly_date or matching the uppercase style for consistency.
out.write(f'nightly_date={date}\n')

Invoke-WebRequest -URI https://win.rustup.rs/x86_64 -OutFile C:\rustup-init.exe
echo "Installing Rust"
C:\rustup-init.exe --default-toolchain nightly-${{ env.RUST_NIGHTLY_VERSION }} --default-host x86_64-pc-windows-gnu -y
C:\rustup-init.exe --default-host x86_64-pc-windows-gnu -y
Copy link

Copilot AI May 19, 2025

Choose a reason for hiding this comment

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

The Windows installation step no longer specifies the nightly toolchain, so rustup will default to stable. Add --default-toolchain ${{ steps.rust-channel.outputs.nightly_date }} to install the correct nightly version.

Suggested change
C:\rustup-init.exe --default-host x86_64-pc-windows-gnu -y
C:\rustup-init.exe --default-host x86_64-pc-windows-gnu --default-toolchain ${{ steps.rust-channel.outputs.nightly_date }} -y

Copilot uses AI. Check for mistakes.
@Wenzel Wenzel force-pushed the pin_rust_nightly branch 2 times, most recently from ed71a24 to bd0f812 Compare May 19, 2025 13:55
@Wenzel Wenzel force-pushed the pin_rust_nightly branch from bd0f812 to 3036afd Compare May 19, 2025 14:04
@Wenzel Wenzel requested a review from Copilot May 19, 2025 14:57
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR pins the Rust nightly toolchain to 2025-02-28 by using a new rust-toolchain.toml file as the single source of truth and updates the CI workflow accordingly.

  • Introduces rust-toolchain.toml with the specified nightly channel.
  • Removes the hardcoded RUST_NIGHTLY_VERSION environment variable and dtolnay/rust-toolchain action from the CI workflow.
  • Extracts the Rust channel from rust-toolchain.toml using a Python step and passes this to build commands.

Reviewed Changes

Copilot reviewed 3 out of 5 changed files in this pull request and generated 2 comments.

File Description
rust-toolchain.toml Adds a [toolchain] section specifying the nightly channel.
.github/workflows/ci.yml Updates CI steps to remove the RUST_NIGHTLY_VERSION env variable and extracts the channel from rust-toolchain.toml for use in subsequent steps.
Files not reviewed (2)
  • .github/builder/common.sh: Language not supported
  • Dockerfile: Language not supported

Copy link
Copy Markdown
Contributor

@brandonmarken brandonmarken left a comment

Choose a reason for hiding this comment

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

All looks good to me!

@Wenzel Wenzel merged commit f3eb6ca into intel:main May 19, 2025
19 checks passed
@Wenzel Wenzel deleted the pin_rust_nightly branch May 19, 2025 19:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants