fd014f6a7fd31bbaaa440eb3d09de61961c3c6da
When an operator stopped a running task via chat /stop or the dashboard Stop button, the task's context was cancelled. Container teardown correctly completed (as Pool.Release detached its context), but terminal state recording in Daemon.runViaAgent and worktree cleanup in Daemon.cleanupTerminalTaskWorktree executed using the same cancelled context. Consequently, SQLite transactions in store.Transition failed immediately and errors were discarded, leaving the task row in 'running' indefinitely until a daemon restart. Extract parkRunningTask in internal/daemon/daemon.go to perform guarded state transitions (store.StatusRunning -> store.StatusParked) using a detached context (context.WithoutCancel) with a bounded 10-second timeout. Update cleanupTerminalTaskWorktree to also use a detached 10-second context for looking up the task status. Check transition errors and log warnings for unexpected database failures while suppressing expected ErrStaleTransition returns when workers have already completed. Add comprehensive table-driven regression tests covering task cancellation, worktree cleanup, and logging behavior.
Description
Archie connects events from your systems to agents that can investigate, reason, and act.
Define what an event means, map its data into a workflow, and give that workflow an agent equipped for the job: its own execution environment, tools, and identity.
https://archie.catlow.cloud
132 MiB
0 Stars
1 Watchers
0 Forks
Releases
11
Archie v1.62.0
Latest
Languages
Go
76.7%
Vue
13.1%
TypeScript
7.8%
JavaScript
1.2%
Shell
0.6%
Other
0.4%