CI - IMPROVEMENT - Gate the Julia test suite on Julia changes, and general workflow cleanup - #344
Merged
Conversation
…lia code The full suite takes 15-25 minutes per matrix leg and was running on every pull request, including docs- and CLAUDE.md-only changes. A `changes` job now inspects the PR's file list and gates the matrix on whether the change touches anything test/runtests.jl actually reads: any .jl file outside docs/, benchmarks/ and regression-harness/, plus Project.toml, test/, examples/ and this workflow. Pushes to main/develop still always run the suite. A `Tests` aggregate job runs unconditionally and reports success when the suite is legitimately skipped, so it can serve as the required status check without blocking merges on skipped runs. Also across the workflows: - Fix the copilot-setup-steps triggers, which referenced a .yml file that does not exist and had a stray space in the pull_request path, so neither the push nor the pull_request trigger ever matched. - Add a concurrency group to the test workflow so superseded PR runs are cancelled instead of running two full matrices in parallel. - Add timeout-minutes to every job; jobs previously inherited the 6-hour default, so a hung test would burn a full day of runner minutes. - Standardize on actions/checkout@v6 and julia-actions/cache@v3 everywhere. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019tFBCa5iBXyb7xp8LxqBJx
… now Adds a Format and Hygiene workflow that runs the repository's own pre-commit suite (JuliaFormatter plus the file-hygiene hooks) so contributors who have not run `pre-commit install` are still caught. It is wired to workflow_dispatch only: the repository has pre-existing formatting drift that must be cleaned up first, which is out of scope here. Running it manually from the Actions tab shows the current damage; uncommenting the pull_request trigger enables it as a gate. The julia-formatter hook is `language: system`, so it shells out to whatever JuliaFormatter is in the default depot environment rather than the one implied by the pinned hook revision. The workflow therefore installs JuliaFormatter v1.0.62 explicitly, matching the rev in .pre-commit-config.yaml, so CI and local runs agree. Also disables coverage instrumentation in the test job. julia-runtest enables it by default, but nothing consumes the .cov files: they are gitignored and never uploaded. Instrumenting compute-heavy numerical code for output that is discarded is pure cost. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019tFBCa5iBXyb7xp8LxqBJx
The detector wrote its decision only to the run summary, so the job log showed the script and nothing else. That makes "why did the suite run?" unanswerable from the place people look first. Echo the verdict and the matched files to stdout as well, and list the files considered when the suite is skipped. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019tFBCa5iBXyb7xp8LxqBJx
…aths The detector matched any .jl file outside a denylist of docs, benchmarks and regression-harness. That meant new untested Julia triggered a full run unless someone remembered to extend the denylist: a benchmark, a root-level script, or a future tools/ directory all ran the suite for nothing. Replace it with an allowlist of what test/runtests.jl actually exercises: src/, test/, examples/, Project.toml, and this workflow. Untested code is now excluded by default rather than by maintenance. Kept as directory prefixes rather than *.jl: src/ForcingTerms/coil_geometries holds the .dat coil geometries the coil tests load, and test/test_data holds 28 non-Julia fixtures. Matching only *.jl would skip runs when either changes. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019tFBCa5iBXyb7xp8LxqBJx
matt-pharr
enabled auto-merge
July 30, 2026 15:13
matt-pharr
disabled auto-merge
July 30, 2026 15:13
matt-pharr
enabled auto-merge
July 30, 2026 15:14
jhalpern30
approved these changes
Jul 30, 2026
jhalpern30
left a comment
Collaborator
There was a problem hiding this comment.
These all look like great changes - especially the auto-formatter check, I've had too many PRs where I change one line on my end but the entire file gets diffed
Collaborator
|
❤️ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Only changed github tests. Changes: