fix(daemon): register autospawned agent in store for task routing #253
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "fix/autospawn-agent-registration"
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?
After autospawn spawns zot, the agent was never registered in the
local SQLite store. The scheduler only routes tasks to registered
agents — so every task stayed stuck in 'queued' forever.
This commit adds a store.register_agent() call right after the spawn
succeeds, before the bootstrap RPC prompt. The agent is registered
with [shell, freebsd, code] capabilities and the current hostname.
Uses try_lock() to avoid blocking the daemon on store contention.