Skip to content

ci: guard release commit push against concurrent merges#1469

Merged
mishushakov merged 3 commits into
mainfrom
mishushakov/fix-release-commit-push-race
Jun 22, 2026
Merged

ci: guard release commit push against concurrent merges#1469
mishushakov merged 3 commits into
mainfrom
mishushakov/fix-release-commit-push-race

Conversation

@mishushakov

@mishushakov mishushakov commented Jun 19, 2026

Copy link
Copy Markdown
Member

The release "Commit new versions" step pushed without a rebase, so a PR merging mid-release failed the push and the whole release. A plain git pull --rebase would fix that but could rebase the version bump onto concurrently-merged package code that was never in the published artifacts — a silent source↔artifact divergence.

This guards the rebase: on a non-fast-forward push, it only rebases when the incoming changes don't touch packages/; if they do, it fails loudly for manual reconciliation.

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@changeset-bot

changeset-bot Bot commented Jun 19, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 57d17ff

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@cursor

cursor Bot commented Jun 19, 2026

Copy link
Copy Markdown

PR Summary

Low Risk
CI-only change to release git push behavior; no runtime or package code affected.

Overview
Mid-release merges caused the version-bump push to fail because it was not a fast-forward. The Commit new versions step in publish_packages.yml now tries git push first, and on failure fetches the branch and checks whether commits that landed during the release touched packages/. If they did, the job errors instead of rebasing the version bump onto package code that was never published. If they did not, it rebases and pushes again.

Reviewed by Cursor Bugbot for commit 57d17ff. Bugbot is set up for automated code reviews on this repo. Configure here.

@mishushakov mishushakov enabled auto-merge (squash) June 19, 2026 20:12
@github-actions

github-actions Bot commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Package Artifacts

Built from af3906e. Download artifacts from this workflow run.

JS SDK (e2b@2.30.4-mishushakov-fix-release-commit-push-race.0):

npm install ./e2b-2.30.4-mishushakov-fix-release-commit-push-race.0.tgz

CLI (@e2b/cli@2.12.2-mishushakov-fix-release-commit-push-race.0):

npm install ./e2b-cli-2.12.2-mishushakov-fix-release-commit-push-race.0.tgz

Python SDK (e2b==2.29.3+mishushakov-fix-release-commit-push-race):

pip install ./e2b-2.29.3+mishushakov.fix.release.commit.push.race-py3-none-any.whl

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c24b051504

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread .github/workflows/publish_packages.yml
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@mishushakov mishushakov changed the title ci: rebase before push in release commit step to avoid push race ci: guard release commit push against concurrent merges Jun 19, 2026
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@mishushakov mishushakov merged commit 4661519 into main Jun 22, 2026
29 checks passed
@mishushakov mishushakov deleted the mishushakov/fix-release-commit-push-race branch June 22, 2026 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants