fix: update references to removed stack methods and add compatibility shims for tests

This commit is contained in:
Roo Code 2025-08-11 21:28:08 +00:00
parent 7507059f0c
commit 48df752435
3 changed files with 11 additions and 2 deletions

View file

@ -94,7 +94,7 @@ const getCommandsMap = ({ context, outputChannel, provider }: RegisterCommandOpt
TelemetryService.instance.captureTitleButtonClicked("plus")
await visibleProvider.removeClineFromStack()
await visibleProvider.deactivateCurrentTask()
await visibleProvider.postStateToWebview()
await visibleProvider.postMessageToWebview({ type: "action", action: "chatButtonClicked" })
// Send focusInput action immediately after chatButtonClicked

View file

@ -2235,6 +2235,15 @@ export class ClineProvider
})
}
}
// Compatibility methods for tests - these wrap the new persistent task management
async addClineToStack(task: Task): Promise<void> {
await this.activateTask(task)
}
async removeClineFromStack(): Promise<void> {
await this.deactivateCurrentTask()
}
}
class OrganizationAllowListViolationError extends Error {

View file

@ -143,7 +143,7 @@ export class API extends EventEmitter<RooCodeEvents> implements RooCodeAPI {
}
}
await provider.removeClineFromStack()
await provider.deactivateCurrentTask()
await provider.postStateToWebview()
await provider.postMessageToWebview({ type: "action", action: "chatButtonClicked" })
await provider.postMessageToWebview({ type: "invoke", invoke: "newChat", text, images })