Skip to content

Use the shared sharded nextest workflow - #1440

Draft
zaniebot wants to merge 5 commits into
mainfrom
zb/ci-reusable-nextest-shards-20260911
Draft

zaniebot wants to merge 5 commits into
mainfrom
zb/ci-reusable-nextest-shards-20260911

Conversation

@zaniebot

@zaniebot zaniebot commented Sep 11, 2026 •

Copy link
Copy Markdown
Collaborator

Move nextest runner allocation and artifact handling into the shared workflow from astral-sh/github-actions#5. test.yml selects the runner, timeout, cache policy, and shard count; uv-specific toolchains, Cargo features, Dev Drive, keychain, and filesystem fixtures remain in local platform actions. Explicit Unix Rust-cache keys keep the cache identity independent of the reusable workflow's job name.

Linux defaults to one shard and Windows to three. macOS uses one complete test run on main and two shards when the existing CI plan enables it elsewhere, so opted-in pull requests can trade additional runner capacity for lower latency without increasing the normal main runner count. The aggregate required check still waits for the complete test workflow.

@zaniebot zaniebot added the test:macos Enable macOS tests for a pull request label Sep 11, 2026
@astral-automations-bot astral-automations-bot Bot added internal A refactor or improvement that is not user-facing internal:ci Related to continuous integration workflows and infrastructure labels Sep 11, 2026
@zaniebot zaniebot added risk:3 Credible risk of meaningful incorrect behavior or regression; bounded or recoverable. priority:3 Normal: useful features, documentation, usability, or routine efficiency improvements. size:3 Substantial: interacting behaviors, difficult compatibility questions, or a careful migration. labels Sep 11, 2026
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch 5 times, most recently from 5f4a55f to eab76dc Compare September 15, 2026 21:16
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from eab76dc to ed3b9b7 Compare September 28, 2026 14:22
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from ed3b9b7 to 8a489e8 Compare October 12, 2026 16:27
UV_INTERNAL__TEST_NOCOW_FS: /tmpfs
UV_INTERNAL__TEST_ALT_FS: /tmpfs
UV_INTERNAL__TEST_LOWLINKS_FS: /minix
uses: astral-sh/github-actions/nextest@583fb5711db77c8554775b551079742d8a341e91

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

[P3] Keep nextest installation tied to the locked dev toolchain

The pinned shared action unconditionally installs nextest through taiki-e/install-action and invokes plain cargo, replacing uv run --only-dev on all three platforms. This bypasses astral-dev-toolchain-cargo-nextest in uv.lock and the explicit installer policy in .github/zizmor.yml. Both currently select 0.9.143, but future lockfile updates will no longer update CI's nextest, allowing local and CI tooling to diverge. Make the shared installer optional and supply nextest from uv's locked development environment in the local action.

@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from 8a489e8 to 7921b76 Compare October 12, 2026 17:50
Comment on lines +27 to +30
prefix-key: v1-rust-workspace
shared-key: ${{ format('{0}-cargo-test-linux', hashFiles('Cargo.toml')) }}
cache-workspace-crates: "true"
save-if: ${{ inputs.save-cache == 'true' }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

[P3] Include the extracted actions in cache-relevant change detection

The CI planner only classifies .github/workflows/*.yml as cache-relevant. A PR that changes only these new actions—for example, bumping this cache prefix or changing a cache-hashed Cargo environment variable—therefore gets save-rust-cache=false, whereas the same edit in test.yml enabled cache saving. Resulting cache misses cannot be saved for subsequent PR runs, causing repeated cold builds. Include the extracted nextest action paths in .github/workflows/plan.yml’s cache-relevant classification.

Comment on lines +44 to +46
# renovate: datasource=github-release-attachments depName=astral-sh/uv
version: "0.13.0"
checksum: "1468ebd5a5541121837c5a2817b9972ba6090fa6caa3d142620850a47fb75154"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

[P2] Extend Renovate’s checksum rules to the extracted actions

The inherited astral-sh/renovate-config preset restricts both its checksum-aware updater and its suppression of version-only updates to .github/workflows/**. Moving these pins into .github/actions/** bypasses both rules, while Renovate’s standard GitHub Actions manager still scans them. A subsequent uv update can therefore change version without updating checksum, causing setup-uv to reject the download before tests run. Extend both path filters to cover all three extracted platform actions.

@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from 99a8dfc to d5da16e Compare October 19, 2026 13:51
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from d5da16e to 923333f Compare October 20, 2026 20:36
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from 923333f to 9b9a971 Compare October 21, 2026 17:26
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from 9b9a971 to a7add45 Compare October 23, 2026 00:11
@astral-automations-bot
astral-automations-bot Bot force-pushed the zb/ci-reusable-nextest-shards-20260911 branch from a7add45 to 1fc0a03 Compare October 24, 2026 04:05

This branch was successfully deployed

1 active (outdated) deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal:ci Related to continuous integration workflows and infrastructure internal A refactor or improvement that is not user-facing priority:3 Normal: useful features, documentation, usability, or routine efficiency improvements. risk:3 Credible risk of meaningful incorrect behavior or regression; bounded or recoverable. size:3 Substantial: interacting behaviors, difficult compatibility questions, or a careful migration. test:macos Enable macOS tests for a pull request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant