{"record":{"id":"bce3ab2ebf7f015f","repo":"deepseek-ai/deepseek-harness","slug":"agent-start-bce3ab","errorCode":"AGENT_START","errorMessage":"agent() could not start a child: ${renderThrown(error)}","messagePattern":"agent\\(\\) could not start a child: (.+?)","errorType":"exception","errorClass":"WorkflowError","httpStatus":null,"severity":"error","filePath":"packages/workflow/workflow-worker-thread/src/runtime.ts","lineNumber":288,"sourceCode":"      // tick even when a slot is free, and a queued waiter resumes a tick\n      // after its release — a cancel() landing in either window must not\n      // reach the host (which would refuse anyway, but the refusal reads as\n      // a start failure rather than the cancellation it is).\n      this.throwIfCancelled()\n      let run: ChildHandle\n      try {\n        run = await this.children.startAgent({\n          prompt: rawPrompt,\n          ...opts.schema !== undefined ? { schema: opts.schema } : {},\n          ...opts.provider !== undefined ? { provider: opts.provider } : {},\n          ...opts.model !== undefined ? { model: opts.model } : {},\n        })\n      } catch (error: unknown) {\n        // The host refuses starts once the run is cancelled — a refusal that\n        // races our own cancel state must read as the cancellation it is,\n        // not as a broken contract.\n        if (this.isCancelled()) throw this.cancelledError()\n        throw new WorkflowError(`agent() could not start a child: ${renderThrown(error)}`, 'AGENT_START', { cause: error })\n      }\n      // The start round-trip yields to the event loop, so a cancel CAN land\n      // between the host starting the child and this continuation running —\n      // wind the fresh child down instead of leaving it live behind a dead\n      // script.\n      if (this.isCancelled()) {\n        await run.dispose()\n        throw this.cancelledError()\n      }\n      const info: WorkflowAgentInfo = { seq, label, ...phase !== undefined ? { phase } : {}, childId: SessionId(run.id) }\n      this.observer.agentStart(info)\n      try {\n        let result\n        try {\n          result = await run.result\n        } catch (error: unknown) {\n          // A rejected child result is an INFRASTRUCTURE fault relayed by the\n          // host — distinct from a child that failed and resolved. Pair the","sourceCodeStart":270,"sourceCodeEnd":306,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/workflow/workflow-worker-thread/src/runtime.ts#L270-L306","documentation":"Error \"agent() could not start a child: ${renderThrown(error)}\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/workflow/workflow-worker-thread/src/runtime.ts:288 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Read the embedded child-start error (provider missing, budget exhausted) and fix that cause before retrying."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b150a551b8d465e31e418e1b2eaf5e79bbb7d28e","analyzedAt":"2026-08-24T18:12:29.105Z","schemaVersion":2},"datasetVersion":"2026-08-24T22:17:12.610Z"}