ci(pr): gate builds on changed-files and broaden safe exclusions#1118
ci(pr): gate builds on changed-files and broaden safe exclusions#1118rapids-bot[bot] merged 3 commits intomainfrom
Conversation
Extends pr.yaml so build jobs are skipped when none of their downstream test or docs consumers need to run, and adds exclusions for files that never affect builds or tests. Build gating (if: conditions): - conda-cpp-build: test_cpp OR test_python_conda OR build_docs - conda-python-build: test_python_conda OR build_docs - wheel-build-cuopt-mps-parser / libcuopt / cuopt / cuopt-server / cuopt-sh-client: test_python_wheels New exclusions added to all four changed-file groups (build_docs, test_cpp, test_python_conda, test_python_wheels): - **/*.md (docs are .rst; Markdown is human-only) - LICENSE, .gitattributes, .gitignore, .clang-format, .github/release.yml - ci/thirdparty-testing/** (invoked only by nightly.yaml) - .github/workflows/*.yaml files not reachable from pr.yaml Each group still begins with '**' so any path not on the exclusion list triggers full CI — the fail-closed default is preserved. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
build_docs ingests Markdown via MyST-NB (docs/cuopt/source/conf.py), and docs/cuopt/source/release-notes.md is a symlink to RELEASE-NOTES.md. Blanket '!**/*.md' would have wrongly skipped docs-build on release-notes or docs/*.md edits. Narrow the exclusion to root-level READMEs / CONTRIBUTING / CHANGELOG, which are not docs inputs. '!**/*.md' is still applied to test_cpp, test_python_conda, and test_python_wheels -- those jobs don't process markdown. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughUpdated the GitHub Actions PR workflow ( Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes 🚥 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)
Comment |
jameslamb
left a comment
There was a problem hiding this comment.
Approving, as I don't think this will cause any correctness problems, but ... I want to mention some reasons why "build unconditionally" is beneficial, in case you haven't considered them:
- keeps
sccachecache fresh (more PRs = faster building for everyone) - keeps CI scripts simpler (no need to have checks for whether or not a given run generated artifacts)
- amortizes the work of detecting and reacting to build issues over time (instead of relying on nightlies to catch them)
I also think it's worth reflecting on the cumulative complexity here... the logic for which CI runs when is getting really complicated in this project (I am thinking about changes like #931 coming too).
If you think the time / resource savings from these changes are worth that complexity and maintenance burden, I won't get in the way.
Per review feedback, merge the added exclusions into each group's list in alphabetical order and drop the interstitial grouping comments so the order is uniform. No behavior change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
/merge |
Summary
Reduces PR CI time by skipping build jobs when no downstream test or doc consumer needs them, and by excluding more files that never affect builds or tests.
Build gating (`if:`):
New exclusions (applied to all 4 changed-file groups):
Safety
Each group still begins with `'**'` (include everything). `!` lines only remove paths, so any new file that isn't explicitly excluded triggers full CI — fail-closed default preserved.
Expected impact