Skip to content

Commit 7471d5f

Browse files
committed
Merge main and preserve grouped Bun regression coverage
Retain the new Bun shared bundled-record test in the grouped e2e matrix. Run the new Rust setup retry script under Bash in the Windows addon job.
2 parents 662d711 + 85105c9 commit 7471d5f

24 files changed

Lines changed: 1744 additions & 317 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 37 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -76,11 +76,12 @@ jobs:
7676
run: python3 scripts/ci-reuse-merge-group.py
7777

7878
- name: Install Rust
79-
# rustup is pre-installed on GitHub-hosted runners. `rustup show`
80-
# reads rust-toolchain.toml in the repo root, then installs the
81-
# pinned channel + listed components if missing. No third-party
79+
# rustup is pre-installed on GitHub-hosted runners. `toolchain
80+
# install` with no name reads rust-toolchain.toml in the repo root,
81+
# then installs the pinned channel + listed components if missing
82+
# (retried past download blips; see the script). No third-party
8283
# action dependency needed for toolchain setup.
83-
run: rustup show
84+
run: scripts/rustup-retry.sh toolchain install
8485

8586
- name: Cache cargo
8687
# Swatinem/rust-cache instead of a raw actions/cache of the whole
@@ -127,7 +128,8 @@ jobs:
127128
persist-credentials: false
128129

129130
- name: Install Rust
130-
run: rustup show
131+
shell: bash
132+
run: scripts/rustup-retry.sh toolchain install
131133

132134
- name: Cache cargo
133135
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
@@ -317,11 +319,13 @@ jobs:
317319
persist-credentials: false
318320

319321
- name: Install Rust
320-
# rustup is pre-installed on GitHub-hosted runners. `rustup show`
321-
# reads rust-toolchain.toml in the repo root, then installs the
322-
# pinned channel + listed components if missing. No third-party
322+
# rustup is pre-installed on GitHub-hosted runners. `toolchain
323+
# install` with no name reads rust-toolchain.toml in the repo root,
324+
# then installs the pinned channel + listed components if missing
325+
# (retried past download blips; see the script). No third-party
323326
# action dependency needed for toolchain setup.
324-
run: rustup show
327+
shell: bash
328+
run: scripts/rustup-retry.sh toolchain install
325329

326330
- name: Cache cargo
327331
# Swatinem/rust-cache, main-only saves: see the first `Cache cargo`
@@ -488,11 +492,12 @@ jobs:
488492
persist-credentials: false
489493

490494
- name: Install Rust
491-
# rustup is pre-installed on GitHub-hosted runners. `rustup show`
492-
# reads rust-toolchain.toml in the repo root, then installs the
493-
# pinned channel + listed components if missing. No third-party
495+
# rustup is pre-installed on GitHub-hosted runners. `toolchain
496+
# install` with no name reads rust-toolchain.toml in the repo root,
497+
# then installs the pinned channel + listed components if missing
498+
# (retried past download blips; see the script). No third-party
494499
# action dependency needed for toolchain setup.
495-
run: rustup show
500+
run: scripts/rustup-retry.sh toolchain install
496501

497502
- name: Cache cargo
498503
# Swatinem/rust-cache, main-only saves: see the first `Cache cargo`
@@ -532,12 +537,12 @@ jobs:
532537
persist-credentials: false
533538

534539
- name: Install Rust
535-
# `rustup show` installs the rust-toolchain.toml channel + listed
536-
# components; `rustup component add` adds the llvm-tools-preview
540+
# `toolchain install` installs the rust-toolchain.toml channel +
541+
# listed components; `component add` adds the llvm-tools-preview
537542
# bits cargo-llvm-cov needs to merge .profraw files into lcov.
538543
run: |
539-
rustup show
540-
rustup component add llvm-tools-preview
544+
scripts/rustup-retry.sh toolchain install
545+
scripts/rustup-retry.sh component add llvm-tools-preview
541546
542547
- name: Install cargo-llvm-cov
543548
# taiki-e/install-action ships precompiled binaries — much faster
@@ -727,11 +732,11 @@ jobs:
727732
driver: docker
728733

729734
- name: Install Rust
730-
# `rustup show` consumes rust-toolchain.toml; the explicit
735+
# `toolchain install` consumes rust-toolchain.toml; the explicit
731736
# `component add` covers llvm-tools-preview for cargo-llvm-cov.
732737
run: |
733-
rustup show
734-
rustup component add llvm-tools-preview
738+
scripts/rustup-retry.sh toolchain install
739+
scripts/rustup-retry.sh component add llvm-tools-preview
735740
736741
- name: Install cargo-llvm-cov
737742
uses: taiki-e/install-action@65851e10cd6c377f11a60e600abc07cb08643468 # v2.79.3
@@ -946,7 +951,8 @@ jobs:
946951
persist-credentials: false
947952

948953
- name: Install Rust
949-
run: rustup show
954+
shell: bash
955+
run: scripts/rustup-retry.sh toolchain install
950956

951957
- name: Cache cargo
952958
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
@@ -1043,7 +1049,7 @@ jobs:
10431049
- {os: 'ubuntu-latest', suite: 'e2e_redirect_bun_build e2e_vendor_bun_build mode_migration_bun', bun: '1.2.23', test_filter: '--include-ignored', ci_group: 'node20-1.2.23-13'}
10441050
- {os: 'ubuntu-latest', bun: '1.3.14', suite: 'e2e_redirect_bun_build e2e_vendor_bun_build mode_migration_bun e2e_bun_lockb', cases: '[{"os":"ubuntu-latest","suite":"e2e_redirect_bun_build e2e_vendor_bun_build mode_migration_bun","bun":"1.3.14","test_filter":"--include-ignored"},{"os":"ubuntu-latest","suite":"e2e_bun_lockb","bun":"1.3.14","test_filter":"--include-ignored workspace_late_dependent"}]', ci_group: 'node20-1.3.14-14'}
10451051
- {os: 'ubuntu-latest', suite: 'e2e_bun_lockb', bun: '1.0.36', test_filter: '--include-ignored', ci_group: 'node20-1.0.36-15'}
1046-
- {os: 'ubuntu-latest', suite: 'e2e_bun_lockb', bun: '1.4.2', test_filter: '--include-ignored text_migration workspace_late_dependent', ci_group: 'node20-1.4.2-16'}
1052+
- {os: 'ubuntu-latest', suite: 'e2e_bun_lockb', bun: '1.4.2', test_filter: '--include-ignored text_migration workspace_late_dependent binary_shared_bundled_record_hosted_pin_is_managed', ci_group: 'node20-1.4.2-16'}
10471053
- {os: 'ubuntu-latest', vlt: '1.2.0', suite: 'e2e_redirect_vlt_build e2e_vendor_vlt_build mode_migration_vlt e2e_safety_vlt e2e_vlt e2e_redirect_pnpm_build', cases: '[{"os":"ubuntu-latest","suite":"e2e_redirect_vlt_build","vlt":"1.2.0","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"e2e_vendor_vlt_build","vlt":"1.2.0","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"mode_migration_vlt","vlt":"1.2.0","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"e2e_safety_vlt","vlt":"1.2.0","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"e2e_safety_vlt","vlt":"1.2.0","test_filter":"--include-ignored vlt_pinned_matrix","vlt_store_linker":"hardlink"},{"os":"ubuntu-latest","suite":"e2e_vlt","vlt":"1.2.0","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"e2e_redirect_pnpm_build","test_filter":"--ignored --skip pnpm_pinned_matrix"}]', ci_group: 'node24-1.2.0-17'}
10481054
- {os: 'ubuntu-latest', suite: 'e2e_redirect_vlt_build', vlt: '0.0.0-16', test_filter: '--include-ignored vlt_pinned_matrix', ci_group: 'node24-0.0.0-16-18'}
10491055
- {os: 'ubuntu-latest', vlt: '0.0.0-32', suite: 'e2e_redirect_vlt_build e2e_vendor_vlt_build mode_migration_vlt e2e_vlt', cases: '[{"os":"ubuntu-latest","suite":"e2e_redirect_vlt_build","vlt":"0.0.0-32","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"e2e_vendor_vlt_build","vlt":"0.0.0-32","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"mode_migration_vlt","vlt":"0.0.0-32","test_filter":"--include-ignored vlt_pinned_matrix"},{"os":"ubuntu-latest","suite":"e2e_vlt","vlt":"0.0.0-32","test_filter":"--include-ignored vlt_pinned_matrix"}]', ci_group: 'node24-0.0.0-32-19'}
@@ -1611,7 +1617,7 @@ jobs:
16111617
driver: docker
16121618

16131619
- name: Install Rust
1614-
run: rustup show
1620+
run: scripts/rustup-retry.sh toolchain install
16151621

16161622
# No `actions/cache` here intentionally. This job builds Docker
16171623
# images and would be flagged by zizmor's cache-poisoning audit.
@@ -1688,7 +1694,7 @@ jobs:
16881694
with:
16891695
persist-credentials: false
16901696
- name: Install Rust
1691-
run: rustup show
1697+
run: scripts/rustup-retry.sh toolchain install
16921698
- name: Cache cargo
16931699
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
16941700
with:
@@ -1735,7 +1741,8 @@ jobs:
17351741
with:
17361742
persist-credentials: false
17371743
- name: Install Rust
1738-
run: rustup show
1744+
shell: bash
1745+
run: scripts/rustup-retry.sh toolchain install
17391746
- name: Cache cargo
17401747
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
17411748
with:
@@ -1842,15 +1849,16 @@ jobs:
18421849
tar -xf target/e2e-bin.tar -C target/e2e-bin
18431850
rm target/e2e-bin.tar
18441851
- name: Install Rust
1845-
run: rustup show
1852+
shell: bash
1853+
run: scripts/rustup-retry.sh toolchain install
18461854
- name: Install the cargo under test
18471855
# bash, not the Windows default pwsh: in PowerShell
18481856
# "$CARGO_TEST_TOOLCHAIN" is an (unset) PowerShell variable, so the
18491857
# windows-latest leg ran `rustup toolchain install ""`.
18501858
shell: bash
18511859
env:
18521860
CARGO_TEST_TOOLCHAIN: ${{ matrix.toolchain }}
1853-
run: rustup toolchain install "$CARGO_TEST_TOOLCHAIN" --profile minimal
1861+
run: scripts/rustup-retry.sh toolchain install "$CARGO_TEST_TOOLCHAIN" --profile minimal
18541862
- name: Real-cargo hosted/vendored + manifest-less VEX
18551863
# The e2e-build binaries, run from the package root as `cargo test`
18561864
# would (see the e2e job's staging step).
@@ -1966,7 +1974,7 @@ jobs:
19661974
with:
19671975
persist-credentials: false
19681976
- name: Install Rust
1969-
run: rustup show
1977+
run: scripts/rustup-retry.sh toolchain install
19701978
- name: Pull the old cargos under test
19711979
if: needs.clippy.outputs.reuse != 'true'
19721980
run: |
@@ -2078,7 +2086,7 @@ jobs:
20782086

20792087
- name: Install Rust
20802088
if: steps.gate.outputs.run == 'true'
2081-
run: rustup show
2089+
run: scripts/rustup-retry.sh toolchain install
20822090

20832091
- name: Cache cargo
20842092
if: steps.gate.outputs.run == 'true'

‎.github/workflows/vlt-compatibility.yml‎

Lines changed: 42 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ on:
4343
- 'scripts/vlt-historical-integrity.json'
4444
- 'scripts/gen-vlt-collation-golden.mjs'
4545
- 'scripts/ci-vlt-proof-suites.py'
46+
- 'scripts/vlt-compat-gate.py'
47+
- 'scripts/tests/test_vlt_compat_gate.py'
4648
- '.github/workflows/ci.yml'
4749
- 'scripts/tests/test_ci_vlt_rows.py'
4850
push:
@@ -84,6 +86,8 @@ on:
8486
- 'scripts/vlt-historical-integrity.json'
8587
- 'scripts/gen-vlt-collation-golden.mjs'
8688
- 'scripts/ci-vlt-proof-suites.py'
89+
- 'scripts/vlt-compat-gate.py'
90+
- 'scripts/tests/test_vlt_compat_gate.py'
8791
- '.github/workflows/ci.yml'
8892
- 'scripts/tests/test_ci_vlt_rows.py'
8993
schedule:
@@ -136,8 +140,41 @@ jobs:
136140
- name: Every era, suite and OS is covered
137141
run: python3 -B -m unittest scripts/tests/test_ci_vlt_rows.py -v
138142

139-
build:
143+
# Both filters list ci.yml for its vlt `e2e` rows, which install-proof
144+
# leaves out. A PR or push whose only matching change is ci.yml, with
145+
# those rows untouched, would rerun the matrix exactly as on the base:
146+
# matrix-coverage above still checks it, the rest is skipped.
147+
changes:
140148
if: github.event.pull_request.draft != true
149+
runs-on: ubuntu-latest
150+
timeout-minutes: 5
151+
outputs:
152+
matrix: ${{ steps.gate.outputs.matrix }}
153+
steps:
154+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
155+
with:
156+
persist-credentials: false
157+
# A PR's merge commit has the base it was merged onto as parent 1.
158+
fetch-depth: 2
159+
- id: gate
160+
env:
161+
EVENT_NAME: ${{ github.event_name }}
162+
PUSH_BEFORE: ${{ github.event.before }}
163+
run: |
164+
set -euo pipefail
165+
case "$EVENT_NAME" in
166+
pull_request) base=HEAD^1 ;;
167+
push) base="$PUSH_BEFORE" ;;
168+
*) base='' ;;
169+
esac
170+
if [ -n "$base" ] && ! git rev-parse --verify --quiet "$base^{commit}" >/dev/null; then
171+
git fetch --quiet --depth 1 origin "$base" || true
172+
fi
173+
python3 -B scripts/vlt-compat-gate.py --event "$EVENT_NAME" --base "$base" >> "$GITHUB_OUTPUT"
174+
175+
build:
176+
needs: changes
177+
if: needs.changes.outputs.matrix == 'true'
141178
strategy:
142179
fail-fast: false
143180
matrix:
@@ -373,7 +410,8 @@ jobs:
373410
steps: *install-proof-steps
374411

375412
plan:
376-
if: github.event.pull_request.draft != true
413+
needs: changes
414+
if: needs.changes.outputs.matrix == 'true'
377415
runs-on: ubuntu-latest
378416
timeout-minutes: 5
379417
outputs:
@@ -468,8 +506,8 @@ jobs:
468506
retention-days: 14
469507

470508
lock-diff:
471-
needs: native
472-
if: ${{ !cancelled() }}
509+
needs: [changes, native]
510+
if: ${{ !cancelled() && needs.changes.outputs.matrix == 'true' }}
473511
runs-on: ubuntu-latest
474512
timeout-minutes: 10
475513
steps:

0 commit comments

Comments
 (0)