Files
cline/apps/vscode
Dominic Cooney b4aed24ff8 fix(vscode): compact tasks opened from history (#12002)
* fix(vscode): compact tasks opened from history

The compact button only worked while a session was actively running.
Opening a task from history and clicking compact errored with "There is
no active task to compact."

Compaction is defined over a session transcript, so rather than grow a
second implementation for displayed tasks, resume a displayed history
task on an isolated session host and compact it through the existing
path. The coordinator owns and disposes that host, so task navigation
cannot make cleanup stop a replacement active session.

Follow-up resume and both compaction paths (idle active session and
displayed task) acquire the same session-rebuild boundary around
transcript read, session start, and persistence. Task and session
object identity are rechecked across awaits; cleanup targets only the
exact host and session started by the operation. A follow-up abandoned
by task navigation settles the streaming turn phase it pre-set, so the
newly displayed task never shows a stuck Thinking/Cancel footer.

The resume-start preparation shared by follow-up and compaction is
extracted into prepareTaskResumeStartInput, including legacy task
conversion, so the two callers cannot drift apart.

The compaction divider UX and context-meter shrink remain owned by the
already-merged webview compaction change.

* fix(vscode): deliver follow-ups across a same-task proxy reload

Follow-up targeting checks compared the displayed TaskProxy by object
identity, but showTaskWithId allocates a fresh proxy for the same task
id, so reloading the task mid-resume silently dropped the message.
Compare targeting by taskId; cleanup keeps object identity.
2026-07-28 10:52:13 -07:00
..
2026-05-25 21:35:59 +02:00
2026-07-28 06:20:28 +02:00
2026-05-25 21:35:59 +02:00
2026-06-24 14:11:35 +09:00
2026-05-25 21:35:59 +02:00
2026-06-24 14:11:30 +09:00
2026-06-03 18:58:27 +02:00
2026-05-25 21:35:59 +02:00
2026-05-25 21:35:59 +02:00
2026-06-24 14:11:35 +09:00