Skip to content

spawn_agent reports FAILURE while creating a live, working agent — boot prompt typed but not submitted #415

Description

@EtanHey

Etan caught this live in the golemsflip lead's pane, 2026-08-14. Not previously filed.

spawn_agent({repo:"golems", cli:"codex", role:"worker", effort:"high", force_new:true}) returned a hard error:

{"ok":false,
 "error":"Boot prompt delivery failed after 258 chars: Enter submit could not be verified for surface:855 within 5000ms",
 "delivered":false,"terminal":false,"typed":true,
 "submit_attempted":true,"submit_verified":false,
 "submit_verification_reason":"input_still_pending","retry_safe":false,
 "agent_id":"golemsCodex-4db3349d","surface_id":"surface:855","workspace_id":"workspace:1",
 "delivered_chars":258}

But the agent was created, booted, and is now working. Verified minutes later:
surface:855agent_type:"codex", status:"working", control_state:"busy", model:"gpt-5.6-sol high", actively reading files in ~/Gits/golems. The boot text was sitting in the composer unsubmitted at the moment of the error, and went through afterwards.

Why this is a defect, not a cosmetic message

This is the same family as the #409 B1 blocker — side effects commit while the call reports failure — on the spawn path:

  • The caller is told the spawn failed. A live worker exists anyway.
  • With force_new:true, a lead that retries gets a second agent. The natural response to "failed" is exactly the wrong action.
  • retry_safe:false is present and correct, which is the only thing preventing this from being worse — but it is a field buried in an error payload whose headline says the operation failed.

The receipt fields themselves are honest (typed:true, submit_verified:false, delivered:false) — that is the #404/#409 contract working. The bug is the framing: a partially-successful operation is reported as a total failure.

Suggested

ok:true with an explicit unsubmitted state, since the agent genuinely exists: return the identity triple plus something like boot_prompt: {typed:true, submitted:false} and a named next action ("the agent is live; its brief is typed but unsent — resend or press Return"). Reserve ok:false for spawns where no agent was created. The caller needs to distinguish "nothing happened, retry" from "an agent exists, finish delivering to it" — today it cannot.

Likely contributing cause

delivered_chars: 258 and the composer contents show the payload that failed to submit was the mailbox contract preamble, not the task brief — the same verbose boot text filed in #400. A shorter boot payload would reduce exposure to this 5000ms verification window, though it would not fix the framing.

Related

#400 (boot-prompt verbosity), #409 B1 (side effects commit while call reports failure), ledger #20/#21 (paste-no-submit class).

— cmuxlayerClaude (lead) · claude-code/claude-fable-5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions