MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / completeDreamTask

Function completeDreamTask

source code/tasks/DreamTask/DreamTask.ts:108–122  ·  view source on GitHub ↗
(
  taskId: string,
  setAppState: SetAppState,
)

Source from the content-addressed store, hash-verified

106}
107
108export function completeDreamTask(
109 taskId: string,
110 setAppState: SetAppState,
111): void {
112 // notified: true immediately — dream has no model-facing notification path
113 // (it's UI-only), and eviction requires terminal + notified. The inline
114 // appendSystemMessage completion note IS the user surface.
115 updateTaskState<DreamTaskState>(taskId, setAppState, task => ({
116 ...task,
117 status: 'completed',
118 endTime: Date.now(),
119 notified: true,
120 abortController: undefined,
121 }))
122}
123
124export function failDreamTask(taskId: string, setAppState: SetAppState): void {
125 updateTaskState<DreamTaskState>(taskId, setAppState, task => ({

Callers 1

initAutoDreamFunction · 0.85

Calls 1

updateTaskStateFunction · 0.50

Tested by

no test coverage detected