{"record":{"id":"ab722d67b368bedb","repo":"deepseek-ai/deepseek-harness","slug":"subprocess-e2b-remote-wrapper-published-invalid-p","errorCode":null,"errorMessage":"subprocess-e2b: remote wrapper published invalid process-group id ${JSON.stringify(value)}","messagePattern":"subprocess-e2b: remote wrapper published invalid process-group id (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/e2b/subprocess-e2b/src/process.ts","lineNumber":497,"sourceCode":"      this.outputReleased.signal.addEventListener('abort', onRelease, { once: true })\n      if (this.terminationController.signal.aborted || this.outputReleased.signal.aborted) onRelease()\n    })\n  }\n\n  private async waitForProcessGroupId(sandbox: Sandbox, completion: Promise<CommandResult>): Promise<number> {\n    const commandSettled = completion.then(\n      () => true,\n      () => true,\n    )\n    while (true) {\n      // TODO(e2b-publication-cancel): Join cancellation to the existing\n      // termination transaction before aborting an in-flight SDK file read.\n      const raw = await sandbox.files.read(this.paths.pid)\n      const value = raw.trim()\n      if (value.length > 0) {\n        const pid = Number(value)\n        if (!/^[1-9][0-9]*$/.test(value) || !Number.isSafeInteger(pid)) {\n          throw new Error(`subprocess-e2b: remote wrapper published invalid process-group id ${JSON.stringify(value)}`)\n        }\n        // A same-UID sandbox process can rewrite this file; refuse ids whose\n        // negative form addresses every process (`kill -- -1`) or init's group.\n        if (pid <= 1) {\n          throw new Error(`subprocess-e2b: unsafe published process-group id ${pid}`)\n        }\n        return pid\n      }\n      const settled = await Promise.race([commandSettled, waitTick(this.pollMs).then(() => false)])\n      if (settled) throw new Error('subprocess-e2b: remote command exited before publishing its process-group id')\n    }\n  }\n\n  private async waitForCommand(\n    sandbox: Sandbox,\n    handle: CommandHandle,\n    completion: Promise<CommandResult>,\n  ): Promise<SubprocessOutcome> {","sourceCodeStart":479,"sourceCodeEnd":515,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/e2b/subprocess-e2b/src/process.ts#L479-L515","documentation":"Error \"subprocess-e2b: remote wrapper published invalid process-group id ${JSON.stringify(value)}\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/e2b/subprocess-e2b/src/process.ts:497 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"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"}