Skip to content

perf(ci): scope feature permutations and build only test targets - #5531

Merged
kixelated merged 2 commits into
mainfrom
quest/m0/ci/features
Oct 15, 2026
Merged

kixelated merged 2 commits into
mainfrom
quest/m0/ci/features

Conversation

@kixelated

@kixelated kixelated commented Oct 14, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

A transitive change such as kio selects nine isolated Tokio Clippy builds and ten media compile shapes. Nextest also compiles benchmark executables it never runs.

Approach

Use Cargo's --tests target selection, which includes library, binary, and integration tests and supports binary-only crates. Keep dependency-only PRs at feature boundaries: Tokio extremes and crypto contracts, media minimal/VPX builds and tests, and every dependency-absence check. Direct feature-owner edits and shared build inputs still run every isolated shape. Nightly explicitly runs both full feature scripts and retains its exhaustive all-target compile. Changes to either feature script now select its own checks. Retire the quest.

Impact

  • Library public API and wire: none.
  • Developer recipes rs tokio-features and rs media-features run boundary checks by default; --all isolates every existing shape.
  • Isolated permutations on dependency-only changes move to Nightly; default, capture, play, wasm, and dependency contracts remain in the affected PR gate.

Validation

just check passes: 7,433 default tests plus the capture, play, crypto-contract, minimal-media, and VPX suites, along with lint/docs/workflow/flake checks. Eight orchestration/target-selection regressions pass and remain wired into nightly gh test.

The real Cargo fixture fails before the fix because an unexecuted benchmark contains compile_error!, then passes after the fix for both library and binary-only crates. Command traces measure Tokio isolated Clippy builds at 9 -> 2 and media compile shapes at 10 -> 4 for a transitive diff; crypto refusal/identity tests, both media test invocations, and all ten dependency graphs remain. The workspace has 38 explicit benchmark targets, now excluded from ordinary nextest builds.

Alternatives

Dropping feature checks entirely loses boundary and dependency-contract coverage. Running every isolated shape for every transitive change retains the measured redundant builds. --lib --bins --tests rejects binary-only crates, so the recipe uses Cargo's test target set directly.

Rebase over #5536

just rs test keeps #5536's denied-warnings clippy-driver build, now over --tests. CI Check runs lint, so the selection tests now default to lint and cover the net-features recipe from #5503, whose own nextest also builds --tests. Bench and example targets leave the PR gate: Nightly features still compiles and lints them (clippy --all-targets --all-features), and the bench smokes still run them.

Follow-ups

Compare runner-minute savings in ordinary PRs; command counts are measured here, while cache-dependent wall-time savings are not claimed.

(Written by GPT-6, rebased by Claude Opus 5.5)


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@kixelated
kixelated force-pushed the quest/m0/ci/features branch from a08d776 to 7aee4eb Compare October 15, 2026 02:38
@kixelated
kixelated marked this pull request as ready for review October 15, 2026 02:48
@coderabbitai

coderabbitai Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 82dd858c-536c-43d0-b79b-bc561df1f8da
📥 Commits

Reviewing files that changed from the base of the PR and between 3abf016 and 597115e.

📒 Files selected for processing: 9
  • .config/nextest.toml
  • quest/m0/ci/README.md
  • quest/m0/ci/features.md
  • rs/justfile
  • sh/rs/media-features.sh
  • sh/rs/net-features.sh
  • sh/rs/select.sh
  • sh/rs/select.test.py
  • sh/rs/tokio-features.sh
💤 Files with no reviewable changes: 2
  • quest/m0/ci/README.md
  • quest/m0/ci/features.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

Walkthrough

Rust CI feature scripts now distinguish regular checks from exhaustive feature combinations. The selector routes feature checks based on changed paths, and the features recipe runs exhaustive Tokio and media checks. Nextest commands select test targets instead of all targets. The selector tests cover routing, feature-check modes, and test-target boundaries. CI documentation and comments now describe the updated PR and nightly workflows.

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to 59711

This change reduces CI work on pull requests by scoping feature checks and building only test targets. Nightly runs still cover the exhaustive checks. No merge-blocking risk was found.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 7.69% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 13 functions across 5 files. (2 skipped: 2… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title clearly and concisely describes the main changes: reducing CI feature permutations and limiting builds to test targets.
Description check Passed The description is directly related to the changeset and explains the problem, implementation, impact, validation, alternatives, and follow-ups.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 7.69% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 13 functions across 5 files. (2 skipped: 2 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches
✨ Simplify code
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-15T13:32:04.100854Z 597115e New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@kixelated kixelated left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Automated review by review (OpenAI)

Reviewed commit: 7aee4eb.

No actionable bugs found. The scope reduction is coherent: direct feature-owner edits, script edits and shared build inputs retain exhaustive checks; transitive edits retain boundary builds, crypto contracts and dependency-absence assertions. Nightly invokes both --all scripts and keeps all-target compilation/linting. The --tests recipes retain Clippy-in-Test while excluding unused benchmark targets, with fixtures for library and binary-only crates wired through Nightly's gh test.

Direction: a reasonable explicit tradeoff, moving isolated permutations and ordinary benchmark/example coverage later rather than deleting them. No library API or wire change.

Verification: static review of selectors, feature scripts, recipes, regression fixtures and workflow wiring. No tests/builds or timing measurements executed; command-count savings do not establish runner-time savings.

kixelated and others added 2 commits October 15, 2026 06:28
Co-Authored-By: GPT-6 <noreply@openai.com>
@kixelated
kixelated force-pushed the quest/m0/ci/features branch from 7aee4eb to 597115e Compare October 15, 2026 13:28
@kixelated

Copy link
Copy Markdown
Collaborator Author

Landing summary

  • Rebase over ci: enforce Clippy in the test build #5536: just rs test keeps the denied-warnings clippy-driver build and builds --tests instead of --all-targets; check-test stays test + lint. Bench and example targets leave the PR gate and stay covered by Nightly features (clippy --all-targets --all-features, all-target nextest) and the bench smokes.
  • Rebase over Gate moq-net async helpers and sessions behind a default feature #5503: kept net-features in features and in the selector; its own nextest call also builds --tests now.
  • Rebase over fix(ci): quote the clippy-driver path so Windows tests run #5557: kept the quoted clippy-driver wrapper path for Windows.
  • Selector tests: default to lint, which CI Check runs, and cover net-features alongside the tokio/media boundary vs --all cases.
  • Validation: just check passed locally except one moq-uring test refused by the host's 8 MiB RLIMIT_MEMLOCK (CI's io_uring job passed); just ci check, just gh check, and sh/rs/select.test.py (8 tests) pass.
  • Reviews: the OpenAI automated review and Codex found nothing on the previous head; Codex approved the final head.

(Written by Claude Opus 5.5)

@kixelated
kixelated enabled auto-merge October 15, 2026 13:32
@kixelated
kixelated added this pull request to the merge queue Oct 15, 2026
Merged via the queue into main with commit 3c0daa2 Oct 15, 2026
11 checks passed
@kixelated
kixelated deleted the quest/m0/ci/features branch October 15, 2026 14:14
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.

1 participant