push mode: worker never pushes main; HOST lands after verify (#193) — rebased #245
No reviewers
Labels
No labels
agent-blocked
agent-working
bug
deferred
enhancement
landing-pr
model-haiku
model-opus
model-sonnet
needs-info
needs-triage
no-triage
priority
ready-for-agent
ready-for-human
ready-for-session
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Matou/dev-factory!245
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "land/issue-193"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
closes #193
Supersedes PR #229 (same commit, rebased onto
mainafter #232 landed — a force-update ofagent/issue-193was not permitted from the interactive session, so the rebased work lives onland/issue-193).#193 — push mode: the worker never pushes
main; the HOST lands after verifyRebase notes (2026-10-16, Ben's Claude Code session):
policy-lib.shkeeps #222's credential-free parenthetical over this PR's token-URL fallback;tests/policy-lib-test.shcarries both assertion sets;.sandcastle/prompt.md+ the idss cutover fixture re-rendered from the resolved source;STATUS.mdkeeps the #230 single-header shape. The PR's 8 named tests +onboard-lib-test.shgreen, full offline suite 0 failures.See PR #229 for the original description and the close-report on #193.
🤖 Generated with Claude Code
The push-mode landing guidance (policy_landing_guidance, rendered into every consumer's prompt via {{LANDING_RULES}}) no longer tells the worker to `git push origin HEAD:refs/heads/main` from the sandbox. The worker pushes its per-run worker branch (HEAD:refs/heads/$(git rev-parse --abbrev-ref HEAD), the sandcastle/worker/<run> branch it is on); the HOST promotes it to main only after the post-run verify gates (worker-birth + the protected-path boundary). The gates that were cosmetic while the worker pushed main itself now genuinely gate. The in-sandbox rebase + the #217 re-test ladder are gone (a worker branch has no main conflict; the host owns the rebase-rescue ladder #207). Key decisions / files: - policy-lib.sh: rewrite the "landing": "push" branch (worker branch, never main). - verify-lib.sh: PP_ENFORCE defaults ON (rollback now keeps a breach off main); verify_protected_paths raises VERIFY_PP_VIOLATION. - landing-lib.sh: new landing_pp_breach_guard — the land seam never pushes a flagged protected-path breach to main (parks a rescue, reds the run). - close-report.sh: push-mode gate 1 verifies reachability from the worker-branch head pre-land (origin/<wb>); a commit on neither the worker branch nor main is a safe refusal, never a false close. - Prompts re-rendered: .sandcastle/*prompt.md (per-repo layer) + onboarding/tests/fixtures/idss-prompts/prompt.md; cutover re-proven byte-identical. - Tests: policy-lib, prompt-render, worker-conflict-retest (re-anchored), verify-lib (PP default-on + VERIFY_PP_VIOLATION), landing-lib (breach->rescue), run-swarm-landing (verify-before-push ordering), close-report (WB worker-branch gate 1). Full offline suite green. Deferred (not formal ACs): explicit HOST post-land "reachable from main" check; a pinned-host-test land gate (LANDING_TEST_CMD unset across consumers -> would fail-closed-park every run). dev-factory STAYS LANDING=pr until the coordinated re-vendor carries this into the running .sandcastle copy (reverting sooner would restore the old worker-pushes-main behaviour the vendored copy still has). Out of scope: reviewer agent #197, server-side branch protection #194, healer push path #203. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>