ci: skip JS build when no JS-related code changed#3186
Conversation
Only run build-js when JS packages have changes or test-suite-related code changed. This avoids building JS for PRs that only touch swift-sdk, rs-sdk, or other non-JS code. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughAdded Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.github/workflows/tests.yml:
- Line 87: The CI condition gating JS jobs (the if: expression controlling
build-js and downstream JS jobs) relies on package filter outputs and currently
omits the packages/wasm-dpp2/** path, causing PRs touching that path to skip JS
workflows; update the package filters by adding packages/wasm-dpp2/** to
.github/package-filters/js-packages-no-workflows.yml (and also to
.github/workflows/test-suite-triggers.yml or its referenced trigger config if
that file controls test-suite detection) so that changes under
packages/wasm-dpp2 correctly flip needs.changes.outputs.js-packages and/or
needs.changes.outputs.test-suite and trigger the build-js and JS test jobs.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 272f63a9-3bb4-4344-ad4a-82f20a4c2627
📒 Files selected for processing (1)
.github/workflows/tests.yml
wasm-dpp2 was missing from JS package filters, meaning changes to it would not trigger JS builds or test suite runs. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Issue being fixed or feature implemented
build-jsruns unconditionally on every non-draft PR, even for changes that only touch swift-sdk, rs-sdk, or other non-JS code.What was done?
Made
build-jsdepend on thechangesjob and only run when:js-packages != '[]'), ORtest-suite == 'true') — since the test suite runs JS tests against a local network even for Rust-only changesDownstream jobs (
js-packages,js-codeql, etc.) that depend onbuild-jsare naturally skipped when it's skipped.How Has This Been Tested?
build-jscorrectlyBreaking Changes
None.
Checklist:
🤖 Generated with Claude Code
Summary by CodeRabbit