[81e63b89] Reconcile already-merged PR work session from forge state in complete() - #1120
Open
roboco-app[bot] wants to merge 3 commits into
Open
roboco-app[bot] wants to merge 3 commits into
roboco-app[bot] wants to merge 3 commits into
Conversation
added 2 commits
September 27, 2026 21:38
…m forge state in cell_pm_complete On the H7 already-merged branch, backfill the work session from forge state (merge_pr + forge merge_commit_sha) and write an audited gateway.pr_merge_backfilled event, so a complete() retry after an interrupted merge self-heals instead of wedging on the PR-merged guard's CEO-manual reconciliation. Unmerged PRs still merge normally.
|
Thanks for opening your first pull request on RoboCo! Quick checklist before review (most of these are enforced by CI, but worth a glance):
See CONTRIBUTING.md for the full workflow and the Code of Conduct for the community standards we follow. Welcome aboard — a maintainer will review shortly. |
…ter rebase The prior regen commit was produced against a stale environment and, after the rebase onto the advanced base, would have deleted verbs the base re-added (run_sandbox_tests, preflight_diff, triage_failure, cancel_leaf, task_time). Restored to base; the task diff now touches only the choreographer, git service, and their tests.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Close the interrupted-complete() bookkeeping gap (live incident: task 05ac303f / PR #955, 120s gateway timeout after the GitHub merge succeeded). When cell_pm_complete's H7 pre-check finds
already_merged = await self.git.is_pr_merged_for_task(task_id)true (current master anchor _impl.py:8992, re-locate by symbol — refs drifted ~300 lines) it skips the pr_merge call but leaves the work session unreconciled (merge_commit None, pr_status 'open'); _finalize_cell_complete (:9019) then fails the PR-merged guard and its remediate text routes to 'escalate to the CEO to reconcile the session and complete manually' (:9041-9057). Fix: on the already-merged branch, backfill the work session from forge state — set pr_status='merged', fetch and store the merge commit sha from the forge (GitService exposes the merged PR's merge_commit_sha), and write an auditable record (audit event or task journal note — your design choice) stating the merge record was backfilled from forge state including the sha. CONSTRAINTS: must not mask the normal path — an unmerged PR still merges normally; this is distinct from the H7 already-merged 405 fix (H7 closed the respawn loop; this closes the bookkeeping gap). No DB migration needed.