You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug(platform): an answer refused for sandbox room after the cursor retarget loses the asking conversation #4719
resumeWorkflowAgentTurnWithAnswerImpl delivers a person's answer to a parked automation agent node in this order (services/platform/backend/core/automations/agent_host.ts): ensure the session (L2104), retarget the run's agent cursor to a fresh exec id (L2208-2226, retargeted = true), stamp the launch, then start the harness exec through drainHarnessWindow (L2390-2397). A refusal for sandbox room settles with sandbox_capacity and carries undeliveredAskId plus the asking conversation's agentSessionId — but only when !retargeted (L2443-2450). Verified on main at 73d03a9.
The refusals that happen at exec start — the session runtime's session_memory_busy (SessionMemoryBusyError), the live-exec cap — all arrive after the retarget, so their settles drop both facts. The retarget does not record them on the cursor either (services/platform/backend/domains/automations/shim.ts:821-897). workflowAgentRetryResume (core/automations/agent_retry.ts:189-233) then has no ask to deliver and no handle to resume: the re-kick starts the node's conversation over, or resumes an older resumedFrom from an earlier retry. Nothing launched in either case, yet the conversation that asked the question is lost and the agent may ask again.
Suggested fix
A room refusal means nothing launched, before or after the retarget: carry undeliveredAskId and agentSessionId on every room-refusal settle (drop the !retargeted condition there), or record both on the cursor in retargetAgentCursor. Test: the exec start throws SessionMemoryBusyError after the retarget, and the re-kick resumes the asking conversation with the answer.
Activity
fix(platform): resume the asking conversation after a room refusal