Skip to content

Prevent overlapping GitHub Pages deployments - #8

Merged
sasmit206 merged 2 commits into
mainfrom
r03
Nov 3, 2026
Merged

sasmit206 merged 2 commits into
mainfrom
r03

Conversation

@Roonil03

@Roonil03 Roonil03 commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Bug Description

Expected: Daily and code-push rating refreshes publish the site without a Pages deployment error.

Actual: GitHub's branch-based Pages run for the bot commit failed with HTTP 400 because another Pages deployment from the refresh workflow was still in progress. The punycode deprecation warning was incidental.

Root Cause

The repository publishes main / through GitHub Pages while the refresh workflow also deploys a Pages artifact. The workflow pushed the generated ratings/site commit before its own artifact deployment completed. That push started GitHub's branch-based publisher, and the two deployment requests overlapped. The observed failure was for c943eb4 while the deployment associated with 9917611 was active.

Fix Description

On code pushes, let the existing branch-based Pages publisher deploy the committed root site and skip the custom artifact deployment. On scheduled and manual refreshes, deploy and verify the built artifact first, then push the generated ratings and root-site commit as github-actions[bot]. This sequences the two publishers instead of allowing them to race.

How to Reproduce (Before Fix)

  1. Run the scheduled refresh with the repository's branch-based Pages publishing enabled.
  2. Let the workflow commit refreshed ratings and root assets before its artifact deployment step.
  3. Observe the branch-based Pages run fail to create its deployment while the other Pages deployment is active.

How to Verify (After Fix)

  1. Merge this PR and manually dispatch the refresh workflow on main.
  2. Confirm the artifact deployment and live-site verification complete before the bot commit is pushed.
  3. Confirm the resulting branch-based Pages run has no HTTP 400 overlap; on a code push, confirm the custom Pages steps are skipped.

Impact Assessment

  • Severity: Medium
  • Users affected: All users waiting for a ratings update during a deployment collision
  • Duration: The competing publication paths were active after root-based Pages publishing was introduced; the reported collision occurred on 2026-11-03.

Regression Risk

A failed bot push after successful artifact deployment could leave the live site ahead of the repository until the next refresh. The workflow reports that push failure. Code-push publishing continues to depend on the repository's configured main / Pages source.

Checklist

  • Root cause identified and documented above
  • Fix addresses the root cause (not just symptoms)
  • Added test to prevent regression
  • Existing tests pass locally
  • Tested the specific reproduction steps

Related Issues

Keep the scheduled and push-triggered ratings refresh, build, root synchronization, and github-actions[bot] commit. Let the repository's existing main-root Pages publisher deploy those committed files, removing the second artifact deployment that races GitHub's Pages build.
Keep artifact deployment for scheduled and manual refreshes, then commit the built root site only after deployment and verification finish. Skip the custom Pages deployment on code pushes, where the branch-based Pages publisher is already active. This prevents the two deployment requests from overlapping.
@Roonil03
Roonil03 requested a review from sasmit206 November 3, 2026 13:59
@Roonil03 Roonil03 self-assigned this Nov 3, 2026
@sasmit206
sasmit206 merged commit 297b942 into main Nov 3, 2026
2 checks passed
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.

2 participants