Skip to content

ci: serialize bot-push workflows via concurrency group#95

Merged
ksimback merged 1 commit intomainfrom
fix-workflow-race
Apr 24, 2026
Merged

ci: serialize bot-push workflows via concurrency group#95
ksimback merged 1 commit intomainfrom
fix-workflow-race

Conversation

@ksimback
Copy link
Copy Markdown
Owner

Summary

Three workflows push bot commits to main: build-pages, rebuild-chunks, audit-summaries. When two fire on the same merge commit (common when a PR touches both data/repos.json AND research/), they race — whichever pushes second gets rejected with ! [rejected] main -> main (fetch first) and the workflow reports failure.

The "failure" has zero user impact (the lost commit is always redundant with what already merged), but it generates noisy emails like the "All jobs have failed" notification received after PR #94 merged.

Fix

Add a shared concurrency group to all three workflows:

concurrency:
  group: main-bot-push
  cancel-in-progress: false
  • group: main-bot-push — all three workflows share the same group, so GitHub Actions serializes them.
  • cancel-in-progress: false — we want both to run, just not simultaneously. Second queues until first finishes.

Evidence of the problem

Race observed on last 3 PR merges:

Test plan

  • YAML syntax valid (three workflow files still parse)
  • Post-merge: next PR that touches both data/repos.json and research/ will trigger both workflows; second should now queue cleanly instead of failing to push. Expected next trigger: next bot-merged repo-suggestion PR (e.g., if we resolve PR Add mem0ai/mem0 to Memory & Context #79 conflicts).

🤖 Generated with Claude Code

Three workflows (build-pages, rebuild-chunks, audit-summaries) push
bot commits to main. When two fire on the same merge commit, the
second loses the push race and the workflow reports failure — which
looked scary via email but caused zero user-visible impact because
the lost commit was always redundant with what already merged.

Adding a shared `concurrency.group: main-bot-push` key serializes
them: second workflow queues until first finishes, then runs with
up-to-date main. cancel-in-progress is false so both still execute
in sequence (we want both, just not simultaneously).

Fixes the repeating "All jobs have failed" emails observed on
merges of PRs #89, #92, and #94.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 24, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hermes-ecosystem Ready Ready Preview, Comment Apr 24, 2026 1:48pm

Request Review

@ksimback ksimback merged commit 21a6e0f into main Apr 24, 2026
2 checks passed
@ksimback ksimback deleted the fix-workflow-race branch April 24, 2026 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant