Skip to content

Keep Linux and Windows workflows alive and fail regeneration on drift - #3

Open
MisterGC wants to merge 3 commits into
masterfrom
issue-2
Open

MisterGC wants to merge 3 commits into
masterfrom
issue-2

Conversation

@MisterGC

@MisterGC MisterGC commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

The Linux and Windows workflows each get a keepalive job (liskin/gh-workflow-keepalive@v1) that runs only on their weekly schedule and re-enables its own workflow. The (sources regeneration) check step now also regenerates into src and fails when that changes the committed sources.

  • keepalive job with actions: write in build_linux.yml and build_windows.yml; the action keeps only the workflow it runs in alive, so each scheduled workflow carries its own
  • after zserio tutorial.zs -python build/gen, the step runs zserio tutorial.zs -python src -ignoreTimestamps + git add --intent-to-add --all -- src + git diff --exit-code -- src; new files count as drift too
  • -ignoreTimestamps is needed: without it zserio skips output files that are newer than tutorial.zs, so a hand edit passes the check

Verified:

  • "regeneration fails on a non-empty git diff": in a fresh clone with pip zserio==2.19.0, the committed sources → exit 0; a committed body edit in src/tutorial/role.py → exit 1 with the flag, exit 0 without it (skipped 6 files); an uncommitted new file → exit 1
  • PR CI on 60bba3a: 10/10 build jobs pass (build_linux 3.9–3.13, build_windows 3.8–3.12), including the new diff check; both keepalive jobs skipped on pull_request as intended
  • actionlint on both workflows → exit 1, 6 findings, all on the existing checkout@v3, setup-java@v3, setup-python@v4 lines, none on lines added here
  • 2 files changed, 22 insertions(+)

Not verified: the keepalive job itself. It runs only on schedule, so its first real run is the next Sunday cron.

Closes #2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

linux and windows workflows must never get disabled for inactivity again

1 participant