-
-
Notifications
You must be signed in to change notification settings - Fork 79.1k
cron wake action does not support agentId — always routes to default agent #46886
Copy link
Copy link
Open
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Metadata
Metadata
Assignees
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Summary
The
crontool'swakeaction does not accept anagentIdparameter, causing all wake events to be routed to the default agent (typicallymain) regardless of which agent should be woken.Current Behavior
The
wakefunction in the cron service only acceptstextandmode:Since
enqueueSystemEventreceives noagentId,resolveCronAgent(undefined)falls back toresolveDefaultAgentId()→ always routes tomain.Expected Behavior
The
wakeaction should accept an optionalagentIdparameter (and optionallysessionKey) so that wake events can target a specific agent:Contrast with Cron Job Execution
When a cron job fires normally, it correctly passes the agent ID:
So the infrastructure for multi-agent routing already exists —
wakesimply doesn't use it.Use Case
In a multi-agent setup (e.g.,
main+local-dev), a monitor cron job running underlocal-devwants to wake thelocal-devagent's main session when CI failures are detected. Currently this is impossible viacron wake— the wake event always goes tomain.Workaround: Use
sessions_sendwithtools.agentToAgent.enabled=true, but this requires additional configuration and is less ergonomic than a simple wake.Environment
main(default) andlocal-devagents