Add parallel-fix-check rule to HEARTBEAT.md (recovery side of Post-Push Protocol)
completedAgent: slava-agent
Priority: 2
Atomic single edit to HEARTBEAT.md, queued from 2026-06-07 04:35Z self-reflection. Complements the 06-06 Post-Push Protocol all-branches doctrine (1850ae06) by addressing the RECOVERY side: what to do AFTER you have already pushed something broken to a human collaborator branch.
Context: 2026-06-05T22:38Z Slava asked Cato to fix 5 Cursor Bugbot issues on his PR #11801. Cato pushed two fix commits without local lint, introduced two Biome useExhaustiveDependencies errors. Slava self-merged at 22:47:44Z with red Lint. Main went red.
At 23:06Z Cato opened PR #11805 (cato/fix-sftp-lint-main) to unbreak main — WITHOUT checking whether Slava was already opening his own fix. Slava opened PR #11807 (BOLT-undefined/apps-admin, formatScheduleNext refactor + biome fixes) later that night and merged it at 2026-06-06T08:58:50Z. Cato's PR #11805 had to be closed-as-superseded at 10:11Z because rebasing it on the new main would have reverted Slava's feature work.
Doctrine to add (HEARTBEAT.md Step 4 / Git & work, adjacent to the existing Post-Push Protocol all-branches section):
```
### Recovery side: parallel-fix check before opening a `cato/fix-*-main` PR
When you have pushed a broken commit to a human collaborator's branch AND main is now red because they merged with your push at the head, BEFORE you open a separate `cato/fix-*-main` recovery PR:
1. Check whether the human is already opening their own fix:
`gh pr list --search 'is:open author:<human-handle> head:<their-branch-prefix>'`
(e.g. `head:BOLT-undefined` or `head:BOLT-1234` — match the prefix they were active on).
2. Also check very recent commits to main and to their original branch:
`gh pr list --search 'is:open author:<human-handle>' --sort=updated`
3. If they ARE opening a fix:
- Route YOUR fix into THEIR PR (push to their branch with the full Post-Push Protocol gates from above: lint, tsc --noEmit, scoped jest).
- Do NOT open a parallel `cato/fix-*-main` branch — it will race with their PR and one of you will have to close.
4. If they are NOT online and have NOT opened a fix within ~30 minutes of the broken merge:
- Open the recovery PR (`cato/fix-*-main` branch).
- DM in the existing thread with the recovery PR URL and a clean disclosure: what broke, why, and what your PR does to unbreak.
5. If you have already opened the recovery PR and the human then opens their own fix:
- Compare diffs. If their fix already resolves main, close yours as superseded with `.blockers.env` resolved-row reasoning.
- Do NOT rebase yours on top of their merged work if doing so would revert their feature additions.
Case study (2026-06-05 → 06-06): 9 minutes between Slava's red merge and Cato's #11805 open. Slava's #11807 opened later that night and merged 06-06 08:58Z. #11805 was closed-as-superseded at 10:11Z because rebasing would have reverted #11807's formatScheduleNext + s3Key + postUploadActionError feature work. If Cato had run the parallel-fix check at 23:00Z before opening #11805, he might have routed the fix into #11807 directly or held HANDS-OFF until 08:58Z and avoided the close-as-superseded loop.
```
Workspace-internal edit. No PR review needed (per workspace-internal-dev-tooling doctrine).
Event Timeline
created
status_change
queued → in_progress
status_change
in_progress → completed