Skip to content

ci(build-project): split the native Rust test and Tier 2 jobs per platform (#443) - #2746

Merged
zackees merged 1 commit into
masterfrom
infra/443-native-lanes
Oct 28, 2026
Merged

zackees merged 1 commit into
masterfrom
infra/443-native-lanes

Conversation

@zackees

@zackees zackees commented Oct 28, 2026

Copy link
Copy Markdown
Member

Refs #443 — first slice: the job split only. No gate is registered yet.

GATE-010 skips whole jobs, so a matrix job over platform_os cannot be attested per host: a macOS stamp would also skip the Windows leg. This PR splits the two native matrix jobs into four named jobs, each hardcoded to its runner and gated by the matching ci_scope output:

was now
rust-tests (matrix over platform_os) rust-tests-macos (macos-26), rust-tests-windows (windows-2025-vs2026)
rust-tier2 (matrix over platform_os) rust-tier2-macos (macos-26), rust-tier2-windows (windows-2025-vs2026)

Pure refactor: the same steps, step conditions, timeouts and cache keys run on the same platforms as the old matrix. The per-platform condition changes from platform_os != '[]' to macos == 'true' / windows == 'true', which are the outputs ci_scope.py builds platform_os from, so a full run still starts all four.

Structural tests updated

The repo pins the job names in ten places; all are updated to the four names: ci/test_ci_job_timeouts.py, test_cook_profiles.py, test_rust_scope.py, test_tier2_macos_cache.py, test_tier2_windows_cache.py, test_qt_cache_identity.py, test_qt_cache_budget.py, test_ci_toml.py, test_rust_cache_policy.py (setup-soldr consumer count 10 → 12), and local-gate.toml (verify-exempt). test_ci_toml.py now checks one restore/save pair per platform job for a split cache prefix instead of exactly one in the file.

Local evidence (focused CI/configuration fix)

  • ./lint: ok (88 s), including the updated structural tests.
  • The workflow parses and exposes the four jobs with the expected runs-on, timeout-minutes, needs and step counts.
  • ./unittest did not finish within 420 s on this host (4694 tests); the change touches only workflow YAML and its structural tests.

Next slices (separate PRs)

  1. macos-native / windows-native lanes in local-gate.toml, running the workspace tests and tier2-validate; exit 75 when not on that host.
  2. Gates in ci-attestations.yml plus the [gate.trust].skip entries with covered-by.
  3. Acceptance: a PR touching only plugins/mac-capture/** with a valid macos-native stamp skips the macOS jobs; without the stamp they run.

…tform (#443)

GATE-010 skips whole jobs, so a matrix job over platform_os cannot be
attested per host: a macOS stamp would also skip the Windows leg. Split
rust-tests and rust-tier2 into rust-tests-macos/-windows and
rust-tier2-macos/-windows, each gated by the matching ci_scope output
and hardcoded to its runner. Pure refactor: same steps, same conditions,
same timeouts; no gate is registered yet.

Local evidence: ./lint ok; the workflow parses; the pinned structural
tests updated to the four names. ./unittest was still running at the
420 s bound on this host (4694 tests) and did not finish.
@zackees
zackees force-pushed the infra/443-native-lanes branch from 60a14a1 to d673b59 Compare October 28, 2026 08:01

@zackees zackees left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Reviewed as coordinator (mechanical/structural review).

Verdict: looks correct; safe to queue.

Checks confirmed:

  • check-event really does expose macos and windows outputs (ci_scope.py writes them; the platform_os array is built from the same booleans), so the new per-platform if: conditions select the same platforms as the old matrix.
  • Windows jobs keep defaults: run: shell: bash (the multi-line bash blocks would break under pwsh otherwise).
  • needs/timeout-minutes are preserved per platform, and no workflow caller needs the old job names.
  • uv run -m workflow.coordinator checks obs-studio 2746: 33 passed, 0 failed.

Minor, non-blocking: two spots still say the old names, contrary to the "ten places; all are updated" note in the description —

  • ci/test_ci_job_timeouts.py:48,53 docstrings say rust-tests / rust-tier2 (assertions use the new names correctly)
  • docs/rust-port/testing-policy.md:121,124 says "job rust-tests" / "job rust-tier2"

Fine as a follow-up docstring cleanup; not worth holding the split for. I could not push a fixup (maintainerCanModify: false).

@zackees
zackees added this pull request to the merge queue Oct 28, 2026
Merged via the queue into master with commit 8e65aa0 Oct 28, 2026
33 checks passed
@zackees
zackees deleted the infra/443-native-lanes branch October 28, 2026 08:19
MCPVOT pushed a commit to MCPVOT/obs-studio that referenced this pull request Oct 30, 2026
…-rust#443) (obs-rust#2761)

* test(native-lanes): pin the macOS/Windows native lanes and the jobs they attest (obs-rust#443)

RED: the native lanes, their optional declarations and the [gate.trust]
entries do not exist yet, so ci.test_native_lanes fails on master.

* ci(gate): attest the macOS and Windows jobs from their own hosts (obs-rust#443)

Slice 2 and 3 of obs-rust#443: the native lanes and the attestation wiring. Slice 1
(obs-rust#2746) split the matrix jobs per platform; this makes those jobs skippable by
a stamp from the host that actually ran them.

- `macos-native` / `windows-native` in `ci/local_gate.py`: the Rust steps the
  split jobs run (tests, clippy, formatting) plus that host's Tier 2
  validation (`validate.sh` with brew cmocka, `validate.ps1` with vcpkg's
  cmocka via `CMOCKA_PREFIX`/`VCPKG_INSTALLATION_ROOT`). The host check comes
  first and comes from `ci/host_platform.py`, so on any other host the lane
  raises `NotApplicable` and `main` exits 75 (EX_TEMPFAIL).
- `local-gate.toml`: both lanes are `optional`, so `ci-lint` reports a Linux
  run as "not applicable on this host" and attests nothing. The four split
  jobs move from `verify-exempt` to `[gate.trust].skip` with their
  `covered-by` lanes.
- `ci-attestations.yml`: `rust/<target>/test` and `cpp/<platform>/tier2` gates
  for both platforms, and the four jobs mapped to them. Their formatting and
  clippy gates stay the Linux lanes' (`lint`, `cross`), so a macOS stamp is
  `lint` + `cross` + `macos-native` together.
- `build-project.yaml`: `ci-mode` publishes `skip_<job>` for the four jobs and
  each job's `if:` consumes its own output (GATE-008); `ci-mode` joins their
  `needs:`.
- `docs/ci-tooling.md`: the lanes and the two new skip rows.

RED `ci/test_native_lanes.py` (7 tests, 17 failures + 4 errors on master),
GREEN the same file plus the declaration. `ci-lint local-gate lint` reports no
new finding over master (62 violations both before and after), `ruff check`
clean, and the `ci/` self-test suite passes apart from the host_platform rule
fixed in this commit.

Refs obs-rust#443
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant