Skip to content

Bridged implementer may commit checkpoints; timebox-free brief for long bridged tasks (#431) - #436

Merged
gmickel merged 3 commits into
mainfrom
fn-244-bridged-implementer-may-commit
Sep 14, 2026
Merged

gmickel merged 3 commits into
mainfrom
fn-244-bridged-implementer-may-commit

Conversation

@gmickel

@gmickel gmickel commented Sep 14, 2026

Copy link
Copy Markdown
Owner

Bridged implementer may commit checkpoints; timebox-free brief for long bridged tasks (#431)

The headless bridge recipes carried a safety rule that the bridged child never commits. A user running a one-task spec through a codex exec implementer hit the cost of that rule: no checkpoints allowed, so host-inserted returns and a timebox that taught the implementer to return partial.

Spec: fn-244-bridged-implementer-may-commit
Branch: fn-244-bridged-implementer-may-commitorigin/main
Tasks: 1 completed
R-ID coverage: 7/7 evidenced

Closes #431.

TL;DR

  • The bridge safety rule now lets a bridged implementer commit checkpoints on the branch the host names.
  • The child still never pushes, rebases or rewrites history, decides scope, issues a review verdict, or spawns a bridge; the host keeps push, review, flowctl done, task state, and any history rewrite, and reviews the child's commit range on return.
  • The usage guide gains the host's return handling, a timebox-free brief template for long bridged tasks, and the fallback for a sandbox that denies commits.
  • A live probe fixed the codex wording: workspace-write keeps .git/ read-only, so a checkpointing child needs danger-full-access in the asserted repo root or the one-run-per-scope-unit fallback.
  • Every surface that restated the old rule now states the new one; the changelog credits the reporter.

Not in this PR (by design)

  • No hook, guard, or flowctl subcommand enforces the new rule; bridge safety stays prose-only.
  • The child still never pushes, never rebases or amends, never decides scope, never issues a verdict, and never spawns a bridge.
  • No change to the in-host worker, flowctl done, review backends, or the thin-wrapper recipe beyond the sentence that names the rule.
  • No packaged delegation, no work.delegate* revival, no per-bridge config key.

The change, top to bottom

The bridge safety rule no longer forbids a bridged implementer from committing: the child may commit checkpoints on the branch the host names while the host keeps push, history rewrite, review, task state, and the verdict. The usage guide gains a timebox-free brief for long bridged tasks plus the sandbox-denied fallback, and every surface that restated the old rule now states the new one (issue #431).

Proof Value Sources
Artifact fn-244-aid-1e6cd758 artifact identity
Base commit bb3554f6854c9f5ee7dc02bdebf77c0d33722a4a artifact currentness
Head commit 1e6cd758003c132efc8bdb6dee1489a1835e568f artifact identity
Human-review lines 44 deterministic file stats
Canonical files 6 deterministic membership
Total files 13 deterministic membership
Full gate python3 scripts/run_tests_parallel.py green, 4991 ran; ruff 0.16.0 clean; sync-codex.sh idempotent source:s-t1
Live probe codex 0.153.4 workspace-write denies git commit (index.lock read-only, exit 128); danger-full-access commits source:s-t1
R-ID coverage R1-R6 satisfied in the prose commit; R7 (site pages, issue reply) deferred to the release walk source:s-c1, source:s-t1

Legend: WHY PRINCIPLE STEP KEPT VERIFY · NEW MODIFIED DELETED RENAMED COPIED · CANONICAL GENERATED MECHANICAL

WHY 0. A prohibition that bought nothing and cost nineteen dispatches — The bridge recipes said the bridged child never commits. On a one-task spec run through a codex exec implementer that left two shapes: one multi-hour run ending in a single uncommitted diff, or host-inserted returns between spec steps so the host could commit, plus a timebox line that taught the implementer to return partial. One task took nineteen dispatches with a re-brief each time. The in-host worker already commits per task and the host reviews its commit range; the bound that matters is push, rewrite, scope, and verdict, not the local commit.

Evidence: source:s-spec

STEP 1. The rule, restated on every canonical surface — The safety rule now reads: the bridged child writes code and may commit checkpoints on the branch the host names; it never pushes, never rebases or rewrites history, never decides scope, never issues a review verdict, and never spawns a bridge; the host keeps push, review, flowctl done, task state, and any history rewrite, and on return reviews the child's commit range from the base it recorded before dispatch. Applied to the usage template's bridge section, the orchestration guide (bridge route, host-model paragraph, field-pattern table, what-stays-fixed list), the running-lean pointer sentence, and this repo's own routing block in CLAUDE.md and AGENTS.md.

Evidence: source:s-t1, source:s-c1, source:s-r1, source:s-r2, source:s-r3, R-ID:R1, R-ID:R2, R-ID:R3, task:fn-244-bridged-implementer-may-commit.1

Change Attention File Purpose +/- Diff Evidence
MODIFIED CANONICAL AGENTS.md Routing block: child may commit checkpoints; host keeps push, rewrite, review, task state, verdict. +3/-2 source:s-diff
MODIFIED CANONICAL CLAUDE.md Same routing-block sentence as AGENTS.md. +3/-2 source:s-diff
MODIFIED CANONICAL plugins/flow-next/docs/orchestration.md Bridge-route rule, host-model paragraph, field-pattern table row, what-stays-fixed bullet. +5/-5 source:s-diff
MODIFIED CANONICAL plugins/flow-next/docs/running-lean.md Pointer sentence names the new rule and the brief. +1/-1 source:s-diff
STEP 2. Usage guide: return handling, the long-task brief, the sandbox fallback — The usage template's bridge section carries the new safety rule, the host's on-return obligation (record the base, review base..HEAD, run the gates on that diff, host-owned squash or keep), a brief template for long bridged tasks that names the branch, commit convention, checkpoint unit, the five never clauses, and one return condition with an explicit warning against timeboxes, and the fallback for a sandbox that denies commits. A live probe fixed the codex wording: workspace-write keeps .git read-only, so a checkpointing child runs danger-full-access inside the asserted repo root or falls back to one run per scope unit.

Evidence: source:s-t1, source:s-c1, source:s-r4, source:s-r5, R-ID:R4, R-ID:R5, task:fn-244-bridged-implementer-may-commit.1

Change Attention File Purpose +/- Diff Evidence
MODIFIED CANONICAL plugins/flow-next/templates/usage.md Safety rule, codex sandbox note, return handling, brief template, denied-commit fallback. +17/-1 source:s-diff
STEP 3. Changelog entry crediting the reporter — An Unreleased Changed entry states the old rule, the new rule, why the local commit is safe to allow, the brief template and sandbox fallback, that no hook or flowctl guard is added, and credits the reporter of issue #431.

Evidence: source:s-t1, source:s-c1, source:s-r6, R-ID:R6, task:fn-244-bridged-implementer-may-commit.1

Change Attention File Purpose +/- Diff Evidence
MODIFIED CANONICAL CHANGELOG.md Unreleased entry for #431. +4/-0 source:s-diff
KEPT 4. What did not change — No hook, guard, or flowctl subcommand enforces the rule; bridge safety stays prose-only per the recorded decision. The in-host worker, flowctl done, review backends, and the thin-wrapper recipe are untouched beyond the sentence that names the rule. The flow-next.dev pages that restate the rule and the reply on issue #431 (R7) are left for the downstream release walk in the site repo.

Evidence: source:s-spec, source:s-t1

VERIFY 5. Gate, mirror regeneration, and task state — Full parallel suite green (4991 ran), ruff clean, sync-codex.sh run twice with no drift. The Codex mirror files are regenerated output; the .flow files are the spec, the minted implicit-owner task, and its receipt.

Evidence: source:s-t1, task:fn-244-bridged-implementer-may-commit.1

Generated/mechanical files (7)
Change Attention File Purpose +/- Diff Evidence
NEW MECHANICAL .flow/specs/fn-244-bridged-implementer-may-commit.json Spec sidecar. +80/-0 source:s-diff
NEW MECHANICAL .flow/specs/fn-244-bridged-implementer-may-commit.md Captured spec body. +76/-0 source:s-diff
NEW MECHANICAL .flow/tasks/fn-244-bridged-implementer-may-commit.1.json Task sidecar. +15/-0 source:s-diff
NEW MECHANICAL .flow/tasks/fn-244-bridged-implementer-may-commit.1.md Task file with done summary and evidence. +28/-0 source:s-diff
MODIFIED GENERATED plugins/flow-next/codex/docs/flow-next/orchestration.md Regenerated by sync-codex.sh. +5/-5 source:s-diff
MODIFIED GENERATED plugins/flow-next/codex/docs/flow-next/running-lean.md Regenerated by sync-codex.sh. +1/-1 source:s-diff
MODIFIED GENERATED plugins/flow-next/codex/templates/usage.md Regenerated by sync-codex.sh. +17/-1 source:s-diff

Critical changes

How to review this PR

The pipeline already verified this — you don't re-check it from scratch:

  • Tests / gates: full parallel suite green (4991 ran), ruff 0.16.0 clean, sync-codex.sh idempotent; live probe of codex 0.153.4 sandbox commit behaviour recorded in the task evidence.
  • R-ID coverage: 7/7 acceptance criteria evidenced (R7's site-page half is deferred to the release walk and named in the task summary).
  • Cross-model review: per-task implementation review reached SHIP on the codex backend (three draws, zero findings) per the task receipt.

Your job — the calls the pipeline can't make:

  • Line-review the Must review bucket below — the ~15% that carries real judgment risk.
  • Own the policy call: is allowing a local checkpoint commit, with push/rewrite/scope/verdict still forbidden, the bound you want on a bridged child?
  • Judge whether recommending danger-full-access for a checkpointing codex child is acceptable, given the asserted-repo-root guard around it.

Review plan

Must review (~15%)

  • 🔴 plugins/flow-next/templates/usage.md — high-churn canonical file and the shipped user-facing recipe — Does the brief template give a bridged child exactly the five never clauses and one return condition, with nothing that reads as a timebox? — open the "Long bridged tasks" paragraph and the text fence below it.
  • 🔴 plugins/flow-next/docs/orchestration.md — the canonical guide restates the rule in four places — Do all four say the same thing, and does "the host keeps git" survive nowhere? — open "Two rules survive from the packaged path".
  • 🔴 CLAUDE.md / AGENTS.md — instruction files every session reads — Is the routing-block sentence identical in both files? — open the model-routing block.

Spot-check

Safe to skim (~85%)

  • ⚪ 3 files under plugins/flow-next/codex/ — regenerated by sync-codex.sh, idempotent on a second run — skim.
  • ⚪ 4 files under .flow/specs/ and .flow/tasks/ — spec, minted implicit-owner task, and its receipt; task-state, not hand-written code — skim.

Decisions made

No decision-track memory entries were written for this spec. The rationale lives in the spec's Decision Context and the changelog entry: a local commit is reversible and reviewable; push, rewrite, scope, and verdict are the bounds that matter. The standing decision that bridge safety is prose-only (recorded 2026-08-14) is unchanged.

Open items

  • R7's second half: the flow-next.dev pages that restate the rule (work page, model-routing guide, cookbook entry, landing-page card) and the reply on Bridged implementer may not commit, which turns one-task specs into many host-driven turns #431 belong to the downstream release walk in the site repo.
  • plugins/flow-next/docs/release-history.md still describes the old rule as history under 4.0.0; it is append-only and gets its line when the release that carries this change is cut.

Generated by /flow-next:make-pr from fn-244-bridged-implementer-may-commit against origin/main on 2026-09-14.

https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL

…box-free brief for long bridged tasks

- Bridge safety rule now reads: the child writes code and may commit checkpoints on the branch the host names; never push, never rebase or rewrite history, never decide scope, never issue a verdict, never spawn a bridge; the host keeps push, review, flowctl done, task state, and any history rewrite (usage template, orchestration guide, running-lean pointer, CLAUDE.md/AGENTS.md routing blocks, Codex mirror regenerated)
- Usage guide states the host's on-return obligation (record base, review the commit range, run the gates on that diff, host-owned squash-or-keep) and carries a brief template for long bridged tasks with no timebox
- Sandbox fallback named from a live probe: codex 0.153.4 workspace-write keeps .git/ read-only (index.lock: Read-only file system); danger-full-access in the asserted repo root permits the commit, else one run per scope unit with the host committing between
- Changelog entry credits @DanielKillenberger (#431)

Task: fn-244-bridged-implementer-may-commit.1

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL
Copilot AI lite review requested due to automatic review settings September 14, 2026 07:52

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@cursor

cursor Bot commented Sep 14, 2026

Copy link
Copy Markdown

PR Summary

Low Risk
Prose-only policy and docs; no runtime hooks or flowctl guards. Reviewers should sanity-check the new danger-full-access guidance for bridged Codex runs.

Overview
Documentation-only update to headless bridge safety: a bridged implementer may commit checkpoints on the branch the host names, while the host still owns push, history rewrite, review, flowctl done, task state, and verdicts. Push, rebase/rewrite, scope, verdict, and nested bridges remain forbidden for the child.

The flowctl usage template (and Codex mirror via sync-codex.sh) now documents host return handling (record base, review <base>..HEAD, run gates, squash-or-keep), a timebox-free brief for long bridged tasks, and a sandbox fallback when git commit is denied— notably that Codex workspace-write leaves .git/ read-only, so checkpointing may need danger-full-access in an asserted repo root or one-run-per-scope-unit with the host committing between runs.

The same rule replaces “child never commits” across orchestration, running-lean, CLAUDE.md / AGENTS.md routing blocks, and an Unreleased CHANGELOG entry crediting @DanielKillenberger (#431). flow-next.dev site pages (R7) are deferred to a downstream release walk; .flow spec/task artifacts record the work.

Reviewed by Cursor Bugbot for commit 1e6cd75. Configure here.

@gmickel
gmickel merged commit f7a9499 into main Sep 14, 2026
8 checks passed
@gmickel
gmickel deleted the fn-244-bridged-implementer-may-commit branch September 14, 2026 08:04
gmickel added a commit that referenced this pull request Sep 14, 2026
…438)

* feat(worker): bridged child owns the task; fan-out license restored; July codex caveats retired

- worker.md Phase 1b: implementer tier resolved before Phase 1.5; a CLI-reached
  model hands the task to the bridged child via pointer prompt + usage brief,
  one foreground bridge call, dirty-remainder commit, base..HEAD range review,
  focused gates, then Phase 3; `stage: implement` line records model + delegated count
- work phases.md 3c and the SECTION3C mirror heredoc: the worker bridges and the
  conductor never does; mirror 3c carries the implementer-tier paragraph again,
  with grep guards for both literals
- usage.md long-task brief: "never spawn another bridge"; carries the
  judicious-subagent license and asks for the delegation count in the digest;
  no-plan-route.md names the owner as the holder wherever it runs
- July "keep the child flat" caveats (usage.md self-bridge line, codex reach
  page shell-out row) are dated watch lines naming openai/codex#33267 with the
  0.153.4 / gpt-6-astra measurements and the 0.144-0.145 reported range
- fn-98 R2 folded in: codex reach page in-host row and platforms.md worker-pin
  note state the measured steering facts; fn-98 closed with a pointer, R4-R9
  recorded as undone
- STRATEGY.md "The owner holds the license"; .flow/criteria.md G3; bug memory
  entry for the #436 widening; CHANGELOG Unreleased entry
- Codex mirror regenerated (sync-codex.sh twice, clean second run)

Task: fn-245-bridge-child-owns-the-task-worker.1

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL

* fix(worker): carry the invocation's implementer override; align the forwarded license and the stage-line model source

- work 3c dispatch (canonical + SECTION3C mirror heredoc) gains the optional
  IMPLEMENTER line; worker Phase 1b consults it as the highest routing rung
- no-plan-route.md license names the owner as the only committer and defers
  the commit convention to the owner's path, so the forwarded paragraph agrees
  with the long-task brief's checkpoint convention
- Phase 1b records `model:` from the bridge command line (never the child's
  self-report) and `delegated:` from the digest
- Codex mirror regenerated (sync-codex.sh twice, clean second run)

Review round 1 (codex, three draws): three merged findings, all addressed.

Task: fn-245-bridge-child-owns-the-task-worker.1

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL

* fix(usage): keep the #33267 watch line identifier-free; capture the review-round memory entry

- usage.md names the codex-cli versions, counts, date and issue; the model
  identifier stays on the codex reach page (fn-195 R2 guard)
- bug memory entry for the fn-245 review round (forwarded license carried the
  wrong holder's commit contract)
- Codex mirror regenerated (sync-codex.sh twice, clean second run)

Task: fn-245-bridge-child-owns-the-task-worker.1

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL

* chore(flow): task receipt fn-245-bridge-child-owns-the-task-worker.1

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL

* chore(flow): record completion-review skip for fn-245

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL

* Address PR review feedback (#438)

- Phase 1b: inert and unreachable branches end the phase explicitly; Done-when scoped to the bridged branch
- Investigate-first rule carries the Phase 1b bridged carve-out in sibling-rule shape
- Conduct checklist gains the bridged-implementer contract with its failure clause

Claude-Session: https://claude.ai/code/session_01JFYv5JtK8HAsshpWRAT5YL
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.

Bridged implementer may not commit, which turns one-task specs into many host-driven turns

2 participants