Skip to content

[codex] Fix stale sandbox head before broker commits#878

Merged
nicoalbanese merged 2 commits into
mainfrom
codex-fix-broker-stale-commit-head
May 13, 2026
Merged

[codex] Fix stale sandbox head before broker commits#878
nicoalbanese merged 2 commits into
mainfrom
codex-fix-broker-stale-commit-head

Conversation

@nicoalbanese

Copy link
Copy Markdown
Contributor

Summary

  • sync the sandbox branch to the latest remote head before brokered commits while preserving local edits
  • run the pre-sync before staging in auto-commit and manual commit paths
  • add sandbox git helper coverage for stash/reset/pop and local-only branches

Root Cause

Broker-created GitHub API commits could land on the remote branch while the sandbox stayed on the previous HEAD if the follow-up sync lagged or failed. The next broker commit then compared the stale sandbox HEAD with the remote branch HEAD and failed with "Remote branch changed before commit could be created".

Validation

  • bun run ci

@vercel

vercel Bot commented May 13, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
open-agents Ready Ready Preview May 13, 2026 3:56pm

@nicoalbanese
nicoalbanese marked this pull request as ready for review May 13, 2026 15:12
@nicoalbanese
nicoalbanese merged commit c82d7e0 into main May 13, 2026
5 checks passed
@nicoalbanese
nicoalbanese deleted the codex-fix-broker-stale-commit-head branch May 13, 2026 16:01
dennisonbertram added a commit to dennisonbertram/fork-open-agents that referenced this pull request Jun 11, 2026
… upstream fixes, CI gates)

PR-equivalent merge performed via temporary branch-protection lift because
PR functionality is currently disabled platform-side on this fork (GitHub
returns 410 on all PR endpoints despite PRs working through #314). Protection
restored immediately after this push. Full CI-equivalent checks run locally.

Included work:
- fix/issue-316-provider-auth-errors (#316): map model-provider auth/billing
  failures to actionable chat messages instead of the generic 'Workspace
  setup failed'; all Sonnet review findings fixed (narrow auth matching,
  explicit HTTP 401/402 forms, tightened billing regex, negative tests).
- fix/issue-253-sidebar-offcanvas-collapse (#253): sessions sidebar switched
  from icon-rail to offcanvas collapse per issue spec; visible collapse +
  reopen controls; persisted state; dead icon-rail code removed; rail-actions
  contract tests added.
- chore/upstream-clean-fixes: upstream cherry-picks vercel-labs#878/#879/#886
  (stale sandbox head before broker commits, git fetch stderr handling,
  web-fetch tool approval gate — approval UI verified wired).
- claude/dev-pipeline-robustness: machine-enforced pipeline gates (additive
  CI build+guards jobs, production-smoke workflow, migration-safety and
  test-touch scripts, opt-in pre-push hook, pipeline-gates process doc,
  concurrent test-isolated runner).

Checks (CI-equivalent of required lint-and-typecheck, run at 52427ff):
git diff --check clean; bun run check 0 warnings/0 errors; bun run typecheck
4/4; bun run test:isolated 342/342 files pass; db:check migrations in sync.

Review: independent integration review (Opus) found no blocking issues across
the combined diff (31 files, +1571/-188); two non-blocking hardening items
were fixed in 52427ff. bun.lock unchanged.

Deploy notes: no migrations, no env/secret changes (production-smoke.yml
reuses existing VERCEL_AUTOMATION_BYPASS_SECRET). Rollback: revert this
merge commit.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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