@openclaw/codex 2026.9.34 → 2026.9.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.setup/{account-usage-runtime-CD8HYWaz.mjs → account-usage-runtime-BaJamBiM.mjs} +3 -3
- package/dist/.setup/{apply-DN-qPbcH.mjs → apply-CxwOGLd_.mjs} +8 -8
- package/dist/.setup/{attempt-client-cleanup-93r-CLTi.mjs → attempt-client-cleanup-BVtNsTOE.mjs} +4 -4
- package/dist/.setup/{attempt-workspace-context-ejEuxrY1.mjs → attempt-workspace-context-XRsWP165.mjs} +1 -1
- package/dist/.setup/{auth-binding-BLWz7stm.mjs → auth-binding-Bnaj0_iV.mjs} +1 -1
- package/dist/.setup/{auth-cache-key-Bs_3kRJD.mjs → auth-cache-key-CskfconU.mjs} +3 -3
- package/dist/.setup/{binding-connection-DTtN1KrX.mjs → binding-connection-DRPlnIgg.mjs} +2 -2
- package/dist/.setup/{binding-connection.runtime-6TpgD1M6.mjs → binding-connection.runtime-DC3oUqo-.mjs} +1 -1
- package/dist/.setup/{bounded-turn-I8Vb-qq3.mjs → bounded-turn-DBwLoFDR.mjs} +11 -11
- package/dist/.setup/{bounded-turn-isolation-B8K_ylqk.mjs → bounded-turn-isolation-Ce-oOk-D.mjs} +2 -2
- package/dist/.setup/{build-state--SrHyc6r.mjs → build-state-B3lvV1Op.mjs} +1 -1
- package/dist/.setup/{client-CyquSiJ2.mjs → client-DcTISXe3.mjs} +7 -7
- package/dist/.setup/{client-catalog-response-B9pLl58Y.mjs → client-catalog-response-BcbsrQXY.mjs} +1 -1
- package/dist/.setup/{command-dispatch-BPLz7tlx.mjs → command-dispatch-MOoD3rsD.mjs} +1 -1
- package/dist/.setup/{command-handlers-95-WVrcl.mjs → command-handlers-Cevt_YwM.mjs} +22 -22
- package/dist/.setup/{command-rpc-BDfCWgc_.mjs → command-rpc-kf7Uq4L-.mjs} +11 -11
- package/dist/.setup/{compact-5zzFlH-W.mjs → compact-BNKuKa7o.mjs} +12 -12
- package/dist/.setup/{config-DKhXquav.mjs → config-DqmrqI23.mjs} +2 -2
- package/dist/.setup/{config-runtime-C0NbLms1.mjs → config-runtime-DDhvIeUC.mjs} +1 -1
- package/dist/.setup/{conversation-binding-C-0jWdSo.mjs → conversation-binding-CKYGEvcX.mjs} +15 -15
- package/dist/.setup/{conversation-binding-data-C746z5Pn.mjs → conversation-binding-data-DlsG-dQu.mjs} +1 -1
- package/dist/.setup/{conversation-control-BEotI-gH.mjs → conversation-control-CoWUL35l.mjs} +5 -5
- package/dist/.setup/{dynamic-tools-D3NAwGw3.mjs → dynamic-tools-Dr0ye5P3.mjs} +7 -7
- package/dist/.setup/{effective-mcp-catalog-C0DfQNYU.mjs → effective-mcp-catalog-BFJCwjSI.mjs} +4 -4
- package/dist/.setup/{ephemeral-turn-ksZ9NfsS.mjs → ephemeral-turn-Dj3iTfSP.mjs} +2 -2
- package/dist/.setup/{event-projector-assistant-message-BmWQXFLV.mjs → event-projector-assistant-message-DXDX94zH.mjs} +1 -1
- package/dist/.setup/{isolated-completion-Ci27cKqA.mjs → isolated-completion-GB52W-qA.mjs} +6 -6
- package/dist/.setup/{managed-binary-B6hQ1UKR.mjs → managed-binary-Ckgvm_4V.mjs} +1 -1
- package/dist/.setup/{model-catalog-qzAfnHzR.mjs → model-catalog-DxSrOSY0.mjs} +7 -7
- package/dist/.setup/{models-BbEE4EWS.mjs → models-BwkZaXXj.mjs} +3 -3
- package/dist/.setup/{native-auth-BN-BD2AV.mjs → native-auth-BNGz77PF.mjs} +3 -3
- package/dist/.setup/{native-subagent-monitor-B9aAqfnU.mjs → native-subagent-monitor-g-ZDkvCr.mjs} +116 -27
- package/dist/.setup/{native-subagent-pending-assignments-DwkCzLvD.mjs → native-subagent-pending-assignments-XHNn4k5q.mjs} +51 -14
- package/dist/.setup/{native-task-assignments-DMQ0g3hu.mjs → native-task-assignments-Dna952zv.mjs} +2 -2
- package/dist/.setup/{node-cli-sessions-HC4W6FLI.mjs → node-cli-sessions-BwhIYgCZ.mjs} +2 -2
- package/dist/.setup/{node-exec-server.runtime-BS7jsvK-.mjs → node-exec-server.runtime-9IZtsOmo.mjs} +2 -2
- package/dist/.setup/{plan-DTyFfTkk.mjs → plan-Cwp_21m-.mjs} +5 -5
- package/dist/.setup/{plugin-activation-cNHRfaxU.mjs → plugin-activation-BaDnJKJd.mjs} +2 -2
- package/dist/.setup/{plugin-inventory-Cky2XJUw.mjs → plugin-inventory-B4uqIw4J.mjs} +1 -1
- package/dist/.setup/{plugin-metadata-cache-Q4ZFn6UH.mjs → plugin-metadata-cache-C-LRxilF.mjs} +7 -7
- package/dist/.setup/{provider-Cnr_icbk.mjs → provider-DUotqBZ6.mjs} +4 -4
- package/dist/.setup/{provider-capabilities-ByhBukaD.mjs → provider-capabilities-DBs9l8oL.mjs} +2 -2
- package/dist/.setup/{request-DxKAfWyy.mjs → request-CWERwKIL.mjs} +5 -5
- package/dist/.setup/{run-attempt-BZKhzSrb.mjs → run-attempt-ypT0LYSD.mjs} +75 -40
- package/dist/.setup/{runtime-artifact-D7lCXdhV.mjs → runtime-artifact-Riq878B2.mjs} +3 -3
- package/dist/.setup/{runtime-artifact-connection-D68qQn1m.mjs → runtime-artifact-connection-Bjv8P6Sx.mjs} +2 -2
- package/dist/.setup/{sandbox-guard-DjCz2eOw.mjs → sandbox-guard-OIYEmTRF.mjs} +1 -1
- package/dist/.setup/{session-binding-DGCYAfvD.mjs → session-binding-Fn7Ekzuv.mjs} +19 -4
- package/dist/.setup/{session-binding-record-Oe9L-CNY.mjs → session-binding-record-CUKpUKVm.mjs} +1 -1
- package/dist/.setup/{session-binding-sidecars-jo6H8dFr.mjs → session-binding-sidecars-BuEALwJY.mjs} +1 -1
- package/dist/.setup/{session-catalog-BaVqm4-Q.mjs → session-catalog-DMagZcW-.mjs} +22 -22
- package/dist/.setup/{session-catalog-adoption-BU_pHWG7.mjs → session-catalog-adoption-58bqOngU.mjs} +5 -5
- package/dist/.setup/{session-catalog-archive-spHfihri.mjs → session-catalog-archive-BM9gCB82.mjs} +5 -5
- package/dist/.setup/{session-catalog-events-D9zC7gRb.mjs → session-catalog-events-r59AxcQ4.mjs} +3 -3
- package/dist/.setup/{session-catalog-index-CNKpHanP.mjs → session-catalog-index-CY1lNpxF.mjs} +8 -8
- package/dist/.setup/{session-catalog-index-order-BcQpHks3.mjs → session-catalog-index-order-DQhmgM3b.mjs} +1 -1
- package/dist/.setup/{session-catalog-index-state-TeO7EyO-.mjs → session-catalog-index-state-DhLoAnfy.mjs} +3 -3
- package/dist/.setup/{session-catalog-limits-DDxOsQeC.mjs → session-catalog-limits-bz5ZvjtY.mjs} +1 -1
- package/dist/.setup/{session-catalog-list-request-CvtxrYSe.mjs → session-catalog-list-request-A1wN4sKw.mjs} +2 -2
- package/dist/.setup/{session-catalog-native-projection-DhId_sl8.mjs → session-catalog-native-projection-CXTe4qQr.mjs} +4 -4
- package/dist/.setup/{session-catalog-node-adoption-DgXvSGu0.mjs → session-catalog-node-adoption-BdS7zDuY.mjs} +2 -2
- package/dist/.setup/{session-catalog-node-continue-DjKXHBbi.mjs → session-catalog-node-continue-XFJG3JGh.mjs} +5 -5
- package/dist/.setup/{session-catalog-node-lookup-CtAXI5W5.mjs → session-catalog-node-lookup-D9AP5D5o.mjs} +2 -2
- package/dist/.setup/{session-catalog-parsing-CPGaPYr-.mjs → session-catalog-parsing-CnEH565l.mjs} +1 -1
- package/dist/.setup/{session-catalog-projection-DcqN7DuI.mjs → session-catalog-projection-DcDKizZd.mjs} +4 -4
- package/dist/.setup/{session-cli-TEVHpWaE.mjs → session-cli-C3GejWcm.mjs} +2 -2
- package/dist/.setup/{session-history-import-WhX-X33a.mjs → session-history-import-tquj9DCz.mjs} +4 -4
- package/dist/.setup/{session-initialization-6aveB9qb.mjs → session-initialization-DefAI1_5.mjs} +2 -2
- package/dist/.setup/{session-permission-policy-Ci_fVX6y.mjs → session-permission-policy-7lM447LW.mjs} +1 -1
- package/dist/.setup/{session-retirement-CW0ciVbW.mjs → session-retirement-CQCMiDul.mjs} +6 -6
- package/dist/.setup/{settled-turn-finalizer-DlPT87wW.mjs → settled-turn-finalizer-w92T5Rbb.mjs} +7 -7
- package/dist/.setup/{shared-client-tOOyadmg.mjs → shared-client-ZXKMsK6f.mjs} +44 -31
- package/dist/.setup/{shared-client-lifecycle-CJ0lYVCW.mjs → shared-client-lifecycle-BH_y_i8l.mjs} +24 -2
- package/dist/.setup/{side-question-BbnuMFTT.mjs → side-question-BBZJibHK.mjs} +15 -15
- package/dist/.setup/{source-Cr8STZpF.mjs → source-Iusn97ly.mjs} +4 -4
- package/dist/.setup/{thread-lifecycle-DcNw9n7E.mjs → thread-lifecycle-CzzYMvTL.mjs} +13 -13
- package/dist/.setup/{thread-ownership-DDban_4i.mjs → thread-ownership-BT_SeSUp.mjs} +4 -4
- package/dist/.setup/{thread-policy-TTAb-1yF.mjs → thread-policy-MM5YD22L.mjs} +3 -3
- package/dist/.setup/{thread-requests-DmkmrGIt.mjs → thread-requests-y_MnVuWC.mjs} +8 -8
- package/dist/.setup/{thread-resume-eo3IhOhh.mjs → thread-resume-B9clyqXE.mjs} +5 -5
- package/dist/.setup/{transcript-mirror-kxmCYsuF.mjs → transcript-mirror-BRNhyb1o.mjs} +1 -1
- package/dist/.setup/{transport-stdio-CbutOIEh.mjs → transport-stdio-DU8dIOCj.mjs} +1 -1
- package/dist/.setup/{transport-websocket-BTBE-LD9.mjs → transport-websocket-zu3jRPnu.mjs} +1 -1
- package/dist/.setup/{upstream-session-fork-BbUNlJPZ.mjs → upstream-session-fork-2ipYynVl.mjs} +14 -14
- package/dist/.setup/{usage-CDiI_zkr.mjs → usage-BgB8DOas.mjs} +3 -3
- package/dist/.setup/{usage-limit-error-BLnJh1mB.mjs → usage-limit-error-B1FCZdeH.mjs} +1 -1
- package/dist/.setup/{web-search-provider.runtime-B_E2kpZN.mjs → web-search-provider.runtime-BWbZnYAL.mjs} +2 -2
- package/dist/.source-module-urls/78bb81623f5bb4c04c8cbd3fb1e9f10b4529f4811dc3cd99cedf5880f01c9b28.json +1 -0
- package/dist/api.js +3 -3
- package/dist/catalog-page.worker.js +1 -1
- package/dist/cli-metadata.js +1 -1
- package/dist/doctor-contract-api.js +5 -5
- package/dist/harness.js +19 -19
- package/dist/index.js +52 -42
- package/dist/media-understanding-provider.js +2 -2
- package/dist/migration-provider-api.js +1 -1
- package/dist/provider-discovery.js +1 -1
- package/package.json +4 -4
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as unwrapNodeInvokePayload, b as parseTranscriptPage, d as boundedCatalogString, f as catalogError, g as isInteractiveThreadSource, h as filterCatalogPageByTitle, n as CODEX_APP_SERVER_THREADS_LIST_COMMAND, o as CatalogParamsError, r as CODEX_APP_SERVER_THREAD_TURNS_LIST_COMMAND, u as NODE_INVOKE_TIMEOUT_MS, v as parseCatalogPage } from "./session-catalog-parsing-
|
|
2
|
-
import { n as createCodexCliNodeConversationBindingData } from "./conversation-binding-data-
|
|
3
|
-
import { r as CODEX_CLI_SESSION_SOURCE_UPGRADE_MESSAGE, t as CODEX_CLI_SESSION_RESUME_COMMAND } from "./node-cli-sessions-
|
|
1
|
+
import { A as unwrapNodeInvokePayload, b as parseTranscriptPage, d as boundedCatalogString, f as catalogError, g as isInteractiveThreadSource, h as filterCatalogPageByTitle, n as CODEX_APP_SERVER_THREADS_LIST_COMMAND, o as CatalogParamsError, r as CODEX_APP_SERVER_THREAD_TURNS_LIST_COMMAND, u as NODE_INVOKE_TIMEOUT_MS, v as parseCatalogPage } from "./session-catalog-parsing-CnEH565l.mjs";
|
|
2
|
+
import { n as createCodexCliNodeConversationBindingData } from "./conversation-binding-data-DlsG-dQu.mjs";
|
|
3
|
+
import { r as CODEX_CLI_SESSION_SOURCE_UPGRADE_MESSAGE, t as CODEX_CLI_SESSION_RESUME_COMMAND } from "./node-cli-sessions-BwhIYgCZ.mjs";
|
|
4
4
|
import { i as withTimeout } from "./timeout-CXOfNoaX.mjs";
|
|
5
|
-
import { t as lookupNodeCodexCatalogRecord } from "./session-catalog-node-lookup-
|
|
5
|
+
import { t as lookupNodeCodexCatalogRecord } from "./session-catalog-node-lookup-D9AP5D5o.mjs";
|
|
6
6
|
import { t as codexLastTerminalTurnId } from "./session-upstream-marker-D15C9NHp.mjs";
|
|
7
|
-
import { catalogSessionActions, createOrReuseNodeAdoptedSession, finalizeNodeAdoptedSession, findNodeAdoptedSessionEntry, nodeAdoptedSourceKey, nodeSessionMarker } from "./session-catalog-node-adoption-
|
|
7
|
+
import { catalogSessionActions, createOrReuseNodeAdoptedSession, finalizeNodeAdoptedSession, findNodeAdoptedSessionEntry, nodeAdoptedSourceKey, nodeSessionMarker } from "./session-catalog-node-adoption-BdS7zDuY.mjs";
|
|
8
8
|
import { resolveSessionAgentIdsStrict } from "openclaw/plugin-sdk/agent-scope-runtime";
|
|
9
9
|
import { createSessionCatalogAdoptionCoordinator, publishSessionCatalogHost, sessionCatalogAdoptedSourceKey } from "openclaw/plugin-sdk/session-catalog";
|
|
10
10
|
//#region extensions/codex/src/session-catalog-node-continue.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as unwrapNodeInvokePayload, n as CODEX_APP_SERVER_THREADS_LIST_COMMAND, o as CatalogParamsError, u as NODE_INVOKE_TIMEOUT_MS, v as parseCatalogPage } from "./session-catalog-parsing-
|
|
2
|
-
import "./session-catalog-limits-
|
|
1
|
+
import { A as unwrapNodeInvokePayload, n as CODEX_APP_SERVER_THREADS_LIST_COMMAND, o as CatalogParamsError, u as NODE_INVOKE_TIMEOUT_MS, v as parseCatalogPage } from "./session-catalog-parsing-CnEH565l.mjs";
|
|
2
|
+
import "./session-catalog-limits-bz5ZvjtY.mjs";
|
|
3
3
|
import { i as withTimeout } from "./timeout-CXOfNoaX.mjs";
|
|
4
4
|
//#region extensions/codex/src/session-catalog-node-lookup.ts
|
|
5
5
|
async function lookupNodeCodexCatalogRecord(params) {
|
package/dist/.setup/{session-catalog-parsing-CPGaPYr-.mjs → session-catalog-parsing-CnEH565l.mjs}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./protocol-CANUwXJ3.mjs";
|
|
2
|
-
import { n as detachCodexCatalogString } from "./session-catalog-limits-
|
|
2
|
+
import { n as detachCodexCatalogString } from "./session-catalog-limits-bz5ZvjtY.mjs";
|
|
3
3
|
import { asFiniteNumber, isRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
4
4
|
import { truncateUtf16Safe } from "openclaw/plugin-sdk/text-utility-runtime";
|
|
5
5
|
//#region extensions/codex/src/app-server/protocol-session-source.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { D as selectCodexCatalogPreviewInput, O as toCatalogSession, S as readControlCursor, d as boundedCatalogString, k as truncateCodexCatalogPreview } from "./session-catalog-parsing-
|
|
2
|
-
import { n as detachCodexCatalogString } from "./session-catalog-limits-
|
|
3
|
-
import { n as codexCatalogRowRecency } from "./session-catalog-index-order-
|
|
1
|
+
import { D as selectCodexCatalogPreviewInput, O as toCatalogSession, S as readControlCursor, d as boundedCatalogString, k as truncateCodexCatalogPreview } from "./session-catalog-parsing-CnEH565l.mjs";
|
|
2
|
+
import { n as detachCodexCatalogString } from "./session-catalog-limits-bz5ZvjtY.mjs";
|
|
3
|
+
import { n as codexCatalogRowRecency } from "./session-catalog-index-order-DQhmgM3b.mjs";
|
|
4
4
|
import { t as isOpenClawManagedCodexThread } from "./session-catalog-provenance-DoAvktcj.mjs";
|
|
5
|
-
import { c as copyCodexCatalogSource, l as getCodexCatalogSource, p as setCodexCatalogSource, r as projectCodexCatalogNativeThread } from "./session-catalog-native-projection-
|
|
5
|
+
import { c as copyCodexCatalogSource, l as getCodexCatalogSource, p as setCodexCatalogSource, r as projectCodexCatalogNativeThread } from "./session-catalog-native-projection-CXTe4qQr.mjs";
|
|
6
6
|
import { asFiniteNumber, isRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
7
7
|
import path from "node:path";
|
|
8
8
|
import fs from "node:fs/promises";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "./session-catalog-parsing-
|
|
2
|
-
import "./session-catalog-
|
|
1
|
+
import "./session-catalog-parsing-CnEH565l.mjs";
|
|
2
|
+
import "./session-catalog-DMagZcW-.mjs";
|
|
3
3
|
import { isRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
4
4
|
import { normalizeAgentId } from "openclaw/plugin-sdk/routing";
|
|
5
5
|
import { truncateUtf16Safe } from "openclaw/plugin-sdk/text-utility-runtime";
|
package/dist/.setup/{session-history-import-WhX-X33a.mjs → session-history-import-tquj9DCz.mjs}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { v as sessionBindingIdentity } from "./session-binding-record-
|
|
2
|
-
import "./session-binding-
|
|
3
|
-
import { r as importCodexThreadHistoryToTranscript } from "./transcript-mirror-
|
|
4
|
-
import { n as prepareCodexSessionInitialization } from "./session-initialization-
|
|
1
|
+
import { v as sessionBindingIdentity } from "./session-binding-record-CUKpUKVm.mjs";
|
|
2
|
+
import "./session-binding-Fn7Ekzuv.mjs";
|
|
3
|
+
import { r as importCodexThreadHistoryToTranscript } from "./transcript-mirror-BRNhyb1o.mjs";
|
|
4
|
+
import { n as prepareCodexSessionInitialization } from "./session-initialization-DefAI1_5.mjs";
|
|
5
5
|
import { resolveStorePath } from "openclaw/plugin-sdk/session-store-runtime";
|
|
6
6
|
//#region extensions/codex/src/app-server/session-history-import.ts
|
|
7
7
|
/** Creates a session whose transcript is derived from one verified Codex thread snapshot. */
|
package/dist/.setup/{session-initialization-6aveB9qb.mjs → session-initialization-DefAI1_5.mjs}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { b as validateBindingForWrite } from "./session-binding-record-
|
|
2
|
-
import "./session-binding-
|
|
1
|
+
import { b as validateBindingForWrite } from "./session-binding-record-CUKpUKVm.mjs";
|
|
2
|
+
import "./session-binding-Fn7Ekzuv.mjs";
|
|
3
3
|
import { createNativeSessionInitializationOwner } from "openclaw/plugin-sdk/agent-harness-session-runtime";
|
|
4
4
|
//#region extensions/codex/src/app-server/session-initialization.ts
|
|
5
5
|
const codexInitializations = createNativeSessionInitializationOwner({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { E as selectGuardianSandbox, _ as selectUserApprovalsReviewer, d as parseAllowedApprovalPoliciesFromCodexRequirements, f as parseAllowedApprovalsReviewersFromCodexRequirements, g as selectGuardianApprovalsReviewer, h as selectGuardianApprovalPolicy, i as resolveCodexAppServerNetworkProxy, p as parseAllowedSandboxModesFromCodexRequirements } from "./config-security-CE-FcGw9.mjs";
|
|
2
|
-
import { n as canUseCodexModelBackedApprovalsReviewerForModel } from "./config-
|
|
2
|
+
import { n as canUseCodexModelBackedApprovalsReviewerForModel } from "./config-DqmrqI23.mjs";
|
|
3
3
|
import { hostname } from "node:os";
|
|
4
4
|
import { isPathInside } from "openclaw/plugin-sdk/file-access-runtime";
|
|
5
5
|
//#region extensions/codex/src/app-server/app-server-policy.ts
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { u as retainSharedCodexAppServerClientByInstanceId } from "./shared-client-lifecycle-BH_y_i8l.mjs";
|
|
2
2
|
import { t as withCodexAppServerThreadMutation } from "./thread-ownership-queue-Dp24d7-F.mjs";
|
|
3
3
|
import { t as isIncognitoSessionKey } from "./incognito-session-C5ve_-63.mjs";
|
|
4
|
-
import { K as releaseCodexAppServerLiveThread, R as hasCodexAppServerLiveThread, V as isCodexAppServerLiveThreadClaimed } from "./shared-client-
|
|
5
|
-
import { n as CODEX_APP_SERVER_UNSUBSCRIBE_TIMEOUT_MS, o as closeCodexStartupClientBestEffort, p as unsubscribeCodexThreadBestEffort, r as CodexAppServerUnsafeSubscriptionError } from "./attempt-client-cleanup-
|
|
6
|
-
import { t as codexNativeSubagentMonitorRuntime } from "./native-subagent-monitor-
|
|
7
|
-
import { t as isSameCodexAppServerThreadOwner } from "./thread-ownership-
|
|
8
|
-
import { t as getCodexSessionInitializationRollback } from "./session-initialization-
|
|
4
|
+
import { K as releaseCodexAppServerLiveThread, R as hasCodexAppServerLiveThread, V as isCodexAppServerLiveThreadClaimed } from "./shared-client-ZXKMsK6f.mjs";
|
|
5
|
+
import { n as CODEX_APP_SERVER_UNSUBSCRIBE_TIMEOUT_MS, o as closeCodexStartupClientBestEffort, p as unsubscribeCodexThreadBestEffort, r as CodexAppServerUnsafeSubscriptionError } from "./attempt-client-cleanup-BVtNsTOE.mjs";
|
|
6
|
+
import { t as codexNativeSubagentMonitorRuntime } from "./native-subagent-monitor-g-ZDkvCr.mjs";
|
|
7
|
+
import { t as isSameCodexAppServerThreadOwner } from "./thread-ownership-BT_SeSUp.mjs";
|
|
8
|
+
import { t as getCodexSessionInitializationRollback } from "./session-initialization-DefAI1_5.mjs";
|
|
9
9
|
//#region extensions/codex/src/app-server/session-retirement.ts
|
|
10
10
|
async function releaseSessionSubscription(client, binding, sessionKey, assertCurrent) {
|
|
11
11
|
assertCurrent?.();
|
package/dist/.setup/{settled-turn-finalizer-DlPT87wW.mjs → settled-turn-finalizer-w92T5Rbb.mjs}
RENAMED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { r as readMirrorIdentity, t as attachCodexMirrorIdentity } from "./upstream-prompt-provenance-fXkKbPVC.mjs";
|
|
2
2
|
import { a as fingerprintCodexMirrorSourceMessage, c as readCodexMirrorSourceFingerprint } from "./transcript-mirror-attestation-YSegaktH.mjs";
|
|
3
|
-
import { rt as resolveCodexAppServerPreparedAuthHandoff } from "./shared-client-
|
|
4
|
-
import { _ as assertCodexPassiveTurnItems } from "./client-
|
|
5
|
-
import { o as resolveCodexLocalRuntimeAttribution } from "./native-subagent-monitor-
|
|
6
|
-
import { t as codexTranscriptMirrorRuntime } from "./transcript-mirror-
|
|
7
|
-
import { runBoundedCodexAppServerTurn } from "./bounded-turn-
|
|
8
|
-
import { t as resolveCodexBoundedTurnIsolation } from "./bounded-turn-isolation-
|
|
9
|
-
import { a as createAttributedCodexAssistantMessage } from "./event-projector-assistant-message-
|
|
3
|
+
import { rt as resolveCodexAppServerPreparedAuthHandoff } from "./shared-client-ZXKMsK6f.mjs";
|
|
4
|
+
import { _ as assertCodexPassiveTurnItems } from "./client-DcTISXe3.mjs";
|
|
5
|
+
import { o as resolveCodexLocalRuntimeAttribution } from "./native-subagent-monitor-g-ZDkvCr.mjs";
|
|
6
|
+
import { t as codexTranscriptMirrorRuntime } from "./transcript-mirror-BRNhyb1o.mjs";
|
|
7
|
+
import { runBoundedCodexAppServerTurn } from "./bounded-turn-DBwLoFDR.mjs";
|
|
8
|
+
import { t as resolveCodexBoundedTurnIsolation } from "./bounded-turn-isolation-Ce-oOk-D.mjs";
|
|
9
|
+
import { a as createAttributedCodexAssistantMessage } from "./event-projector-assistant-message-DXDX94zH.mjs";
|
|
10
10
|
import { t as CodexSettledTurnContext } from "./settled-turn-context-D4yj4rxf.mjs";
|
|
11
11
|
import { isSilentReplyText } from "openclaw/plugin-sdk/reply-runtime";
|
|
12
12
|
//#region extensions/codex/src/app-server/settled-turn-finalizer.ts
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import { i as isJsonObject } from "./protocol-CANUwXJ3.mjs";
|
|
2
|
-
import { n as defineCodexBuildState, t as codexBuildSymbol } from "./build-state
|
|
2
|
+
import { n as defineCodexBuildState, t as codexBuildSymbol } from "./build-state-B3lvV1Op.mjs";
|
|
3
3
|
import { t as CODEX_APP_SERVER_AUTH_PROVIDER } from "./auth-profile-selection-DFu9e167.mjs";
|
|
4
4
|
import { n as isCodexAppServerProxyLaunch } from "./launch-args-DbFCehO7.mjs";
|
|
5
5
|
import { a as withEphemeralCodexAuthStore, i as withClearedEnvironmentVariables, n as resolveCodexAppServerLocalHomeDir, r as resolveCodexAppServerUserHomeDir, t as resolveCodexAppServerHomeDir } from "./auth-start-options-BPIPeEX8.mjs";
|
|
6
6
|
import { a as resolveCodexAppServerStartOptionsForAgent, d as readCodexEffectiveConfig, o as resolveCodexComputerUseConfig, t as codexAppServerStartOptionsKey, u as CODEX_SESSION_OVERRIDABLE_LAYER_TYPES } from "./config-options-CzyWLTJt.mjs";
|
|
7
|
-
import { d as resolveMacOSDesktopCodexBundledMarketplaceCandidates, f as resolveMacOSDesktopCodexComputerUseServiceAppCandidates, i as resolveManagedCodexNativeCommand, l as resolveFirstExistingMacOSDesktopCodexBundledMarketplacePath, r as resolveManagedCodexAppServerStartOptions, t as isManagedCodexDesktopCommand, u as resolveMacOSDesktopCodexAppPathCandidates } from "./managed-binary-
|
|
8
|
-
import { a as readCodexCliAuthFileApiKey, c as resolveCodexAppServerPreparedApiKeyCacheKey, d as waitForCodexDesktopGeneration, f as readCodexDesktopArtifactTreeFingerprint, i as fingerprintTokenAuthProfileCacheKey, n as CODEX_AUTH_JSON_FILENAME, o as readFirstNonEmptyEnv, r as fingerprintApiKeyAuthProfileCacheKey, s as resolveCodexAppServerFallbackApiKeyCacheKey, t as CODEX_APP_SERVER_API_KEY_ENV_VARS, u as isCodexDesktopGenerationCurrent } from "./auth-cache-key-
|
|
9
|
-
import { a as notifyDesktopGenerationDrainChecks, c as
|
|
10
|
-
import { n as resolveCodexAppServerSpawnEnv } from "./transport-stdio-
|
|
7
|
+
import { d as resolveMacOSDesktopCodexBundledMarketplaceCandidates, f as resolveMacOSDesktopCodexComputerUseServiceAppCandidates, i as resolveManagedCodexNativeCommand, l as resolveFirstExistingMacOSDesktopCodexBundledMarketplacePath, r as resolveManagedCodexAppServerStartOptions, t as isManagedCodexDesktopCommand, u as resolveMacOSDesktopCodexAppPathCandidates } from "./managed-binary-Ckgvm_4V.mjs";
|
|
8
|
+
import { a as readCodexCliAuthFileApiKey, c as resolveCodexAppServerPreparedApiKeyCacheKey, d as waitForCodexDesktopGeneration, f as readCodexDesktopArtifactTreeFingerprint, i as fingerprintTokenAuthProfileCacheKey, n as CODEX_AUTH_JSON_FILENAME, o as readFirstNonEmptyEnv, r as fingerprintApiKeyAuthProfileCacheKey, s as resolveCodexAppServerFallbackApiKeyCacheKey, t as CODEX_APP_SERVER_API_KEY_ENV_VARS, u as isCodexDesktopGenerationCurrent } from "./auth-cache-key-CskfconU.mjs";
|
|
9
|
+
import { a as notifyDesktopGenerationDrainChecks, c as releaseSharedClientEntry, d as retirePendingSharedClientEntryIfUnclaimed, f as retireSharedCodexAppServerClientIfCurrent, h as waitForUnclaimedSharedClientStartup, l as retainSharedClientEntry, n as getCurrentSharedClientEntry, o as ownCodexStartup, r as getSharedCodexAppServerClientState, s as refreshSharedClientIdleRetirement, t as createCodexAppServerStartupLifetime } from "./shared-client-lifecycle-BH_y_i8l.mjs";
|
|
10
|
+
import { n as resolveCodexAppServerSpawnEnv } from "./transport-stdio-DU8dIOCj.mjs";
|
|
11
11
|
import { n as CodexAppServerAuthProfileUnavailableError, r as formatCodexAuthProfileUnavailableMessage } from "./auth-profile-recovery-BREezV0L.mjs";
|
|
12
12
|
import { i as withTimeout } from "./timeout-CXOfNoaX.mjs";
|
|
13
13
|
import { n as readCodexSessionMeta } from "./session-catalog-provenance-DoAvktcj.mjs";
|
|
14
|
-
import { n as observeCodexCatalogClient } from "./session-catalog-events-
|
|
15
|
-
import { n as resolveCodexAppServerRuntimeOptions } from "./config-runtime-
|
|
14
|
+
import { n as observeCodexCatalogClient } from "./session-catalog-events-r59AxcQ4.mjs";
|
|
15
|
+
import { n as resolveCodexAppServerRuntimeOptions } from "./config-runtime-DDhvIeUC.mjs";
|
|
16
16
|
import { a as resolveCodexAppServerAuthProfileStore, i as resolveCodexAppServerAuthProfileIdForAgent, r as resolveCodexAppServerAuthProfileId, t as isCodexAppServerNativeAuthProfile } from "./auth-profile-B0okYl2D.mjs";
|
|
17
17
|
import { i as isCodexResponsesOAuthCredential, n as createCodexResponsesOAuth, o as resolveCodexResponsesOAuthProfileFingerprint, r as isCodexResponsesOAuth, t as CODEX_RESPONSES_OAUTH_PROVIDER } from "./responses-oauth-twnuTaAa.mjs";
|
|
18
|
-
import { f as isUnsupportedCodexAppServerVersionError, t as CodexAppServerClient } from "./client-
|
|
19
|
-
import { n as isCodexWebSocketOpenFailure } from "./transport-websocket-
|
|
20
|
-
import { t as __exportAll } from "./session-binding-sidecars-
|
|
18
|
+
import { f as isUnsupportedCodexAppServerVersionError, t as CodexAppServerClient } from "./client-DcTISXe3.mjs";
|
|
19
|
+
import { n as isCodexWebSocketOpenFailure } from "./transport-websocket-zu3jRPnu.mjs";
|
|
20
|
+
import { t as __exportAll } from "./session-binding-sidecars-BuEALwJY.mjs";
|
|
21
21
|
import { isRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
22
22
|
import { createHash, randomUUID } from "node:crypto";
|
|
23
23
|
import { isDeepStrictEqual } from "node:util";
|
|
@@ -1906,7 +1906,7 @@ async function readCodexClientSessionMeta(client, sessionsRoot, boundRolloutPath
|
|
|
1906
1906
|
return structuredClone(metadata);
|
|
1907
1907
|
}
|
|
1908
1908
|
/** Installs one auth-refresh handler and one rate-limit observer per physical client. */
|
|
1909
|
-
function ensureCodexAppServerClientRuntime(client, context) {
|
|
1909
|
+
function ensureCodexAppServerClientRuntime(client, context, onThreadOwnershipChange) {
|
|
1910
1910
|
const existing = configuredClients.get(client);
|
|
1911
1911
|
if (existing) {
|
|
1912
1912
|
if (existing.closed) return;
|
|
@@ -1918,6 +1918,7 @@ function ensureCodexAppServerClientRuntime(client, context) {
|
|
|
1918
1918
|
}
|
|
1919
1919
|
const runtime = {
|
|
1920
1920
|
context,
|
|
1921
|
+
onThreadOwnershipChange,
|
|
1921
1922
|
closed: false,
|
|
1922
1923
|
retainedThreads: /* @__PURE__ */ new Map(),
|
|
1923
1924
|
claimedThreads: /* @__PURE__ */ new Map(),
|
|
@@ -1989,17 +1990,16 @@ function ensureCodexAppServerClientRuntime(client, context) {
|
|
|
1989
1990
|
invalidateThreadOwnership(runtime, threadId);
|
|
1990
1991
|
runtime.sessionMetadata.delete(threadId);
|
|
1991
1992
|
runtime.workspaceReferences.delete(threadId);
|
|
1992
|
-
|
|
1993
|
+
updateThreadOwnership(client, runtime);
|
|
1993
1994
|
}
|
|
1994
1995
|
}
|
|
1995
1996
|
});
|
|
1996
1997
|
}
|
|
1997
|
-
function
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
runtime.evictionTimer = void 0;
|
|
2001
|
-
}
|
|
1998
|
+
function updateThreadOwnership(client, runtime) {
|
|
1999
|
+
clearTimeout(runtime.evictionTimer);
|
|
2000
|
+
runtime.evictionTimer = void 0;
|
|
2002
2001
|
if (runtime.closed) return;
|
|
2002
|
+
runtime.onThreadOwnershipChange?.();
|
|
2003
2003
|
let expiresAt = Number.POSITIVE_INFINITY;
|
|
2004
2004
|
for (const [threadId, thread] of runtime.retainedThreads) if (!runtime.protectedThreads.has(threadId)) expiresAt = Math.min(expiresAt, thread.expiresAt);
|
|
2005
2005
|
if (!Number.isFinite(expiresAt)) return;
|
|
@@ -2026,7 +2026,6 @@ async function releaseRetainedThread(client, runtime, threadId, assertCurrent) {
|
|
|
2026
2026
|
olderThreadIds.add(candidateThreadId);
|
|
2027
2027
|
}
|
|
2028
2028
|
runtime.retainedThreads.delete(threadId);
|
|
2029
|
-
scheduleRetainedThreadEviction(client, runtime);
|
|
2030
2029
|
const transition = {
|
|
2031
2030
|
retainedOwnerToken: retained.ownerToken,
|
|
2032
2031
|
completion: Promise.resolve().then(() => {
|
|
@@ -2035,6 +2034,7 @@ async function releaseRetainedThread(client, runtime, threadId, assertCurrent) {
|
|
|
2035
2034
|
})
|
|
2036
2035
|
};
|
|
2037
2036
|
runtime.releasingThreads.set(threadId, transition);
|
|
2037
|
+
updateThreadOwnership(client, runtime);
|
|
2038
2038
|
try {
|
|
2039
2039
|
await transition.completion;
|
|
2040
2040
|
runtime.workspaceReferences.delete(threadId);
|
|
@@ -2051,13 +2051,13 @@ async function releaseRetainedThread(client, runtime, threadId, assertCurrent) {
|
|
|
2051
2051
|
throw error;
|
|
2052
2052
|
} finally {
|
|
2053
2053
|
if (runtime.releasingThreads.get(threadId) === transition) runtime.releasingThreads.delete(threadId);
|
|
2054
|
-
|
|
2054
|
+
updateThreadOwnership(client, runtime);
|
|
2055
2055
|
}
|
|
2056
2056
|
}
|
|
2057
2057
|
async function evictExpiredRetainedThreads(client, runtime) {
|
|
2058
2058
|
const now = Date.now();
|
|
2059
2059
|
for (const [threadId, thread] of runtime.retainedThreads) if (thread.expiresAt <= now && !runtime.protectedThreads.has(threadId)) await releaseRetainedThread(client, runtime, threadId);
|
|
2060
|
-
|
|
2060
|
+
updateThreadOwnership(client, runtime);
|
|
2061
2061
|
}
|
|
2062
2062
|
async function evictExcessIdleThreads(client, runtime) {
|
|
2063
2063
|
const idleThreads = () => [...runtime.retainedThreads].filter(([threadId, thread]) => thread.ephemeralPolicy === void 0 && !runtime.protectedThreads.has(threadId));
|
|
@@ -2098,7 +2098,7 @@ async function retainCodexAppServerLiveThread(client, threadId, releaseThread, c
|
|
|
2098
2098
|
await evictExcessIdleThreads(client, runtime);
|
|
2099
2099
|
} catch (error) {
|
|
2100
2100
|
if (runtime.retainedThreads.get(threadId) === retained) runtime.retainedThreads.delete(threadId);
|
|
2101
|
-
|
|
2101
|
+
updateThreadOwnership(client, runtime);
|
|
2102
2102
|
embeddedAgentLog$1.warn("codex retained thread capacity eviction failed", {
|
|
2103
2103
|
threadId,
|
|
2104
2104
|
reason: formatErrorMessage$1(error)
|
|
@@ -2107,7 +2107,7 @@ async function retainCodexAppServerLiveThread(client, threadId, releaseThread, c
|
|
|
2107
2107
|
}
|
|
2108
2108
|
if (runtime.closed) return false;
|
|
2109
2109
|
if (claimed !== void 0 && runtime.claimedThreads.get(threadId) === claimed) runtime.claimedThreads.delete(threadId);
|
|
2110
|
-
|
|
2110
|
+
updateThreadOwnership(client, runtime);
|
|
2111
2111
|
return true;
|
|
2112
2112
|
}
|
|
2113
2113
|
/** Transfer one idle subscription to its next turn or compaction without touching sibling threads. */
|
|
@@ -2146,7 +2146,7 @@ function claimCodexAppServerThreadOwnership(client, runtime, threadId, retained,
|
|
|
2146
2146
|
runtime.claimedThreads.set(threadId, claimed);
|
|
2147
2147
|
previousClaim?.invalidate();
|
|
2148
2148
|
retained.ownerToken?.invalidate();
|
|
2149
|
-
|
|
2149
|
+
updateThreadOwnership(client, runtime);
|
|
2150
2150
|
const assertCurrent = () => {
|
|
2151
2151
|
if (claimed.invalidated || runtime.closed || runtime.claimedThreads.get(threadId) !== claimed) throw new Error(`Codex thread subscription ownership changed: ${threadId}`);
|
|
2152
2152
|
};
|
|
@@ -2187,6 +2187,7 @@ function claimCodexAppServerThreadOwnership(client, runtime, threadId, retained,
|
|
|
2187
2187
|
}
|
|
2188
2188
|
} finally {
|
|
2189
2189
|
if (runtime.releasingThreads.get(threadId) === transition) runtime.releasingThreads.delete(threadId);
|
|
2190
|
+
updateThreadOwnership(client, runtime);
|
|
2190
2191
|
}
|
|
2191
2192
|
};
|
|
2192
2193
|
physicalThreadReleases.set(release, retained.release);
|
|
@@ -2200,7 +2201,7 @@ function claimCodexAppServerThreadOwnership(client, runtime, threadId, retained,
|
|
|
2200
2201
|
forget: () => {
|
|
2201
2202
|
if (forgetThreadOwnership(runtime, threadId, claimed)) {
|
|
2202
2203
|
runtime.workspaceReferences.delete(threadId);
|
|
2203
|
-
|
|
2204
|
+
updateThreadOwnership(client, runtime);
|
|
2204
2205
|
}
|
|
2205
2206
|
}
|
|
2206
2207
|
};
|
|
@@ -2210,6 +2211,11 @@ function revertCodexAppServerLiveThreadSkillsCatalog(client, threadId) {
|
|
|
2210
2211
|
const runtime = configuredClients.get(client);
|
|
2211
2212
|
if (runtime && !runtime.closed) revertRetainedThreadSkillsCatalog(runtime, threadId);
|
|
2212
2213
|
}
|
|
2214
|
+
/** Native subscriptions, including ephemeral history and releases, pin their physical client. */
|
|
2215
|
+
function hasCodexAppServerThreadOwnership(client) {
|
|
2216
|
+
const runtime = configuredClients.get(client);
|
|
2217
|
+
return Boolean(runtime && !runtime.closed && (runtime.retainedThreads.size > 0 || runtime.claimedThreads.size > 0 || runtime.releasingThreads.size > 0 || runtime.protectedThreads.size > 0));
|
|
2218
|
+
}
|
|
2213
2219
|
/** Distinguish active claimed ownership from an already-evicted idle subscription. */
|
|
2214
2220
|
function hasCodexAppServerLiveThread(client, threadId) {
|
|
2215
2221
|
return hasThreadOwnership(configuredClients.get(client), threadId);
|
|
@@ -2253,20 +2259,24 @@ async function unsubscribeCodexAppServerLiveThread(client, threadId, timeoutMs,
|
|
|
2253
2259
|
physicalRelease
|
|
2254
2260
|
};
|
|
2255
2261
|
runtime.releasingThreads.set(threadId, transition);
|
|
2262
|
+
updateThreadOwnership(client, runtime);
|
|
2256
2263
|
}
|
|
2257
2264
|
try {
|
|
2258
2265
|
await physicalRelease;
|
|
2259
2266
|
if (retained !== void 0 && runtime?.retainedThreads.get(threadId) === retained) {
|
|
2260
2267
|
runtime.retainedThreads.delete(threadId);
|
|
2261
2268
|
retained.ownerToken?.invalidate();
|
|
2262
|
-
|
|
2269
|
+
updateThreadOwnership(client, runtime);
|
|
2263
2270
|
}
|
|
2264
2271
|
if (claimed !== void 0 && runtime?.claimedThreads.get(threadId) === claimed) {
|
|
2265
2272
|
runtime.claimedThreads.delete(threadId);
|
|
2266
2273
|
claimed.invalidate();
|
|
2267
2274
|
}
|
|
2268
2275
|
} finally {
|
|
2269
|
-
if (ownsTransition && runtime.releasingThreads.get(threadId) === transition)
|
|
2276
|
+
if (ownsTransition && runtime.releasingThreads.get(threadId) === transition) {
|
|
2277
|
+
runtime.releasingThreads.delete(threadId);
|
|
2278
|
+
updateThreadOwnership(client, runtime);
|
|
2279
|
+
}
|
|
2270
2280
|
}
|
|
2271
2281
|
}
|
|
2272
2282
|
/** Reset/end owns the exact thread; failed generation retirement must never release its successor. */
|
|
@@ -2279,7 +2289,7 @@ function protectCodexAppServerLiveThread(client, threadId) {
|
|
|
2279
2289
|
const runtime = configuredClients.get(client);
|
|
2280
2290
|
if (!runtime || runtime.closed) return () => void 0;
|
|
2281
2291
|
runtime.protectedThreads.set(threadId, (runtime.protectedThreads.get(threadId) ?? 0) + 1);
|
|
2282
|
-
|
|
2292
|
+
updateThreadOwnership(client, runtime);
|
|
2283
2293
|
let protectedThread = true;
|
|
2284
2294
|
return () => {
|
|
2285
2295
|
if (!protectedThread) return;
|
|
@@ -2295,7 +2305,7 @@ function protectCodexAppServerLiveThread(client, threadId) {
|
|
|
2295
2305
|
runtime.retainedThreads.set(threadId, retained);
|
|
2296
2306
|
}
|
|
2297
2307
|
} else runtime.protectedThreads.set(threadId, count - 1);
|
|
2298
|
-
|
|
2308
|
+
updateThreadOwnership(client, runtime);
|
|
2299
2309
|
evictExcessIdleThreads(client, runtime).catch((error) => {
|
|
2300
2310
|
embeddedAgentLog$1.warn("codex retained thread unpin eviction failed", {
|
|
2301
2311
|
threadId,
|
|
@@ -2558,7 +2568,7 @@ async function prepareCodexInferenceRoute(params) {
|
|
|
2558
2568
|
}
|
|
2559
2569
|
pending = Promise.all([
|
|
2560
2570
|
import("./inference-proxy-DhcXOgUE.mjs"),
|
|
2561
|
-
import("./native-subagent-monitor-
|
|
2571
|
+
import("./native-subagent-monitor-g-ZDkvCr.mjs").then((n) => n.n),
|
|
2562
2572
|
import("./inference-dispatch-CMZtjQyz.mjs")
|
|
2563
2573
|
]).then(([{ createCodexInferenceProxy }, native, { createCodexInferenceModelBinding }]) => {
|
|
2564
2574
|
assertClient();
|
|
@@ -3245,7 +3255,10 @@ function createSharedCodexAppServerClientStartup(params) {
|
|
|
3245
3255
|
}).then((client) => {
|
|
3246
3256
|
const state = getSharedCodexAppServerClientState();
|
|
3247
3257
|
params.entry.client = client;
|
|
3258
|
+
params.entry.hasOwnedThreads = () => hasCodexAppServerThreadOwnership(client);
|
|
3248
3259
|
client.addCloseHandler((closedClient) => {
|
|
3260
|
+
clearTimeout(params.entry.idleTimer);
|
|
3261
|
+
params.entry.idleTimer = void 0;
|
|
3249
3262
|
const entry = getCurrentSharedClientEntry(closedClient);
|
|
3250
3263
|
if (entry) state.clients.delete(entry.key);
|
|
3251
3264
|
});
|
|
@@ -3349,7 +3362,7 @@ async function startInitializedCodexAppServerClientOnce(params) {
|
|
|
3349
3362
|
} finally {
|
|
3350
3363
|
artifactDrain?.cancel();
|
|
3351
3364
|
}
|
|
3352
|
-
const runtimeArtifactModule = params.runtimeArtifactMode ? await import("./runtime-artifact-
|
|
3365
|
+
const runtimeArtifactModule = params.runtimeArtifactMode ? await import("./runtime-artifact-Riq878B2.mjs") : void 0;
|
|
3353
3366
|
const runtimeArtifactBeforeStart = runtimeArtifactModule ? await runtimeArtifactModule.captureCodexAppServerRuntimeArtifactBeforeStart({
|
|
3354
3367
|
startOptions,
|
|
3355
3368
|
spawnIdentity: resolveCodexAppServerSpawnIdentity(startOptions),
|
|
@@ -3420,7 +3433,7 @@ async function startInitializedCodexAppServerClientOnce(params) {
|
|
|
3420
3433
|
...params.authProfileStore ? { authProfileStore: params.authProfileStore } : {},
|
|
3421
3434
|
config: params.config,
|
|
3422
3435
|
onAuthRefreshFailure: () => retireSharedCodexAppServerClientIfCurrent(client)
|
|
3423
|
-
});
|
|
3436
|
+
}, () => refreshSharedClientIdleRetirement(client));
|
|
3424
3437
|
assertStartupCurrent();
|
|
3425
3438
|
const authHandoff = await waitForStartup(() => applyCodexAppServerAuthProfile({
|
|
3426
3439
|
client,
|
package/dist/.setup/{shared-client-lifecycle-CJ0lYVCW.mjs → shared-client-lifecycle-BH_y_i8l.mjs}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as defineCodexBuildState } from "./build-state
|
|
1
|
+
import { n as defineCodexBuildState } from "./build-state-B3lvV1Op.mjs";
|
|
2
2
|
//#region extensions/codex/src/app-server/shared-client-lifecycle.ts
|
|
3
3
|
/** Client ownership and synchronous retirement, independent of startup/auth execution. */
|
|
4
4
|
const createCodexAppServerStartupLifetime = () => ({
|
|
@@ -50,6 +50,7 @@ function retireSharedCodexAppServerClientIfCurrent(client, opts) {
|
|
|
50
50
|
const currentEntry = getCurrentSharedClientEntry(client);
|
|
51
51
|
const entry = currentEntry ?? state.entriesByClient.get(client);
|
|
52
52
|
if (!entry || entry.client !== client && !entry.closeError) return;
|
|
53
|
+
cancelSharedClientIdleRetirement(entry);
|
|
53
54
|
if (currentEntry) {
|
|
54
55
|
state.clients.delete(entry.key);
|
|
55
56
|
entry.closeWhenIdle = true;
|
|
@@ -84,6 +85,7 @@ function closeRetiredSharedClientEntry(entry) {
|
|
|
84
85
|
const client = entry.client;
|
|
85
86
|
if (!client) return false;
|
|
86
87
|
entry.client = void 0;
|
|
88
|
+
cancelSharedClientIdleRetirement(entry);
|
|
87
89
|
client.close();
|
|
88
90
|
return true;
|
|
89
91
|
}
|
|
@@ -135,8 +137,27 @@ async function retainSharedCodexAppServerClientByInstanceId(clientId) {
|
|
|
135
137
|
function notifyDesktopGenerationDrainChecks(state) {
|
|
136
138
|
for (const check of state.desktopGenerationDrainChecks) check();
|
|
137
139
|
}
|
|
140
|
+
const CODEX_APP_SERVER_CLIENT_IDLE_GRACE_MS = 3e4;
|
|
141
|
+
function cancelSharedClientIdleRetirement(entry) {
|
|
142
|
+
clearTimeout(entry.idleTimer);
|
|
143
|
+
entry.idleTimer = void 0;
|
|
144
|
+
}
|
|
145
|
+
function refreshSharedClientIdleRetirement(client) {
|
|
146
|
+
const entry = getCurrentSharedClientEntry(client);
|
|
147
|
+
if (entry) scheduleSharedClientIdleRetirement(entry);
|
|
148
|
+
}
|
|
149
|
+
function scheduleSharedClientIdleRetirement(entry) {
|
|
150
|
+
cancelSharedClientIdleRetirement(entry);
|
|
151
|
+
if (entry.activeLeases > 0 || entry.pendingAcquires > 0 || !entry.client || entry.hasOwnedThreads?.() || getCurrentSharedClientEntry(entry.client) !== entry) return;
|
|
152
|
+
entry.idleTimer = setTimeout(() => {
|
|
153
|
+
entry.idleTimer = void 0;
|
|
154
|
+
if (entry.activeLeases === 0 && entry.pendingAcquires === 0 && !entry.hasOwnedThreads?.()) retireSharedCodexAppServerClientIfCurrent(entry.client);
|
|
155
|
+
}, CODEX_APP_SERVER_CLIENT_IDLE_GRACE_MS);
|
|
156
|
+
entry.idleTimer.unref?.();
|
|
157
|
+
}
|
|
138
158
|
function retainSharedClientEntry(entry, counter = "activeLeases") {
|
|
139
159
|
let released = false;
|
|
160
|
+
cancelSharedClientIdleRetirement(entry);
|
|
140
161
|
entry[counter] += 1;
|
|
141
162
|
return () => {
|
|
142
163
|
if (released) return;
|
|
@@ -147,7 +168,8 @@ function retainSharedClientEntry(entry, counter = "activeLeases") {
|
|
|
147
168
|
function releaseSharedClientEntry(entry, counter) {
|
|
148
169
|
entry[counter] -= 1;
|
|
149
170
|
closeRetiredSharedClientEntryIfIdle(entry);
|
|
171
|
+
scheduleSharedClientIdleRetirement(entry);
|
|
150
172
|
notifyDesktopGenerationDrainChecks(getSharedCodexAppServerClientState());
|
|
151
173
|
}
|
|
152
174
|
//#endregion
|
|
153
|
-
export { notifyDesktopGenerationDrainChecks as a,
|
|
175
|
+
export { notifyDesktopGenerationDrainChecks as a, releaseSharedClientEntry as c, retirePendingSharedClientEntryIfUnclaimed as d, retireSharedCodexAppServerClientIfCurrent as f, waitForUnclaimedSharedClientStartup as h, hasActiveSharedCodexAppServerWork as i, retainSharedClientEntry as l, waitForCodexAppServerClientExit as m, getCurrentSharedClientEntry as n, ownCodexStartup as o, retireSharedCodexAppServerClientsBeforeDesktopGeneration as p, getSharedCodexAppServerClientState as r, refreshSharedClientIdleRetirement as s, createCodexAppServerStartupLifetime as t, retainSharedCodexAppServerClientByInstanceId as u };
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import { i as isJsonObject } from "./protocol-CANUwXJ3.mjs";
|
|
2
|
-
import { v as sessionBindingIdentity } from "./session-binding-record-
|
|
2
|
+
import { v as sessionBindingIdentity } from "./session-binding-record-CUKpUKVm.mjs";
|
|
3
3
|
import { c as shouldAutoApproveCodexAppServerApprovals, l as withMcpElicitationsApprovalPolicy, m as readCodexRequirementsToml, n as hasCodexMcpToolApprovalOverrides } from "./config-security-CE-FcGw9.mjs";
|
|
4
4
|
import { c as isCodexPairedNodeRemoteExecPlacementSandbox, d as readCodexPluginConfig, l as isCodexRemoteExecPlacementSandbox, u as isCodexSandboxExecServerEnabled } from "./config-parsing-b088LyhT.mjs";
|
|
5
5
|
import { i as resolveCodexAppServerHomeScope, l as resolveCodexModelBackedReviewerPolicyContext } from "./config-options-CzyWLTJt.mjs";
|
|
6
6
|
import { n as formatCodexUsageLimitErrorMessage } from "./rate-limits-B7-X2TgG.mjs";
|
|
7
|
-
import { i as resolveCodexBindingAppServerConnection, r as requireCodexSupervisionModelSelection } from "./binding-connection-
|
|
8
|
-
import { n as canUseCodexModelBackedApprovalsReviewerForModel, r as resolveOpenClawExecPolicyForCodexAppServer } from "./config-
|
|
9
|
-
import { Z as readRecentCodexRateLimits, b as withLeasedCodexAppServerClientStartSelectionRetry, c as getLeasedSharedCodexAppServerClient, m as releaseCodexAppServerClientLease, rt as resolveCodexAppServerPreparedAuthHandoff } from "./shared-client-
|
|
10
|
-
import { A as handleDynamicToolCallWithTimeout, B as resolveCodexToolAbortTerminalReason, P as resolveDynamicToolCallTimeoutMs, S as assertCodexTurnStartResponse, i as isCodexAppServerApprovalRequest, k as createCodexElicitationResponse, s as isCodexAppServerIndeterminateRequestCancellationError, w as readCodexDynamicToolCallParams, y as assertCodexThreadForkResponse, z as toCodexDynamicToolProtocolResponse } from "./client-
|
|
11
|
-
import { f as terminateCodexBackgroundTerminals, p as unsubscribeCodexThreadBestEffort, s as interruptCodexTurnAndWaitBestEffort, u as retireUnsafeCodexTurnClientBestEffort } from "./attempt-client-cleanup-
|
|
12
|
-
import { t as CodexEphemeralTurn } from "./ephemeral-turn-
|
|
13
|
-
import { Ct as refreshCodexPluginAppApprovalPolicy, D as buildCodexNativeHookRelayConfig, M as resolveCodexNativeHookRelayEvents, N as resolveCodexNativeHookRelayTtlMs, O as buildCodexNativeHookRelayDisabledConfig, St as mergeCodexThreadConfigs, ft as resolveCodexDynamicToolsLoading, g as CODEX_NATIVE_PERSONALITY_NONE, p as resolveCodexWebSearchPlan, r as buildCodexRuntimeThreadConfig, y as resolveCodexAppServerThreadModelSelection } from "./thread-requests-
|
|
14
|
-
import { S as resolveCodexAppServerReasoningEffort, o as buildCodexUserInput, r as buildCodexTemporalAdditionalContext, x as readCodexSupportedReasoningEfforts } from "./thread-lifecycle-
|
|
15
|
-
import { o as resolveCodexSessionBinding } from "./session-binding-
|
|
16
|
-
import { a as refreshCodexThreadPolicy, i as assertCodexSupervisionThreadLineage, n as CodexThreadPolicyHandoffError } from "./thread-policy-
|
|
17
|
-
import { t as resolveCodexNativeExecutionBlock } from "./sandbox-guard-
|
|
18
|
-
import { E as CodexNativeToolLifecycleProjector, a as emitDynamicToolStartedDiagnostic, b as createCodexNativePreToolUseFailureBuffer, c as buildDynamicTools, f as resolveCodexExternalSandboxPolicyForOpenClawSandbox, g as shouldRequireCodexSandboxExecServerEnvironment, h as shouldEnableCodexAppServerNativeToolSurface, i as emitDynamicToolErrorDiagnostic, m as resolveCodexSandboxEnvironmentSelection, o as emitDynamicToolTerminalDiagnostic, p as resolveCodexMessageToolProvider, r as routeCodexAppServerElicitationRequest, s as handleCodexAppServerApprovalRequest, t as createCodexDynamicToolBridge, v as ensureCodexSandboxExecServerEnvironment, y as releaseCodexSandboxExecServerEnvironment } from "./dynamic-tools-
|
|
19
|
-
import { a as resolveCodexAppServerForModelProvider, i as resolveCodexSessionPermissionCwd, n as applyCodexSessionPermissionPolicy, r as resolveCodexEffectiveSessionPermissionPolicy, t as CODEX_SESSION_PERMISSION_EXEC_MODES } from "./session-permission-policy-
|
|
20
|
-
import { n as resolveCodexProviderWebSearchSupportForClient } from "./provider-capabilities-
|
|
7
|
+
import { i as resolveCodexBindingAppServerConnection, r as requireCodexSupervisionModelSelection } from "./binding-connection-DRPlnIgg.mjs";
|
|
8
|
+
import { n as canUseCodexModelBackedApprovalsReviewerForModel, r as resolveOpenClawExecPolicyForCodexAppServer } from "./config-DqmrqI23.mjs";
|
|
9
|
+
import { Z as readRecentCodexRateLimits, b as withLeasedCodexAppServerClientStartSelectionRetry, c as getLeasedSharedCodexAppServerClient, m as releaseCodexAppServerClientLease, rt as resolveCodexAppServerPreparedAuthHandoff } from "./shared-client-ZXKMsK6f.mjs";
|
|
10
|
+
import { A as handleDynamicToolCallWithTimeout, B as resolveCodexToolAbortTerminalReason, P as resolveDynamicToolCallTimeoutMs, S as assertCodexTurnStartResponse, i as isCodexAppServerApprovalRequest, k as createCodexElicitationResponse, s as isCodexAppServerIndeterminateRequestCancellationError, w as readCodexDynamicToolCallParams, y as assertCodexThreadForkResponse, z as toCodexDynamicToolProtocolResponse } from "./client-DcTISXe3.mjs";
|
|
11
|
+
import { f as terminateCodexBackgroundTerminals, p as unsubscribeCodexThreadBestEffort, s as interruptCodexTurnAndWaitBestEffort, u as retireUnsafeCodexTurnClientBestEffort } from "./attempt-client-cleanup-BVtNsTOE.mjs";
|
|
12
|
+
import { t as CodexEphemeralTurn } from "./ephemeral-turn-Dj3iTfSP.mjs";
|
|
13
|
+
import { Ct as refreshCodexPluginAppApprovalPolicy, D as buildCodexNativeHookRelayConfig, M as resolveCodexNativeHookRelayEvents, N as resolveCodexNativeHookRelayTtlMs, O as buildCodexNativeHookRelayDisabledConfig, St as mergeCodexThreadConfigs, ft as resolveCodexDynamicToolsLoading, g as CODEX_NATIVE_PERSONALITY_NONE, p as resolveCodexWebSearchPlan, r as buildCodexRuntimeThreadConfig, y as resolveCodexAppServerThreadModelSelection } from "./thread-requests-y_MnVuWC.mjs";
|
|
14
|
+
import { S as resolveCodexAppServerReasoningEffort, o as buildCodexUserInput, r as buildCodexTemporalAdditionalContext, x as readCodexSupportedReasoningEfforts } from "./thread-lifecycle-CzzYMvTL.mjs";
|
|
15
|
+
import { o as resolveCodexSessionBinding } from "./session-binding-Fn7Ekzuv.mjs";
|
|
16
|
+
import { a as refreshCodexThreadPolicy, i as assertCodexSupervisionThreadLineage, n as CodexThreadPolicyHandoffError } from "./thread-policy-MM5YD22L.mjs";
|
|
17
|
+
import { t as resolveCodexNativeExecutionBlock } from "./sandbox-guard-OIYEmTRF.mjs";
|
|
18
|
+
import { E as CodexNativeToolLifecycleProjector, a as emitDynamicToolStartedDiagnostic, b as createCodexNativePreToolUseFailureBuffer, c as buildDynamicTools, f as resolveCodexExternalSandboxPolicyForOpenClawSandbox, g as shouldRequireCodexSandboxExecServerEnvironment, h as shouldEnableCodexAppServerNativeToolSurface, i as emitDynamicToolErrorDiagnostic, m as resolveCodexSandboxEnvironmentSelection, o as emitDynamicToolTerminalDiagnostic, p as resolveCodexMessageToolProvider, r as routeCodexAppServerElicitationRequest, s as handleCodexAppServerApprovalRequest, t as createCodexDynamicToolBridge, v as ensureCodexSandboxExecServerEnvironment, y as releaseCodexSandboxExecServerEnvironment } from "./dynamic-tools-Dr0ye5P3.mjs";
|
|
19
|
+
import { a as resolveCodexAppServerForModelProvider, i as resolveCodexSessionPermissionCwd, n as applyCodexSessionPermissionPolicy, r as resolveCodexEffectiveSessionPermissionPolicy, t as CODEX_SESSION_PERMISSION_EXEC_MODES } from "./session-permission-policy-7lM447LW.mjs";
|
|
20
|
+
import { n as resolveCodexProviderWebSearchSupportForClient } from "./provider-capabilities-DBs9l8oL.mjs";
|
|
21
21
|
import { readStringField } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
22
22
|
import { randomUUID } from "node:crypto";
|
|
23
23
|
import { isDeepStrictEqual } from "node:util";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { a as marketplaceRef, n as isOpenAiCuratedMarketplace, o as pluginReadParams, u as CODEX_PLUGINS_MARKETPLACE_NAME } from "./plugin-inventory-
|
|
1
|
+
import { a as marketplaceRef, n as isOpenAiCuratedMarketplace, o as pluginReadParams, u as CODEX_PLUGINS_MARKETPLACE_NAME } from "./plugin-inventory-B4uqIw4J.mjs";
|
|
2
2
|
import { a as defaultCodexAppInventoryCache, r as buildCodexPluginAppCacheKey } from "./plugin-app-cache-key-BL9B5H0L.mjs";
|
|
3
|
-
import { o as withCodexAppServerJsonClient } from "./request-
|
|
4
|
-
import "./config-
|
|
5
|
-
import { t as __exportAll } from "./session-binding-sidecars-
|
|
3
|
+
import { o as withCodexAppServerJsonClient } from "./request-CWERwKIL.mjs";
|
|
4
|
+
import "./config-DqmrqI23.mjs";
|
|
5
|
+
import { t as __exportAll } from "./session-binding-sidecars-BuEALwJY.mjs";
|
|
6
6
|
import { asNonArrayRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
7
7
|
import path from "node:path";
|
|
8
8
|
import os from "node:os";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { i as isJsonObject, r as flattenCodexDynamicToolFunctions } from "./protocol-CANUwXJ3.mjs";
|
|
2
|
-
import { a as matchesPendingSupervisionBranch, n as assertCodexBindingMayBeReplaced, v as sessionBindingIdentity } from "./session-binding-record-
|
|
2
|
+
import { a as matchesPendingSupervisionBranch, n as assertCodexBindingMayBeReplaced, v as sessionBindingIdentity } from "./session-binding-record-CUKpUKVm.mjs";
|
|
3
3
|
import { u as stringifyCodexPolicy } from "./config-security-CE-FcGw9.mjs";
|
|
4
4
|
import { n as resolveCodexAppServerLocalHomeDir, t as resolveCodexAppServerHomeDir } from "./auth-start-options-BPIPeEX8.mjs";
|
|
5
5
|
import { d as readCodexEffectiveConfig, n as codexSandboxPolicyForTurn, s as assertCodexModelBackedReviewerEffectiveConfig, u as CODEX_SESSION_OVERRIDABLE_LAYER_TYPES } from "./config-options-CzyWLTJt.mjs";
|
|
6
6
|
import { i as markStartedCodexManagedThread } from "./managed-thread-store-BMqgThVL.mjs";
|
|
7
|
-
import {
|
|
7
|
+
import { n as getCurrentSharedClientEntry, u as retainSharedCodexAppServerClientByInstanceId } from "./shared-client-lifecycle-BH_y_i8l.mjs";
|
|
8
8
|
import { t as withCodexAppServerThreadMutation } from "./thread-ownership-queue-Dp24d7-F.mjs";
|
|
9
9
|
import { t as isIncognitoSessionKey } from "./incognito-session-C5ve_-63.mjs";
|
|
10
10
|
import { n as CodexAppServerRpcError, r as isCodexThreadReadMissingError } from "./rpc-error-BlD2vuzn.mjs";
|
|
@@ -13,20 +13,20 @@ import { r as withAbortableTimeout } from "./timeout-CXOfNoaX.mjs";
|
|
|
13
13
|
import { t as projectBoundedCodexThreadHistory } from "./transcript-history-projection-DRSifI-1.mjs";
|
|
14
14
|
import { t as buildCodexAppServerConnectionFingerprint } from "./plugin-app-cache-key-BL9B5H0L.mjs";
|
|
15
15
|
import { n as readCodexSessionMeta } from "./session-catalog-provenance-DoAvktcj.mjs";
|
|
16
|
-
import { t as assertCodexSessionRuntimeOwnership } from "./binding-connection-
|
|
17
|
-
import "./config-
|
|
16
|
+
import { t as assertCodexSessionRuntimeOwnership } from "./binding-connection-DRPlnIgg.mjs";
|
|
17
|
+
import "./config-DqmrqI23.mjs";
|
|
18
18
|
import { i as sanitizeInlineImageDataUrl, r as invalidInlineImageText } from "./session-history-read-Ov3StuL4.mjs";
|
|
19
19
|
import { c as resolveCodexContextEngineProjectionMaxChars, o as neutralizeCodexExplicitMentionSigils } from "./context-engine-projection-PezSESth.mjs";
|
|
20
20
|
import { n as normalizeCodexAppServerBindingModelProvider } from "./auth-profile-B0okYl2D.mjs";
|
|
21
|
-
import { $ as createCodexEphemeralThreadPolicy, A as bindCodexInferenceThread, B as isCodexAppServerClientRuntimeLive, C as CodexThreadBindingConflictError, F as consumeCodexAppServerLiveThread, H as isCodexAppServerLiveThreadProtected, K as releaseCodexAppServerLiveThread, M as getCodexInferenceThreadQualification, N as prepareCodexInferenceThreadConfig, S as CodexAdoptedThreadActiveError, T as CodexThreadStartRequestError, V as isCodexAppServerLiveThreadClaimed, Y as unsubscribeCodexAppServerLiveThread, et as wasCodexAppServerThreadClosed, j as getCodexInferenceThread, k as assertCodexInferenceRouteConfig, n as captureCodexAppServerClientLifetime, w as CodexThreadClientReplacementError, z as hasCodexAppServerSiblingThreadWork } from "./shared-client-
|
|
22
|
-
import { C as assertExactSupervisionModelSelection, D as readSupervisionResponseThreadId, O as resolveCodexThreadRolloutPath, d as isCodexAppServerRequestTimeoutError, l as isCodexAppServerOverloadError, p as resolveCodexAppServerClientInstanceId, r as getCodexAppServerClientInstanceId, v as assertCodexThreadAcceptsDirectInput, x as assertCodexThreadStartResponse, y as assertCodexThreadForkResponse } from "./client-
|
|
23
|
-
import { c as isCodexAppServerUnsafeSubscriptionError, g as hasCodexAppServerSiblingRouteWork, n as CODEX_APP_SERVER_UNSUBSCRIBE_TIMEOUT_MS, o as closeCodexStartupClientBestEffort, p as unsubscribeCodexThreadBestEffort, r as CodexAppServerUnsafeSubscriptionError, u as retireUnsafeCodexTurnClientBestEffort } from "./attempt-client-cleanup-
|
|
24
|
-
import { $ as readActiveCodexTurnIdsFromResume, B as loadCodexNativeToolCatalog, C as mergeCodexNativeProjectDocThreadConfig, E as assertCodexNativeHookRelayAllowed, F as attestCodexThreadToolSurface, G as areUserMcpServersFingerprintsCompatible, H as applyCodexNativeSkillIsolation, I as checkCodexThreadAppAvailability, J as fingerprintCodexThreadConfig, K as codexDynamicToolsFingerprint, L as discardUnattestedCodexPluginThread, Q as legacyFingerprintUserMcpServersConfigPatch, R as attestCodexRestrictedToolSurfaceMcpServersDisabled, St as mergeCodexThreadConfigs, T as CodexManagedHooksOnlyError, Tt as buildCodexAppApprovalOverrides, U as resolveCodexNativeSkillIsolation, W as areCodexDynamicToolFingerprintsCompatible, X as fingerprintJsonObject, Y as fingerprintEnvironmentSelection, Z as fingerprintUserMcpServersConfigPatch, _ as resolveCodexAppServerModelProvider, at as shouldRotateCodexGpt56MultiAgentBinding, bt as disableUnlistedCodexApps, c as codexThreadSandboxOrPermissions, d as resolveCodexThreadApprovalsReviewer, et as shouldStartTransientNoToolThread, g as CODEX_NATIVE_PERSONALITY_NONE, h as buildDeveloperInstructions, i as buildCodexRuntimeThreadConfigForRun, it as shouldRotateCodexAppServerBindingForRuntime, l as readCodexInheritedMcpServerNames, lt as isMessageOnlyCodexSourceReply, m as mergeCodexNativeShellEnvironment, mt as buildCodexPluginAppsConfigPatchFromPolicyContext, n as buildCodexRingZeroThreadConfigPatch, nt as isTransientWebSearchRestriction, o as buildThreadResumeParams, p as resolveCodexWebSearchPlan, q as codexLegacyDynamicToolsFingerprint, rt as shouldRecheckRecoverablePluginBinding, s as buildThreadStartParams, t as assertCodexManagedRequirementsDoNotOverrideToolPolicy, u as readCodexManagedRequirementsFingerprint, ut as isSystemAgentOnlyCodexDynamicToolAllowlist, v as resolveCodexAppServerRequestModelSelection, x as joinPresentSections, xt as isCodexPluginThreadBindingStale, y as resolveCodexAppServerThreadModelSelection, yt as buildPluginAppPolicyContext, z as hasCodexNativeToolCatalog } from "./thread-requests-
|
|
25
|
-
import { o as resolveCodexSessionBinding, r as hashCodexAppServerBindingFingerprint } from "./session-binding-
|
|
26
|
-
import { a as refreshCodexThreadPolicy, i as assertCodexSupervisionThreadLineage, n as CodexThreadPolicyHandoffError, o as refreshCodexThreadSkillsCatalog, r as assertAdoptedCodexThreadResumeAllowed, t as CodexIncognitoPolicyChangeError } from "./thread-policy-
|
|
27
|
-
import { t as resumeCodexAppServerThread } from "./thread-resume-
|
|
28
|
-
import { c as withExclusiveCodexAppServerThread, r as retainCodexAppServerBindingSubscription, t as isSameCodexAppServerThreadOwner } from "./thread-ownership-
|
|
29
|
-
import "./transcript-mirror-
|
|
21
|
+
import { $ as createCodexEphemeralThreadPolicy, A as bindCodexInferenceThread, B as isCodexAppServerClientRuntimeLive, C as CodexThreadBindingConflictError, F as consumeCodexAppServerLiveThread, H as isCodexAppServerLiveThreadProtected, K as releaseCodexAppServerLiveThread, M as getCodexInferenceThreadQualification, N as prepareCodexInferenceThreadConfig, S as CodexAdoptedThreadActiveError, T as CodexThreadStartRequestError, V as isCodexAppServerLiveThreadClaimed, Y as unsubscribeCodexAppServerLiveThread, et as wasCodexAppServerThreadClosed, j as getCodexInferenceThread, k as assertCodexInferenceRouteConfig, n as captureCodexAppServerClientLifetime, w as CodexThreadClientReplacementError, z as hasCodexAppServerSiblingThreadWork } from "./shared-client-ZXKMsK6f.mjs";
|
|
22
|
+
import { C as assertExactSupervisionModelSelection, D as readSupervisionResponseThreadId, O as resolveCodexThreadRolloutPath, d as isCodexAppServerRequestTimeoutError, l as isCodexAppServerOverloadError, p as resolveCodexAppServerClientInstanceId, r as getCodexAppServerClientInstanceId, v as assertCodexThreadAcceptsDirectInput, x as assertCodexThreadStartResponse, y as assertCodexThreadForkResponse } from "./client-DcTISXe3.mjs";
|
|
23
|
+
import { c as isCodexAppServerUnsafeSubscriptionError, g as hasCodexAppServerSiblingRouteWork, n as CODEX_APP_SERVER_UNSUBSCRIBE_TIMEOUT_MS, o as closeCodexStartupClientBestEffort, p as unsubscribeCodexThreadBestEffort, r as CodexAppServerUnsafeSubscriptionError, u as retireUnsafeCodexTurnClientBestEffort } from "./attempt-client-cleanup-BVtNsTOE.mjs";
|
|
24
|
+
import { $ as readActiveCodexTurnIdsFromResume, B as loadCodexNativeToolCatalog, C as mergeCodexNativeProjectDocThreadConfig, E as assertCodexNativeHookRelayAllowed, F as attestCodexThreadToolSurface, G as areUserMcpServersFingerprintsCompatible, H as applyCodexNativeSkillIsolation, I as checkCodexThreadAppAvailability, J as fingerprintCodexThreadConfig, K as codexDynamicToolsFingerprint, L as discardUnattestedCodexPluginThread, Q as legacyFingerprintUserMcpServersConfigPatch, R as attestCodexRestrictedToolSurfaceMcpServersDisabled, St as mergeCodexThreadConfigs, T as CodexManagedHooksOnlyError, Tt as buildCodexAppApprovalOverrides, U as resolveCodexNativeSkillIsolation, W as areCodexDynamicToolFingerprintsCompatible, X as fingerprintJsonObject, Y as fingerprintEnvironmentSelection, Z as fingerprintUserMcpServersConfigPatch, _ as resolveCodexAppServerModelProvider, at as shouldRotateCodexGpt56MultiAgentBinding, bt as disableUnlistedCodexApps, c as codexThreadSandboxOrPermissions, d as resolveCodexThreadApprovalsReviewer, et as shouldStartTransientNoToolThread, g as CODEX_NATIVE_PERSONALITY_NONE, h as buildDeveloperInstructions, i as buildCodexRuntimeThreadConfigForRun, it as shouldRotateCodexAppServerBindingForRuntime, l as readCodexInheritedMcpServerNames, lt as isMessageOnlyCodexSourceReply, m as mergeCodexNativeShellEnvironment, mt as buildCodexPluginAppsConfigPatchFromPolicyContext, n as buildCodexRingZeroThreadConfigPatch, nt as isTransientWebSearchRestriction, o as buildThreadResumeParams, p as resolveCodexWebSearchPlan, q as codexLegacyDynamicToolsFingerprint, rt as shouldRecheckRecoverablePluginBinding, s as buildThreadStartParams, t as assertCodexManagedRequirementsDoNotOverrideToolPolicy, u as readCodexManagedRequirementsFingerprint, ut as isSystemAgentOnlyCodexDynamicToolAllowlist, v as resolveCodexAppServerRequestModelSelection, x as joinPresentSections, xt as isCodexPluginThreadBindingStale, y as resolveCodexAppServerThreadModelSelection, yt as buildPluginAppPolicyContext, z as hasCodexNativeToolCatalog } from "./thread-requests-y_MnVuWC.mjs";
|
|
25
|
+
import { o as resolveCodexSessionBinding, r as hashCodexAppServerBindingFingerprint } from "./session-binding-Fn7Ekzuv.mjs";
|
|
26
|
+
import { a as refreshCodexThreadPolicy, i as assertCodexSupervisionThreadLineage, n as CodexThreadPolicyHandoffError, o as refreshCodexThreadSkillsCatalog, r as assertAdoptedCodexThreadResumeAllowed, t as CodexIncognitoPolicyChangeError } from "./thread-policy-MM5YD22L.mjs";
|
|
27
|
+
import { t as resumeCodexAppServerThread } from "./thread-resume-B9clyqXE.mjs";
|
|
28
|
+
import { c as withExclusiveCodexAppServerThread, r as retainCodexAppServerBindingSubscription, t as isSameCodexAppServerThreadOwner } from "./thread-ownership-BT_SeSUp.mjs";
|
|
29
|
+
import "./transcript-mirror-BRNhyb1o.mjs";
|
|
30
30
|
import { asOptionalRecord, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
31
31
|
import crypto from "node:crypto";
|
|
32
32
|
import { isDeepStrictEqual } from "node:util";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { u as retainSharedCodexAppServerClientByInstanceId } from "./shared-client-lifecycle-BH_y_i8l.mjs";
|
|
2
2
|
import { t as withCodexAppServerThreadMutation } from "./thread-ownership-queue-Dp24d7-F.mjs";
|
|
3
|
-
import { K as releaseCodexAppServerLiveThread, V as isCodexAppServerLiveThreadClaimed, q as retainCodexAppServerLiveThread } from "./shared-client-
|
|
4
|
-
import { o as closeCodexStartupClientBestEffort, p as unsubscribeCodexThreadBestEffort, r as CodexAppServerUnsafeSubscriptionError } from "./attempt-client-cleanup-
|
|
5
|
-
import { t as __exportAll } from "./session-binding-sidecars-
|
|
3
|
+
import { K as releaseCodexAppServerLiveThread, V as isCodexAppServerLiveThreadClaimed, q as retainCodexAppServerLiveThread } from "./shared-client-ZXKMsK6f.mjs";
|
|
4
|
+
import { o as closeCodexStartupClientBestEffort, p as unsubscribeCodexThreadBestEffort, r as CodexAppServerUnsafeSubscriptionError } from "./attempt-client-cleanup-BVtNsTOE.mjs";
|
|
5
|
+
import { t as __exportAll } from "./session-binding-sidecars-BuEALwJY.mjs";
|
|
6
6
|
import { createDeferred } from "openclaw/plugin-sdk/extension-shared";
|
|
7
7
|
import { runWithAsyncWorkResources } from "openclaw/plugin-sdk/agent-harness-tool-runtime";
|
|
8
8
|
//#region extensions/codex/src/app-server/thread-ownership.ts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { r as requestCodexAppServerClientJson, t as CodexAppServerScopedRequestRejectedError } from "./request-
|
|
2
|
-
import { S as CodexAdoptedThreadActiveError } from "./shared-client-
|
|
3
|
-
import { l as isCodexAppServerOverloadError, u as isCodexAppServerPrewriteRequestCancellationError, v as assertCodexThreadAcceptsDirectInput } from "./client-
|
|
1
|
+
import { r as requestCodexAppServerClientJson, t as CodexAppServerScopedRequestRejectedError } from "./request-CWERwKIL.mjs";
|
|
2
|
+
import { S as CodexAdoptedThreadActiveError } from "./shared-client-ZXKMsK6f.mjs";
|
|
3
|
+
import { l as isCodexAppServerOverloadError, u as isCodexAppServerPrewriteRequestCancellationError, v as assertCodexThreadAcceptsDirectInput } from "./client-DcTISXe3.mjs";
|
|
4
4
|
import { AgentHarnessPreflightError, embeddedAgentLog, formatErrorMessage } from "openclaw/plugin-sdk/agent-harness-runtime";
|
|
5
5
|
//#region extensions/codex/src/app-server/thread-policy.ts
|
|
6
6
|
/** A refusal, not a failed native write: the ephemeral conversation must stay alive. */
|