Skip to content

fix(ci): run every present language on schedule/dispatch in reusable-ci - #369

Merged
jdfalk merged 3 commits into
mainfrom
ci/reusable-ci-force-all
Oct 5, 2026
Merged

jdfalk merged 3 commits into
mainfrom
ci/reusable-ci-force-all

Conversation

@jdfalk

@jdfalk jdfalk commented Oct 5, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

detect-changes used base: github.event.pull_request.base.sha || github.event.before || github.sha. On schedule and workflow_dispatch there is no before, so the run compared the head commit with itself. Every category came back unchanged and every language job skipped. audiobook-organizer's nightly.yml skipped Go CI on 5 of 5 scheduled runs checked, so its full non-short race suite never ran nightly.

Fix

  • New input force-all (string, default 'auto'). 'auto' forces on schedule/workflow_dispatch and diffs otherwise. 'true' always forces, 'false' always diffs, and any other value fails the job.
  • A forced run inventories tracked files (git ls-files with :(glob) pathspecs) against the same filters, so only categories the repo contains report true.
  • Three categories gate on the job's entry point instead of any matching file. A fixture or a tool-config file is not a project:
    • rust_files needs a root Cargo.toml.
    • frontend_files needs <gha-get-frontend-config dir>/package.json.
    • python_files needs a root package: pyproject.toml with [project]/[build-system], setup.py, setup.cfg, or requirements.txt.
  • The filters are defined once in CHANGE_FILTERS, and both paths read them. The inventory parser fails on any line it cannot parse.
  • The summary prints which mode ran. detect-changes exposes a force-all output.
  • workflow-lint/workflow-scripts drop their own workflow_dispatch bypass, since the forced inventory covers that case.

Verified on real runners (forced via workflow_dispatch on this branch)

  • github-common: Go, Python and Workflow Lint pass. Rust and Frontend are now skipped; before the entry-point gate both failed on testdata/rust/Cargo.toml and a root package.json with no web/. Workflow Scripts fails on pre-existing ruff debt in .github/scripts (411 findings). That job already ran on every manual dispatch through the removed bypass. The fix is a separate PR.
  • audiobook-organizer nightly (pinned to this branch with force-all: 'true'): Go CI, Frontend CI (with E2E), Workflow Lint and Workflow Scripts run. Python CI is now gated off, because its pyproject.toml is black config only and failed at pip install -e ..

Caller impact

Caller Ref Effect
github-common ci.yml (weekly schedule + dispatch) local widens to Go, Python, workflow lint/scripts
cockroach-rollout-agent ci.yml (dispatch) @main manual dispatch runs rust-ci (root Cargo.toml + src/main.rs)
audiobook-organizer nightly.yml SHA pin changes on bump; sets force-all: 'true'
burndown-runner-image, magnet-handler, migrate-loop SHA pin none until they bump
subtitle-manager, ubuntu-autoinstall-agent own local copy none

Known gap, not changed here: diff mode has the same fixture false positive. A PR touching only testdata/rust/*.rs would still start rust-ci.

🤖 Generated with Claude Code

https://claude.ai/code/session_017MtQ5LP2n3t3bs7AhptkKJ

detect-changes compared the commit with itself on schedule and
workflow_dispatch events (no github.event.before), so every language job
skipped and nightly callers never ran their suites. Add a force-all input
('auto' default forces on schedule/workflow_dispatch; 'true'/'false'
override). A forced run inventories tracked files against the same
filters, so only languages the repo contains run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017MtQ5LP2n3t3bs7AhptkKJ
@github-actions github-actions Bot added github-actions GitHub Actions related work type:documentation Improvements or additions to documentation module:config Configuration management workflow:github-actions GitHub Actions workflows size/L labels Oct 5, 2026
jdfalk and others added 2 commits October 5, 2026 02:25
A forced run marked rust and frontend changed on any matching file, so
fixture files (testdata/rust/Cargo.toml, a root package.json with no
web/) started rust-ci and frontend-ci, which then failed. Require a root
Cargo.toml for rust and <frontend dir>/package.json for frontend, using
the same gha-get-frontend-config resolution frontend-ci uses.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017MtQ5LP2n3t3bs7AhptkKJ
python-ci runs `pip install -e .` whenever pyproject.toml exists and
pytest at the root. audiobook-organizer's pyproject.toml holds only
black config, so a forced run failed python-ci at the install. Require a
pyproject.toml with [project]/[build-system], setup.py, setup.cfg or
requirements.txt before forcing python-ci.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017MtQ5LP2n3t3bs7AhptkKJ
@jdfalk
jdfalk merged commit eae0c5a into main Oct 5, 2026
60 checks passed
@jdfalk
jdfalk deleted the ci/reusable-ci-force-all branch October 5, 2026 06:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github-actions GitHub Actions related work module:config Configuration management size/L type:documentation Improvements or additions to documentation workflow:github-actions GitHub Actions workflows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant