fix: add missing ServiceManager.notifyStatusChange() calls for service timeout failures

This commit is contained in:
Roo Code 2025-11-16 11:06:39 +00:00
parent d476095cb3
commit 228c014986
2 changed files with 3 additions and 1 deletions

View file

@ -700,6 +700,7 @@ async function executeServiceCommand(
} catch (error) {
const errorMessage = error instanceof Error ? error.message : String(error)
serviceHandle.status = "failed"
ServiceManager.notifyStatusChange(serviceHandle)
const status: CommandExecutionStatus = {
executionId,
status: "service_failed",
@ -763,6 +764,7 @@ async function waitForPattern(
// Timeout check
if (Date.now() - startTime > timeoutMs) {
serviceHandle.status = "failed"
ServiceManager.notifyStatusChange(serviceHandle)
clearInterval(checkInterval)
reject(new Error(`Service ready pattern not matched within ${timeoutMs}ms`))
}

View file

@ -323,7 +323,7 @@ export class ServiceManager {
/**
* Notify status change
*/
private static notifyStatusChange(serviceHandle: ServiceHandle): void {
static notifyStatusChange(serviceHandle: ServiceHandle): void {
for (const callback of this.statusChangeCallbacks) {
try {
callback(serviceHandle)