Commit Graph

58 Commits

Author SHA1 Message Date
Alassane 739eabc49a fix(agents): enforce exact profile model identity (#3473)
Co-authored-by: ayattara <alassane.yattara@savoirfairelinux.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-09-15 23:11:43 +01:00
José Almeida 4ef775afc9 fix(kubernetes): recover sessions after lost Pods (#3703) 2026-09-15 22:09:33 +02:00
Carlos Florêncio f371804f5b fix: contain workflow reset failures (#3358) (#3637) 2026-09-14 09:28:11 +01:00
Henry e75c8b37c8 feat(executors): keep worktree and local agents running across a backend restart (#3467)
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-09-13 21:42:24 +01:00
Carlos Florêncio 2a11854e13 fix: fence cancelled session recovery attempts (#3636) 2026-09-13 12:08:05 +01:00
Henry 1262d4476d fix(backend): stop orphaned agentctl processes from piling up on SSH runners (#3527)
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-09-10 23:38:36 +01:00
Henry 6597f8b9d1 feat(web,backend): show a distinct icon for tasks parked on background work (#3402)
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-09-07 21:29:15 +01:00
Carlos Florêncio cb1ffd0f58 feat(agents): resolve unique advertised model variations (#3472) 2026-09-07 19:23:17 +01:00
Carlos Florêncio d796cf131d feat(desktop): add consent-aware repository discovery 2026-09-06 11:32:14 +01:00
José Almeida 0064b9fb5a feat: add Kubernetes executor (#3261) 2026-09-02 13:50:03 +00:00
Carlos Florêncio 9f2bb78aa2 fix: clear stale dispatch gate after context reset (#3210) (#3223) 2026-08-31 22:37:19 +00:00
Carlos Florêncio 3df09051cd fix: safely recover Cursor stream resets (#3188) 2026-08-31 13:18:54 +00:00
Henry bf84fb52bd fix(backend): rescue tasks stuck running forever after a silent agent stall (#2975)
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-28 00:29:41 +00:00
Carlos Florêncio 29e4c98fff fix(agents): recover executor-local npm runtime caches (#2986) 2026-08-24 21:05:02 +00:00
Luan Martins a728a0fed7 fix(agent-runtime): retain executions when runtime stop fails (#2998)
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-24 20:39:45 +00:00
nova28 c82668c789 feat(mcp): expose agent clarification questions and permission requests externally (#2875)
Co-authored-by: Vojtěch Biberle <vojtech.biberle@gmail.com>
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-22 15:39:40 +00:00
nova28 d2518a1fb9 fix(office): stop finished runs from showing an empty output summary (#2900)
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-21 22:02:07 +01:00
Carlos Florêncio 6c97e0a237 fix(lifecycle): clear stale dispatch gate after cancel (#2825) 2026-08-19 22:47:38 +01:00
WaleWangPW 0dfd8198a7 fix(orchestrator): controller advancement — subtask WAITING guard, plan_mode gate, idle-session reclaim (#2811)
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-19 21:25:42 +01:00
Carlos Florêncio 9a6240d1d4 fix: preserve ACP runtime configuration across reset (#2790) 2026-08-19 07:49:25 +01:00
nova28 4100b5b5b0 fix(orchestrator): fail never-started agent turns instead of reporting healthy (#2776)
Co-authored-by: nova28 <17953305+nova28@users.noreply.github.com>
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-18 21:57:00 +01:00
Carlos Florêncio 7c96621de1 feat: add executor parity safeguards (#2704) 2026-08-16 21:13:41 +00:00
Carlos Florêncio e86202647e fix(runtime): recover stale npm metadata (#2714) 2026-08-16 17:41:43 +01:00
Carlos Florêncio 45c9ba5554 fix(agents): add validated managed runtime recovery (#2580) 2026-08-13 12:14:01 +01:00
Carlos Florêncio 76ccc667ce fix(backend): don't surface backend-shutdown turn aborts as agent failures (#2571) 2026-08-12 18:21:34 +01:00
João Salavisa ed04825bb2 fix(lifecycle): guard agent execution metadata against concurrent map access (#2472)
Co-authored-by: Kandev Agent <agent@kandev.dev>
2026-08-09 23:54:43 +01:00
Clément Fiere e4bc3be8b1 feat: no silent model fallback — explicit failure, gone models, per-profile fallback (#2385)
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-09 21:44:25 +01:00
nova28 6eaab90d9f feat: add mid-turn steering for Claude ACP sessions (#2241)
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-08-06 11:28:18 +01:00
Carlos Florêncio 2ee2fa8c66 fix: make agent turn cancellation responsive (#2228) 2026-08-04 08:09:07 +01:00
Carlos Florêncio 5e486fccf9 fix(acp): preserve model across context reset (#2079) 2026-07-30 22:40:45 +01:00
Carlos Florêncio 35d1a85d74 fix: recover failed agent resumes and managed runtimes (#1991) 2026-07-28 09:23:30 +01:00
Carlos Florêncio dc38aaf0d0 feat: update ACP compatibility and subagent handling (#1880) 2026-07-25 19:31:15 +01:00
point-source dba2057590 feat: accept input while a session's foreground turn waits on background work (#1668) 2026-07-25 18:08:35 +01:00
Carlos Florêncio 2f6be0c777 fix(agents): harden ACP launcher configuration (#1917) 2026-07-24 16:36:44 +01:00
Mathieu Virbel b4239d885e feat(agents): add configurable command prefix for sandboxed ACP launch (#1888) 2026-07-24 10:29:37 +01:00
José Almeida f7f1d10996 feat: add parent-controlled task stopping via MCP (#1803)
* feat: add parent-controlled task stopping via MCP

* fix: harden parent task stop lifecycle

* fix: preserve rejected task rollback state
2026-07-19 20:23:46 +01:00
Carlos Florêncio 21f811d5ec feat: add idle storage maintenance (#1699) 2026-07-18 19:08:44 +01:00
Carlos Florêncio 16da501fc4 feat(office): route agents through execution profiles (#1725) 2026-07-17 18:47:09 +01:00
Carlos Florêncio 3e68fd3da6 fix: prevent stale ready events from completing replacement turns (#1678) 2026-07-14 13:20:52 +01:00
Clément Fiere 84e40ee4c8 feat: interrupt busy child task turn on parent message_task_kandev (#1653) 2026-07-14 09:07:58 +01:00
point-source e1cf99f821 fix(executors): truthful executor rows, startup reconciliation, resume-safe cleanup (#1597) (#1608)
Co-authored-by: Carlos Florencio <carlosmflorencio@gmail.com>
2026-07-08 23:37:02 +01:00
Carlos Florêncio c3f713e494 feat: scope GitHub integration settings by workspace (#1572) 2026-07-06 21:43:13 +01:00
Carlos Florêncio 85950a4b69 fix: persist live executor runtime state (#1585) (#1587) 2026-07-03 15:39:06 +01:00
Carlos Florêncio 8e9a41efab fix: recover stale prompts and invalid monitors (#1581) 2026-07-02 20:27:13 +01:00
Carlos Florêncio 49c482bd4d fix: prevent leaked agent processes on shutdown (#1498) 2026-06-26 10:09:23 +01:00
Carlos Florêncio aee1846cd5 feat: remove nextjs production runtime (#1389) 2026-06-18 18:36:48 +01:00
Carlos Florêncio 326297c3e7 fix(agent): avoid oversized env spawn failures (#1344) 2026-06-11 22:25:58 +01:00
Carlos Florêncio 64140ae942 fix(acpdbg): read claude agent models and modes from configOptions (#1310) 2026-06-08 22:44:02 +01:00
Carlos Florêncio df9a68a103 fix(agentctl): unblock next prompt when agent does not acknowledge cancel (#1259) 2026-06-03 22:36:24 +01:00
João Salavisa 9aaf3170e0 fix(lifecycle): drain StreamManager goroutines in tests (#1227)
* fix(lifecycle): drain StreamManager goroutines in tests

Goroutines spawned by `agentctl.Client.StreamUpdates` /
`StreamWorkspace` and by `lifecycle.StreamManager.connectWorkspaceStream`
could outlive the tests that created them on slow CI runners, causing
intermittent `goleak.VerifyTestMain` failures in
`internal/agent/runtime/lifecycle` even though every individual test
passed. The leak required the test to race: `client.Close()` could
return while a workspace dial was still in flight, leaving the
just-spawned WS read/write loops with nobody to drain them, and
`StreamManager.Wait()` only fired the drain when the external `stopCh`
had been closed first.

Make the close paths absolute drain barriers:

- `Client.Close()` now tracks every stream goroutine it spawns
  (`streamWG` + a per-stream `WorkspaceStream` reference) and blocks
  until all of them have exited. A `closed` flag flipped under the
  client mutex makes subsequent `StreamUpdates` / `StreamWorkspace`
  calls reject the dial, so a Close that races a dial in flight cannot
  leave behind a stranded WS connection. `manager_interaction.go`
  switches the restart path to per-stream Close helpers so it can keep
  reusing the client after teardown.
- `StreamManager.Wait()` closes a new internal `waitCh` that the retry
  backoff (`sleepOrStop`) and the connected `<-ws.Done() / <-stop>`
  select also observe. This makes `Wait` an absolute drain barrier
  regardless of whether the caller ever closes the external `stopCh`.
  `streamContext` carries both stops through `stopChannelContext` so
  in-flight WebSocket dials cancel on either signal.

Local stress (`make test-lifecycle-goleak LIFECYCLE_GOLEAK_COUNT=20`)
passes 20/20 with `-race` after the fix. The new
`TestClientClose_DrainsStreamGoroutines` covers the drain barrier and
the post-Close rejection path. Added a `test-lifecycle-goleak`
Makefile target as the repro hook for the CI-only flake.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* fix(lifecycle): track mergeStops goroutine and guard workspace stream races

Address PR review feedback:
- stopChannelContext now registers the mergeStops goroutine on an optional
  *sync.WaitGroup so sm.wg.Wait stays a true drain barrier even for the
  connectUpdatesStream path (outer goroutine returns immediately after dial).
- StreamWorkspace re-checks workspaceStreamConn after dial to seal the
  concurrent-callers race that could orphan a conn.
- readWorkspaceStream's defer now guards the workspaceStreamConn reset by
  identity so an old read goroutine cannot zero out a newer conn pointer.
- Clarify comments on streamWG, Client.Close, and the mock.connected wait
  in the close-barrier test.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* fix(lifecycle): drop agent-stream drain barrier to unblock workflow cascade

The previous Close drain barrier for the agent (updates) stream blocked
the on_turn_complete cascade flow. completeAndStopSession calls Close
synchronously on the current session's client, and Close was waiting on
streamWG (which tracked the read goroutine). The wait stalled the
cascade long enough that Step2's auto-started session never got its
profile name into the tab — surfacing as a flaky "Profile B tab not
visible" failure in workflow-agent-switch E2E shard 7.

Drain barrier is still in place for the workspace stream (where the
original goleak flake lived). Agent stream is closed but not awaited:
the cascade legitimately stops + restarts the agent stream on the same
client, and the workspace stream's existing barrier is sufficient for
the leak coverage.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
Co-authored-by: Kandev Agent <agent@kandev.dev>
2026-06-03 11:06:17 +01:00