@openclaw/codex 2026.9.6 → 2026.9.8

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.
Files changed (158) hide show
  1. package/README.md +2 -0
  2. package/assets/icon.png +0 -0
  3. package/dist/.setup/{account-usage-runtime-Eem_WGqY.mjs → account-usage-runtime-G348lY1q.mjs} +5 -5
  4. package/dist/.setup/{apply-DDOi8uNx.mjs → apply-Cqb-YoCS.mjs} +22 -36
  5. package/dist/.setup/{attempt-client-cleanup-CEv1cKwF.mjs → attempt-client-cleanup-B-S7ngS_.mjs} +128 -37
  6. package/dist/.setup/attempt-workspace-context-BJ5Z_olH.mjs +164 -0
  7. package/dist/.setup/{auth-binding-DhLWa_7K.mjs → auth-binding-BLWz7stm.mjs} +14 -1
  8. package/dist/.setup/{auth-cache-key-B2mpaI9D.mjs → auth-cache-key-Dnps4W4_.mjs} +36 -34
  9. package/dist/.setup/{auth-profile-WqZtZfXN.mjs → auth-profile-B0okYl2D.mjs} +1 -2
  10. package/dist/.setup/auth-start-options-BPIPeEX8.mjs +44 -0
  11. package/dist/.setup/{binding-connection-ThoatDcb.mjs → binding-connection-DTtN1KrX.mjs} +2 -2
  12. package/dist/.setup/{binding-connection.runtime-yoHrABt-.mjs → binding-connection.runtime-6TpgD1M6.mjs} +4 -4
  13. package/dist/.setup/{bounded-turn-B2HScEgT.mjs → bounded-turn-BNunZPtz.mjs} +15 -18
  14. package/dist/.setup/bounded-turn-isolation-B8K_ylqk.mjs +14 -0
  15. package/dist/.setup/{build-state-C7EnDVgr.mjs → build-state-DIQ5O_-S.mjs} +1 -1
  16. package/dist/.setup/{capabilities-CDXOOFdZ.mjs → capabilities-B3WEZl4e.mjs} +2 -10
  17. package/dist/.setup/{client-catalog-response-BMgt_4q4.mjs → client-catalog-response-DRvx_wCC.mjs} +1 -1
  18. package/dist/.setup/{client-Cs08OXVQ.mjs → client-qyUBJlGZ.mjs} +138 -399
  19. package/dist/.setup/{command-dispatch-B4JuOsOk.mjs → command-dispatch-Btrs1D6f.mjs} +5 -8
  20. package/dist/.setup/{command-formatters-Bmqvr9tO.mjs → command-formatters-R3ckE3Co.mjs} +29 -61
  21. package/dist/.setup/{command-handlers-DW7Lx9oH.mjs → command-handlers-DvlCHJch.mjs} +222 -343
  22. package/dist/.setup/{command-rpc-DixIj3HW.mjs → command-rpc-skzRq4wD.mjs} +15 -18
  23. package/dist/.setup/compact-8ttks5U5.mjs +776 -0
  24. package/dist/.setup/{config-BoTP_mrL.mjs → config-DKhXquav.mjs} +26 -28
  25. package/dist/.setup/{config-options-BvaRs51b.mjs → config-options-CzyWLTJt.mjs} +24 -37
  26. package/dist/.setup/{config-parsing-CcB9iPoq.mjs → config-parsing-b088LyhT.mjs} +57 -60
  27. package/dist/.setup/{config-runtime-C8Rw1m1m.mjs → config-runtime-C0NbLms1.mjs} +2 -2
  28. package/dist/.setup/{config-security-BEReZ6go.mjs → config-security-CE-FcGw9.mjs} +32 -111
  29. package/dist/.setup/{config-utils-DujwEnhg.mjs → config-utils-D0CXecki.mjs} +3 -13
  30. package/dist/.setup/context-engine-projection-PezSESth.mjs +387 -0
  31. package/dist/.setup/{conversation-binding-DP-gMrBP.mjs → conversation-binding-74LaGGH-.mjs} +67 -90
  32. package/dist/.setup/{conversation-binding-data-CrcyZk6O.mjs → conversation-binding-data-C746z5Pn.mjs} +8 -12
  33. package/dist/.setup/{conversation-control-uK9Jomlc.mjs → conversation-control-OrN6zuaY.mjs} +8 -8
  34. package/dist/.setup/{cyber-failover-DYwbmf1o.mjs → cyber-failover-XV0nNRZu.mjs} +1 -1
  35. package/dist/.setup/{cyber-failover-notice-e9G3J9-e.mjs → cyber-failover-notice-RNpGpTyP.mjs} +1 -1
  36. package/dist/.setup/{dynamic-tools-BDXl-8Cw.mjs → dynamic-tools-Db2sY5cZ.mjs} +2305 -2606
  37. package/dist/.setup/{effective-mcp-catalog-CvnvnGIe.mjs → effective-mcp-catalog-Bi6-SQ7i.mjs} +8 -17
  38. package/dist/.setup/{ephemeral-turn-poidXgek.mjs → ephemeral-turn-DiCS1ijR.mjs} +3 -3
  39. package/dist/.setup/event-projector-assistant-message-MV_1dj-3.mjs +69 -0
  40. package/dist/.setup/{event-projector-usage-CnBS8Wa3.mjs → event-projector-usage-03R0I2dM.mjs} +3 -25
  41. package/dist/.setup/event-projector-values-DJSz8BTk.mjs +106 -0
  42. package/dist/.setup/incognito-session-DWYapfwf.mjs +2 -0
  43. package/dist/.setup/{inference-context-D96l9-ew.mjs → inference-context-D-9gWlTR.mjs} +16 -18
  44. package/dist/.setup/inference-dispatch-CMZtjQyz.mjs +359 -0
  45. package/dist/.setup/inference-metadata-CgIf7sOx.mjs +81 -0
  46. package/dist/.setup/{inference-proxy-b-aJMSxm.mjs → inference-proxy-DhcXOgUE.mjs} +174 -214
  47. package/dist/.setup/{isolated-completion-BIZFhTNG.mjs → isolated-completion-D80IXfQF.mjs} +9 -12
  48. package/dist/.setup/{managed-binary-BnshlFag.mjs → managed-binary-kiWRhNRE.mjs} +8 -12
  49. package/dist/.setup/{model-catalog-CfXJf9Ay.mjs → model-catalog-DiC0Tkha.mjs} +11 -10
  50. package/dist/.setup/model-runtime-BdqzOMkU.mjs +11 -0
  51. package/dist/.setup/{models-KnqBv0hE.mjs → models-DfLmPV0k.mjs} +9 -18
  52. package/dist/.setup/{native-auth-rWbGbMn3.mjs → native-auth-CuG53tu4.mjs} +4 -4
  53. package/dist/.setup/{native-execution-policy-umd0tgh4.mjs → native-execution-policy-BxZJy5mP.mjs} +5 -30
  54. package/dist/.setup/{native-subagent-monitor-D3filLY2.mjs → native-subagent-monitor-BwkQXf9e.mjs} +4395 -3609
  55. package/dist/.setup/native-subagent-pending-assignments-DwkCzLvD.mjs +203 -0
  56. package/dist/.setup/native-task-assignments-DMQ0g3hu.mjs +194 -0
  57. package/dist/.setup/{node-cli-sessions-r3avj02l.mjs → node-cli-sessions-HC4W6FLI.mjs} +19 -49
  58. package/dist/.setup/{node-exec-server.runtime-BDwWXVpK.mjs → node-exec-server.runtime-BgBfWQqo.mjs} +3 -6
  59. package/dist/.setup/{plan-CN3VwfNU.mjs → plan-DPdMk1Oy.mjs} +49 -92
  60. package/dist/.setup/{plugin-activation-DT3MNtqj.mjs → plugin-activation-cNHRfaxU.mjs} +8 -36
  61. package/dist/.setup/{plugin-app-cache-key-B2CsSdnV.mjs → plugin-app-cache-key-BL9B5H0L.mjs} +6 -23
  62. package/dist/.setup/{plugin-inventory-BoRei8Z4.mjs → plugin-inventory-Cky2XJUw.mjs} +21 -21
  63. package/dist/.setup/{plugin-marketplace-discovery-CDOi8IFs.mjs → plugin-marketplace-discovery-D_dV9FXa.mjs} +18 -24
  64. package/dist/.setup/{plugin-metadata-cache-Ctmo83k_.mjs → plugin-metadata-cache-BRwtRct9.mjs} +116 -176
  65. package/dist/.setup/{provider-BOsxQHOM.mjs → provider-D6F_7p1I.mjs} +11 -14
  66. package/dist/.setup/{provider-capabilities-BfE88FZ5.mjs → provider-capabilities-DG5qbsUZ.mjs} +13 -18
  67. package/dist/.setup/{rate-limits-CMU3DUD0.mjs → rate-limits-B7-X2TgG.mjs} +9 -31
  68. package/dist/.setup/{request-D2L0zMrq.mjs → request-BZOfsSXW.mjs} +7 -6
  69. package/dist/.setup/responses-oauth-twnuTaAa.mjs +93 -0
  70. package/dist/.setup/rpc-error-BlD2vuzn.mjs +31 -0
  71. package/dist/.setup/{run-attempt-BHu11r7h.mjs → run-attempt-dYJhjZrp.mjs} +1035 -1023
  72. package/dist/.setup/{run-attempt-lifecycle-B7JbY4-F.mjs → run-attempt-lifecycle-C-6O3Exn.mjs} +10 -24
  73. package/dist/.setup/{runtime-artifact-CLZ8udh-.mjs → runtime-artifact-DDQ-HGXf.mjs} +16 -4
  74. package/dist/.setup/runtime-artifact-connection-D68qQn1m.mjs +78 -0
  75. package/dist/.setup/sandbox-guard-DjCz2eOw.mjs +126 -0
  76. package/dist/.setup/scope-DOC1Xjc8.mjs +6 -0
  77. package/dist/.setup/session-binding-DGCYAfvD.mjs +443 -0
  78. package/dist/.setup/{session-binding-record-BGoz8wOK.mjs → session-binding-record-Oe9L-CNY.mjs} +52 -130
  79. package/dist/.setup/{session-binding-sidecars-BlB5EvIS.mjs → session-binding-sidecars-jo6H8dFr.mjs} +196 -17
  80. package/dist/.setup/{session-catalog-Pno1xGcl.mjs → session-catalog-BFafIiF6.mjs} +185 -350
  81. package/dist/.setup/{session-catalog-adoption-BI6UTDZT.mjs → session-catalog-adoption-BU_pHWG7.mjs} +7 -6
  82. package/dist/.setup/{session-catalog-archive-lHBqzhaO.mjs → session-catalog-archive-spHfihri.mjs} +6 -6
  83. package/dist/.setup/session-catalog-events-BMCFMZw-.mjs +139 -0
  84. package/dist/.setup/session-catalog-home-id-vlih0B_g.mjs +22 -0
  85. package/dist/.setup/{session-catalog-index-B9_VQIUz.mjs → session-catalog-index-DwJjnF5k.mjs} +126 -122
  86. package/dist/.setup/{session-catalog-index-order-hcdz07yN.mjs → session-catalog-index-order-BcQpHks3.mjs} +1 -1
  87. package/dist/.setup/{session-catalog-index-state-Dgh8ORJm.mjs → session-catalog-index-state-TeO7EyO-.mjs} +3 -2
  88. package/dist/.setup/session-catalog-limits-DDxOsQeC.mjs +14 -0
  89. package/dist/.setup/session-catalog-list-request-CvtxrYSe.mjs +170 -0
  90. package/dist/.setup/session-catalog-native-projection-CuaFZuQE.mjs +178 -0
  91. package/dist/.setup/{session-catalog-node-adoption-ITddWx_X.mjs → session-catalog-node-adoption-DgXvSGu0.mjs} +10 -27
  92. package/dist/.setup/{session-catalog-node-continue-6g6qi4A9.mjs → session-catalog-node-continue-DjKXHBbi.mjs} +8 -10
  93. package/dist/.setup/session-catalog-node-lookup-CtAXI5W5.mjs +56 -0
  94. package/dist/.setup/{session-catalog-native-projection-DowriLid.mjs → session-catalog-parsing-CPGaPYr-.mjs} +11 -194
  95. package/dist/.setup/{session-catalog-projection-zK_PUsiE.mjs → session-catalog-projection-CGfzfP93.mjs} +6 -4
  96. package/dist/.setup/session-catalog-provenance-DoAvktcj.mjs +95 -0
  97. package/dist/.setup/{session-cli-irrD-uo7.mjs → session-cli-DlmBHYIe.mjs} +9 -22
  98. package/dist/.setup/{session-history-BrqhSCf9.mjs → session-history-D83lJWHG.mjs} +4 -6
  99. package/dist/.setup/{session-history-import-D-3wAgOP.mjs → session-history-import-WhX-X33a.mjs} +7 -10
  100. package/dist/.setup/session-history-read-Ov3StuL4.mjs +133 -0
  101. package/dist/.setup/{session-history.worker-CaCh0xF_.mjs → session-history.worker-MnPKncqP.mjs} +9 -5
  102. package/dist/.setup/session-initialization-6aveB9qb.mjs +22 -0
  103. package/dist/.setup/{session-permission-policy-BI1QK_98.mjs → session-permission-policy-Ci_fVX6y.mjs} +4 -8
  104. package/dist/.setup/{session-retirement-BH-S6qkJ.mjs → session-retirement-LlYWBKTJ.mjs} +17 -17
  105. package/dist/.setup/{settled-turn-context-fmwouT5I.mjs → settled-turn-context-D4yj4rxf.mjs} +1 -1
  106. package/dist/.setup/{settled-turn-finalizer-DiAi6Kx6.mjs → settled-turn-finalizer-DW9W3gza.mjs} +14 -10
  107. package/dist/.setup/{shared-client-DA4VR4Eb.mjs → shared-client-CJCTeFpQ.mjs} +783 -412
  108. package/dist/.setup/shared-client-lifecycle-7xgtlo15.mjs +153 -0
  109. package/dist/.setup/{side-question-BJ1wSDcB.mjs → side-question-BLeGj7TQ.mjs} +79 -143
  110. package/dist/.setup/{source-CUzJq5WN.mjs → source-CJis_1EF.mjs} +80 -137
  111. package/dist/.setup/{thread-lifecycle-B3mfz1TG.mjs → thread-lifecycle-_bAbjedG.mjs} +294 -737
  112. package/dist/.setup/{thread-ownership-DcTtAcXj.mjs → thread-ownership-B6pPt21M.mjs} +45 -10
  113. package/dist/.setup/{incognito-session-uhrBF6wJ.mjs → thread-ownership-queue-Dp24d7-F.mjs} +1 -2
  114. package/dist/.setup/{thread-policy-DGuQsuFC.mjs → thread-policy-gNPzzpVp.mjs} +46 -7
  115. package/dist/.setup/{thread-requests-BLvGkP2R.mjs → thread-requests-OWGOiDaV.mjs} +199 -302
  116. package/dist/.setup/{thread-resume-DIBXwOpE.mjs → thread-resume-GOry0AYh.mjs} +6 -6
  117. package/dist/.setup/{timeout-C910MdAB.mjs → timeout-CXOfNoaX.mjs} +1 -35
  118. package/dist/.setup/{transcript-history-projection-ZZpkFkJ_.mjs → transcript-history-projection-DRSifI-1.mjs} +17 -89
  119. package/dist/.setup/{transcript-mirror-attestation-CzM-94NC.mjs → transcript-mirror-attestation-YSegaktH.mjs} +3 -4
  120. package/dist/.setup/{transcript-mirror-BtHDBp1G.mjs → transcript-mirror-kxmCYsuF.mjs} +7 -9
  121. package/dist/.setup/{transport-stdio-h2VHOskC.mjs → transport-stdio-Bdegpn2V.mjs} +5 -22
  122. package/dist/.setup/transport-websocket-BTBE-LD9.mjs +211 -0
  123. package/dist/.setup/{upstream-prompt-provenance-LphB8slG.mjs → upstream-prompt-provenance-fXkKbPVC.mjs} +3 -9
  124. package/dist/.setup/{upstream-session-fork-BUr4OUbC.mjs → upstream-session-fork-gkdRj2yH.mjs} +23 -23
  125. package/dist/.setup/{usage-BML0r-ua.mjs → usage-CApUvLOV.mjs} +4 -4
  126. package/dist/.setup/{usage-limit-error-DUMbefVY.mjs → usage-limit-error-wSMQkbpV.mjs} +4 -19
  127. package/dist/.setup/{web-search-provider.runtime-CDKlN-Rv.mjs → web-search-provider.runtime-UKgeiBUG.mjs} +8 -19
  128. package/dist/api.js +9 -11
  129. package/dist/catalog-page.worker.js +1 -1
  130. package/dist/cli-metadata.js +1 -1
  131. package/dist/doctor-contract-api.js +50 -8
  132. package/dist/harness.js +344 -1
  133. package/dist/index.js +193 -245
  134. package/dist/media-understanding-provider.js +9 -22
  135. package/dist/migration-provider-api.js +1 -1
  136. package/dist/provider-discovery.js +1 -1
  137. package/dist/session-history-worker-runtime.js +3 -3
  138. package/dist/session-history.worker.js +1 -1
  139. package/openclaw.plugin.json +14 -2
  140. package/package.json +7 -6
  141. package/dist/.setup/attempt-workspace-context-DUVEn_CS.mjs +0 -331
  142. package/dist/.setup/compact-Du5UvtxA.mjs +0 -680
  143. package/dist/.setup/event-projector-assistant-message-BsruvNrH.mjs +0 -103
  144. package/dist/.setup/event-projector-items-C6L_5ZiT.mjs +0 -234
  145. package/dist/.setup/harness-a_MsE4-_.mjs +0 -355
  146. package/dist/.setup/history-rejection-B4nOXNXF.mjs +0 -13
  147. package/dist/.setup/image-payload-sanitizer-tupAr-2o.mjs +0 -79
  148. package/dist/.setup/local-runtime-attribution-B_2mnqhb.mjs +0 -19
  149. package/dist/.setup/native-subagent-history-0nYYgo0k.mjs +0 -148
  150. package/dist/.setup/native-subagent-task-ids-wb8CKZGN.mjs +0 -441
  151. package/dist/.setup/plugin-approval-roundtrip-C0MZzCuP.mjs +0 -122
  152. package/dist/.setup/rolldown-runtime-8H4AJuhK.mjs +0 -14
  153. package/dist/.setup/sandbox-guard-C2sRMOEY.mjs +0 -166
  154. package/dist/.setup/session-binding-Cm0apEbd.mjs +0 -692
  155. package/dist/.setup/session-catalog-events-Bj6j94E_.mjs +0 -347
  156. package/dist/.setup/session-history-read-B3ZfSUbF.mjs +0 -50
  157. package/dist/.setup/session-initialization-rcgbZiid.mjs +0 -75
  158. package/dist/.setup/thread-history-page-DoVpnHim.mjs +0 -83
@@ -1,16 +1,15 @@
1
- import { d as resolveCodexAppServerHomeDir } from "./config-security-BEReZ6go.mjs";
2
- import { o as resolveCodexComputerUseConfig } from "./config-options-BvaRs51b.mjs";
3
- import { d as resolveMacOSDesktopCodexBundledMarketplaceCandidates, l as resolveFirstExistingMacOSDesktopCodexBundledMarketplacePath, t as isManagedCodexDesktopCommand } from "./managed-binary-BnshlFag.mjs";
4
- import { n as describeControlFailure } from "./capabilities-CDXOOFdZ.mjs";
5
- import { r as requestCodexAppServerClientJson } from "./request-D2L0zMrq.mjs";
6
- import "./config-BoTP_mrL.mjs";
7
- import { n as resolveCodexAppServerRuntimeOptions } from "./config-runtime-C8Rw1m1m.mjs";
8
- import { $ as assertNotSymlink, D as acquireCodexNativeConfigFence, Q as resolveCodexManagedBundledMarketplacePath, Y as reconcileCodexComputerUseStartArtifacts, b as waitForCodexAppServerClientDesktopGenerationDrain, c as getLeasedSharedCodexAppServerClient, d as readCodexAppServerClientDesktopGeneration, g as resolveCodexNativeConfigFenceKey, h as releaseLeasedSharedCodexAppServerClient, p as readCodexAppServerClientProcessIdentity, t as assertCodexAppServerClientStartSelectionCurrent, u as isCodexAppServerStartSelectionChangedError, x as withLeasedCodexAppServerClientStartSelectionRetry } from "./shared-client-DA4VR4Eb.mjs";
9
- import { c as isCodexAppServerIndeterminateTransportError, o as isCodexAppServerConnectionClosedError, s as isCodexAppServerIndeterminateRequestCancellationError } from "./client-Cs08OXVQ.mjs";
10
- import { r as CodexAppServerUnsafeSubscriptionError, u as retireUnsafeCodexTurnClientBestEffort } from "./attempt-client-cleanup-CEv1cKwF.mjs";
11
- import { existsSync } from "node:fs";
1
+ import { t as resolveCodexAppServerHomeDir } from "./auth-start-options-BPIPeEX8.mjs";
2
+ import { o as resolveCodexComputerUseConfig } from "./config-options-CzyWLTJt.mjs";
3
+ import { d as resolveMacOSDesktopCodexBundledMarketplaceCandidates, t as isManagedCodexDesktopCommand } from "./managed-binary-kiWRhNRE.mjs";
4
+ import { n as describeControlFailure } from "./capabilities-B3WEZl4e.mjs";
5
+ import { r as requestCodexAppServerClientJson } from "./request-BZOfsSXW.mjs";
6
+ import "./config-DKhXquav.mjs";
7
+ import { n as resolveCodexAppServerRuntimeOptions } from "./config-runtime-C0NbLms1.mjs";
8
+ import { $ as reconcileCodexComputerUseStartArtifacts, O as acquireCodexNativeConfigFence, at as isLegacyCodexComputerUsePluginDisabled, b as withLeasedCodexAppServerClientStartSelectionRetry, c as getLeasedSharedCodexAppServerClient, ct as assertNotSymlink, d as readCodexAppServerClientDesktopGeneration, g as resolveCodexNativeConfigFenceKey, h as releaseLeasedSharedCodexAppServerClient, it as hasLegacyCodexComputerUseMcpPolicy, nt as resolveBundledComputerUseMarketplacePath, ot as resolveManagedCodexComputerUseConfig, p as readCodexAppServerClientProcessIdentity, rt as resolveClientManagedBundledMarketplacePath, st as ensureCodexComputerUseSharedPluginCache, t as assertCodexAppServerClientStartSelectionCurrent, u as isCodexAppServerStartSelectionChangedError, y as waitForCodexAppServerClientDesktopGenerationDrain } from "./shared-client-CJCTeFpQ.mjs";
9
+ import { c as isCodexAppServerIndeterminateTransportError, o as isCodexAppServerConnectionClosedError, s as isCodexAppServerIndeterminateRequestCancellationError } from "./client-qyUBJlGZ.mjs";
10
+ import { r as CodexAppServerUnsafeSubscriptionError, u as retireUnsafeCodexTurnClientBestEffort } from "./attempt-client-cleanup-B-S7ngS_.mjs";
12
11
  import path from "node:path";
13
- import fs$1 from "node:fs/promises";
12
+ import fs from "node:fs/promises";
14
13
  import { toErrorObject } from "openclaw/plugin-sdk/error-runtime";
15
14
  //#region extensions/codex/src/app-server/computer-use-readiness.ts
16
15
  /** Computer Use readiness probes and their native subscription lifecycle. */
@@ -36,7 +35,7 @@ const COMPUTER_USE_LIVE_TEST_RETRY_COUNT = 1;
36
35
  const COMPUTER_USE_LIVE_TEST_THREAD_NAME = "OpenClaw Computer Use readiness probe";
37
36
  const COMPUTER_USE_LIST_APPS_TOOL = "list_apps";
38
37
  const COMPUTER_USE_UNIFIED_JS_TOOL = "js";
39
- const COMPUTER_USE_UNIFIED_JS_PROBE = "await cua.getState();";
38
+ const COMPUTER_USE_UNIFIED_JS_PROBE = "await cua.listApps();";
40
39
  async function runCodexComputerUseLiveTest(params) {
41
40
  const startedAt = Date.now();
42
41
  let lastError;
@@ -162,11 +161,38 @@ function skippedLiveTestStatus(config, message) {
162
161
  };
163
162
  }
164
163
  //#endregion
164
+ //#region extensions/codex/src/app-server/computer-use-status.ts
165
+ function unavailableStatus(config, reason, message) {
166
+ const disabled = reason === "disabled";
167
+ return {
168
+ enabled: !disabled,
169
+ ready: false,
170
+ reason,
171
+ installed: reason === "plugin_disabled" ? null : false,
172
+ pluginEnabled: false,
173
+ mcpServerAvailable: false,
174
+ pluginName: config.pluginName,
175
+ mcpServerName: config.mcpServerName,
176
+ ...!disabled && config.marketplaceName ? { marketplaceName: config.marketplaceName } : {},
177
+ ...!disabled && config.marketplacePath ? { marketplacePath: config.marketplacePath } : {},
178
+ tools: [],
179
+ installation: {
180
+ status: disabled ? "disabled" : reason === "plugin_disabled" ? "unchecked" : reason === "marketplace_missing" ? "marketplace_missing" : "not_installed",
181
+ ok: false,
182
+ message
183
+ },
184
+ exposure: {
185
+ status: "skipped",
186
+ ok: false,
187
+ message: disabled ? "MCP exposure was not checked because Computer Use is disabled." : "MCP exposure was not checked because Computer Use installation is not ready."
188
+ },
189
+ liveTest: skippedLiveTestStatus(config, disabled ? "Computer Use live test was not run because Computer Use is disabled." : "Computer Use live test was not run because installation is not ready."),
190
+ warnings: [],
191
+ message
192
+ };
193
+ }
194
+ //#endregion
165
195
  //#region extensions/codex/src/app-server/computer-use.ts
166
- /**
167
- * Computer Use plugin/MCP readiness checks and optional install flow for Codex
168
- * app-server sessions.
169
- */
170
196
  var CodexComputerUseSetupError = class extends Error {
171
197
  constructor(status) {
172
198
  super(status.message);
@@ -186,13 +212,13 @@ const COMPUTER_USE_MARKETPLACE_NAME_PRIORITY = [
186
212
  /** Reads Computer Use readiness without installing or mutating app-server state. */
187
213
  async function readCodexComputerUseStatus(params = {}) {
188
214
  const config = resolveComputerUseConfig(params);
189
- if (!config.enabled) return disabledStatus(config);
215
+ if (!config.enabled) return unavailableStatus(config, "disabled", "Computer Use is disabled.");
190
216
  try {
191
217
  return await inspectCodexComputerUse({
192
218
  ...params,
193
219
  computerUseConfig: config,
194
220
  runLiveTest: true,
195
- installPlugin: false
221
+ installMode: "none"
196
222
  });
197
223
  } catch (error) {
198
224
  return unavailableStatus(config, "check_failed", `Computer Use check failed: ${describeControlFailure(error)}`);
@@ -204,12 +230,13 @@ async function readCodexComputerUseStatus(params = {}) {
204
230
  */
205
231
  async function ensureCodexComputerUse(params = {}) {
206
232
  const config = resolveComputerUseConfig(params);
207
- if (!config.enabled) return disabledStatus(config);
233
+ if (!config.enabled) return unavailableStatus(config, "disabled", "Computer Use is disabled.");
208
234
  const status = await inspectCodexComputerUse({
209
235
  ...params,
210
236
  computerUseConfig: config,
211
237
  runLiveTest: config.strictReadiness,
212
- installPlugin: false
238
+ installMode: "none",
239
+ refreshSharedCache: config.autoInstall
213
240
  });
214
241
  if (status.ready) return status;
215
242
  if (config.autoInstall) {
@@ -219,13 +246,13 @@ async function ensureCodexComputerUse(params = {}) {
219
246
  ...params,
220
247
  computerUseConfig: config,
221
248
  runLiveTest: config.strictReadiness,
222
- installPlugin: true
249
+ installMode: "automatic",
250
+ refreshSharedCache: true
223
251
  });
224
252
  if (!installedStatus.ready) throw new CodexComputerUseSetupError(installedStatus);
225
253
  return installedStatus;
226
254
  }
227
- if (!status.ready) throw new CodexComputerUseSetupError(status);
228
- return status;
255
+ throw new CodexComputerUseSetupError(status);
229
256
  }
230
257
  /** Forces Computer Use plugin installation and returns the ready status. */
231
258
  async function installCodexComputerUse(params = {}) {
@@ -242,7 +269,7 @@ async function installCodexComputerUse(params = {}) {
242
269
  ...params,
243
270
  computerUseConfig: config,
244
271
  runLiveTest: true,
245
- installPlugin: true
272
+ installMode: "explicit"
246
273
  });
247
274
  if (!status.ready) throw new CodexComputerUseSetupError(status);
248
275
  return status;
@@ -273,7 +300,7 @@ async function inspectCodexComputerUse(params) {
273
300
  });
274
301
  lease.client = client;
275
302
  }
276
- if (!params.installPlugin) {
303
+ if (params.installMode === "none" && !params.refreshSharedCache) {
277
304
  if (!lease.client) return await inspectCodexComputerUseWithoutFence(params);
278
305
  return await withLeasedCodexAppServerClientStartSelectionRetry({
279
306
  lease,
@@ -340,18 +367,16 @@ async function inspectCodexComputerUse(params) {
340
367
  });
341
368
  let releaseFenceOnReturn = true;
342
369
  try {
343
- try {
344
- return await inspectCodexComputerUseWithoutFence({
345
- ...inspectionParams,
346
- releaseNativeConfigFence: release
347
- });
348
- } catch (error) {
349
- if (client && (isCodexAppServerIndeterminateRequestCancellationError(error) || isCodexAppServerIndeterminateTransportError(error) || isCodexAppServerConnectionClosedError(error))) {
350
- releaseFenceOnReturn = false;
351
- await client.closeAndRunAfterExit(release, "Computer Use config mutation");
352
- }
353
- throw error;
370
+ return await inspectCodexComputerUseWithoutFence({
371
+ ...inspectionParams,
372
+ releaseNativeConfigFence: release
373
+ });
374
+ } catch (error) {
375
+ if (client && (isCodexAppServerIndeterminateRequestCancellationError(error) || isCodexAppServerIndeterminateTransportError(error) || isCodexAppServerConnectionClosedError(error))) {
376
+ releaseFenceOnReturn = false;
377
+ await client.closeAndRunAfterExit(release, "Computer Use config mutation");
354
378
  }
379
+ throw error;
355
380
  } finally {
356
381
  if (releaseFenceOnReturn) release();
357
382
  }
@@ -361,38 +386,59 @@ async function inspectCodexComputerUse(params) {
361
386
  }
362
387
  async function inspectCodexComputerUseWithoutFence(params) {
363
388
  const request = createComputerUseRequest(params);
364
- if (params.installPlugin) {
389
+ if (params.installMode !== "none") {
365
390
  if (!resolveCodexComputerUseConfig({ pluginConfig: params.pluginConfig }).autoInstall) await prepareExplicitManagedComputerUseInstall(params);
366
- await request("experimentalFeature/enablement/set", { enablement: { plugins: true } });
367
391
  }
368
- const managedMarketplacePath = await resolveClientManagedBundledMarketplacePath(params.client, params.agentDir);
392
+ const managedMarketplacePath = await resolveClientManagedBundledMarketplacePath(params.client?.getRuntimeIdentity()?.codexHome, params.agentDir);
369
393
  const managedCodexHome = managedMarketplacePath ? params.client?.getRuntimeIdentity()?.codexHome : void 0;
370
- if (params.installPlugin && managedCodexHome) await assertNotSymlink(path.join(managedCodexHome, "config.toml"), "Codex config");
394
+ let computerUseConfig = await resolveManagedCodexComputerUseConfig(params.computerUseConfig, managedMarketplacePath);
395
+ const nativeDisableStatus = computerUseConfig !== params.computerUseConfig && params.installMode !== "explicit" ? unavailableStatus(params.computerUseConfig, "plugin_disabled", "Computer Use is disabled by native plugin policy. Run /codex computer-use install for explicit recovery, or enable computer-use@openai-bundled in native Codex config for automatic replacement.") : void 0;
396
+ if (computerUseConfig !== params.computerUseConfig) {
397
+ const nativeConfig = await request("config/read", { includeLayers: false });
398
+ if (nativeDisableStatus && isLegacyCodexComputerUsePluginDisabled(nativeConfig.config)) return nativeDisableStatus;
399
+ if (hasLegacyCodexComputerUseMcpPolicy(nativeConfig.config)) computerUseConfig = params.computerUseConfig;
400
+ }
401
+ if (params.installMode !== "none") await request("experimentalFeature/enablement/set", { enablement: { plugins: true } });
402
+ if (params.installMode !== "none" && managedCodexHome) await assertNotSymlink(path.join(managedCodexHome, "config.toml"), "Codex config");
371
403
  const marketplace = await resolveMarketplaceRef({
372
404
  request,
373
- config: params.computerUseConfig,
374
- allowAdd: params.installPlugin,
405
+ config: computerUseConfig,
406
+ allowAdd: params.installMode !== "none",
375
407
  signal: params.signal,
376
408
  defaultBundledMarketplacePath: params.defaultBundledMarketplacePath ?? managedMarketplacePath,
377
409
  defaultBundledMarketplacePathCandidates: params.defaultBundledMarketplacePathCandidates,
378
410
  managedCodexHome
379
411
  });
380
- if (!marketplace.marketplace) return unavailableStatus(params.computerUseConfig, "marketplace_missing", marketplace.message ?? `No Codex marketplace containing ${params.computerUseConfig.pluginName} is registered. Configure computerUse.marketplaceSource or computerUse.marketplacePath, then run /codex computer-use install.`);
412
+ if (!marketplace.marketplace) return unavailableStatus(computerUseConfig, "marketplace_missing", marketplace.message ?? `No Codex marketplace containing ${computerUseConfig.pluginName} is registered. Configure computerUse.marketplaceSource or computerUse.marketplacePath, then run /codex computer-use install.`);
381
413
  const pluginInspection = await ensureComputerUsePlugin({
382
414
  request,
383
- config: params.computerUseConfig,
415
+ config: computerUseConfig,
384
416
  marketplace: marketplace.marketplace,
385
- installPlugin: params.installPlugin
417
+ nativeDisableStatus,
418
+ installPlugin: params.installMode !== "none"
386
419
  });
387
420
  if (!pluginInspection.ok) return pluginInspection.status;
421
+ if (params.refreshSharedCache && computerUseConfig !== params.computerUseConfig && managedCodexHome && managedMarketplacePath && params.agentDir && params.client) {
422
+ const client = params.client;
423
+ await ensureCodexComputerUseSharedPluginCache({
424
+ codexHome: managedCodexHome,
425
+ ownershipRoot: params.agentDir,
426
+ bundledMarketplacePath: managedMarketplacePath,
427
+ config: computerUseConfig,
428
+ assertCurrent: () => {
429
+ params.assertCurrent?.();
430
+ assertCodexAppServerClientStartSelectionCurrent({ client });
431
+ }
432
+ });
433
+ }
388
434
  return await readComputerUseTools({
389
435
  request,
390
436
  client: params.client,
391
437
  signal: params.signal,
392
- config: params.computerUseConfig,
438
+ config: computerUseConfig,
393
439
  plugin: pluginInspection.plugin,
394
440
  runLiveTest: params.runLiveTest,
395
- installPlugin: params.installPlugin,
441
+ installPlugin: params.installMode !== "none",
396
442
  releaseNativeConfigFence: params.releaseNativeConfigFence
397
443
  });
398
444
  }
@@ -431,7 +477,7 @@ async function resolveExplicitManagedComputerUseInstallContext(params) {
431
477
  const desktopGeneration = readCodexAppServerClientDesktopGeneration(params.client);
432
478
  if (!desktopGeneration) throw new Error("Codex Computer Use install requires a desktop-generation-bound client; reconnect and retry.");
433
479
  const expectedHome = resolveCodexAppServerHomeDir(params.agentDir);
434
- const [actualRealHome, expectedRealHome] = await Promise.all([fs$1.realpath(codexHome).catch(() => void 0), fs$1.realpath(expectedHome).catch(() => void 0)]);
480
+ const [actualRealHome, expectedRealHome] = await Promise.all([fs.realpath(codexHome).catch(() => void 0), fs.realpath(expectedHome).catch(() => void 0)]);
435
481
  if (!actualRealHome || actualRealHome !== expectedRealHome) return;
436
482
  return {
437
483
  client: params.client,
@@ -441,29 +487,18 @@ async function resolveExplicitManagedComputerUseInstallContext(params) {
441
487
  desktopGeneration
442
488
  };
443
489
  }
444
- async function resolveClientManagedBundledMarketplacePath(client, agentDir) {
445
- const codexHome = client?.getRuntimeIdentity()?.codexHome;
446
- if (!codexHome || !agentDir) return;
447
- const [actualRealHome, expectedRealHome] = await Promise.all([fs$1.realpath(codexHome).catch(() => void 0), fs$1.realpath(resolveCodexAppServerHomeDir(agentDir)).catch(() => void 0)]);
448
- if (!actualRealHome || actualRealHome !== expectedRealHome) return;
449
- const managedPath = resolveCodexManagedBundledMarketplacePath(codexHome);
450
- return existsSync(managedPath) ? managedPath : void 0;
451
- }
452
490
  async function ensureComputerUsePlugin(params) {
453
491
  let plugin = await readComputerUsePlugin(params.request, params.marketplace, params.config.pluginName);
454
- if (!plugin.summary.installed || !plugin.summary.enabled) {
455
- if (!params.installPlugin) return {
492
+ if (params.nativeDisableStatus) {
493
+ const nativeConfig = await params.request("config/read", { includeLayers: false });
494
+ if (isLegacyCodexComputerUsePluginDisabled(nativeConfig.config)) return {
456
495
  ok: false,
457
- status: statusFromPlugin({
458
- config: params.config,
459
- plugin,
460
- tools: [],
461
- reason: pluginSetupReason(plugin),
462
- message: pluginSetupMessage(params.config, plugin)
463
- })
496
+ status: params.nativeDisableStatus
464
497
  };
498
+ }
499
+ if (params.installPlugin && (!plugin.summary.installed || !plugin.summary.enabled)) {
465
500
  await params.request("plugin/install", pluginRequestParams(params.marketplace, params.config.pluginName));
466
- await reloadMcpServers(params.request);
501
+ await params.request("config/mcpServer/reload", void 0);
467
502
  plugin = await readComputerUsePlugin(params.request, params.marketplace, params.config.pluginName);
468
503
  }
469
504
  if (!plugin.summary.installed || !plugin.summary.enabled) return {
@@ -472,8 +507,8 @@ async function ensureComputerUsePlugin(params) {
472
507
  config: params.config,
473
508
  plugin,
474
509
  tools: [],
475
- reason: pluginSetupReason(plugin),
476
- message: pluginSetupMessage(params.config, plugin)
510
+ reason: plugin.summary.installed ? "plugin_disabled" : "plugin_not_installed",
511
+ message: plugin.summary.installed ? `Computer Use is installed, but the ${params.config.pluginName} plugin is disabled. Run /codex computer-use install or enable computerUse.autoInstall to re-enable it.` : "Computer Use is available but not installed. Run /codex computer-use install or enable computerUse.autoInstall."
477
512
  })
478
513
  };
479
514
  return {
@@ -485,7 +520,7 @@ async function readComputerUseTools(params) {
485
520
  let server = await readMcpServerStatus(params.request, params.config.mcpServerName);
486
521
  let tools = Object.keys(server?.tools ?? {}).toSorted();
487
522
  if ((!server || tools.length === 0) && params.installPlugin) {
488
- await reloadMcpServers(params.request);
523
+ await params.request("config/mcpServer/reload", void 0);
489
524
  server = await readMcpServerStatus(params.request, params.config.mcpServerName);
490
525
  tools = Object.keys(server?.tools ?? {}).toSorted();
491
526
  }
@@ -605,11 +640,6 @@ function blockUnsafeAutoInstallStatus(config) {
605
640
  function shouldAddBundledComputerUseMarketplace(params) {
606
641
  return params.allowAdd && !params.config.marketplaceSource && !params.config.marketplacePath && !params.config.marketplaceName && Boolean(resolveBundledComputerUseMarketplacePath(params));
607
642
  }
608
- function resolveBundledComputerUseMarketplacePath(params) {
609
- if (params.defaultBundledMarketplacePath) return existsSync(params.defaultBundledMarketplacePath) ? params.defaultBundledMarketplacePath : void 0;
610
- if (!params.defaultBundledMarketplacePathCandidates) return;
611
- return resolveFirstExistingMacOSDesktopCodexBundledMarketplacePath({ candidates: params.defaultBundledMarketplacePathCandidates });
612
- }
613
643
  function findComputerUseMarketplaces(listed, pluginName) {
614
644
  return listed.marketplaces.flatMap((marketplace) => {
615
645
  const plugin = marketplace.plugins.find((candidate) => candidate.name === pluginName || candidate.id === pluginName || candidate.id === `${pluginName}@${marketplace.name}`);
@@ -674,9 +704,6 @@ async function readMcpServerStatus(request, serverName) {
674
704
  cursor = response.nextCursor;
675
705
  } while (cursor);
676
706
  }
677
- async function reloadMcpServers(request) {
678
- await request("config/mcpServer/reload", void 0);
679
- }
680
707
  function pluginRequestParams(marketplace, pluginName) {
681
708
  return marketplace.kind === "local" ? {
682
709
  marketplacePath: marketplace.path,
@@ -686,13 +713,6 @@ function pluginRequestParams(marketplace, pluginName) {
686
713
  pluginName: marketplace.remotePluginId
687
714
  };
688
715
  }
689
- function pluginSetupReason(plugin) {
690
- return plugin.summary.installed ? "plugin_disabled" : "plugin_not_installed";
691
- }
692
- function pluginSetupMessage(config, plugin) {
693
- if (!plugin.summary.installed) return "Computer Use is available but not installed. Run /codex computer-use install or enable computerUse.autoInstall.";
694
- return `Computer Use is installed, but the ${config.pluginName} plugin is disabled. Run /codex computer-use install or enable computerUse.autoInstall to re-enable it.`;
695
- }
696
716
  function statusFromPlugin(params) {
697
717
  return {
698
718
  enabled: true,
@@ -709,99 +729,26 @@ function statusFromPlugin(params) {
709
729
  installation: installationStatusFromPlugin(params.plugin, params.message),
710
730
  exposure: exposureStatusFromTools(params.config, params.tools),
711
731
  liveTest: skippedLiveTestStatus(params.config, "Computer Use live test was not run."),
712
- warnings: pluginWarnings(params.plugin),
732
+ warnings: params.plugin.summary.source?.type === "remote" ? ["Computer Use plugin is resolved from a remote marketplace; live local bundles are preferred."] : [],
713
733
  message: params.message
714
734
  };
715
735
  }
716
- function disabledStatus(config) {
717
- return {
718
- enabled: false,
719
- ready: false,
720
- reason: "disabled",
721
- installed: false,
722
- pluginEnabled: false,
723
- mcpServerAvailable: false,
724
- pluginName: config.pluginName,
725
- mcpServerName: config.mcpServerName,
726
- tools: [],
727
- installation: {
728
- status: "disabled",
729
- ok: false,
730
- message: "Computer Use is disabled."
731
- },
732
- exposure: {
733
- status: "skipped",
734
- ok: false,
735
- message: "MCP exposure was not checked because Computer Use is disabled."
736
- },
737
- liveTest: skippedLiveTestStatus(config, "Computer Use live test was not run because Computer Use is disabled."),
738
- warnings: [],
739
- message: "Computer Use is disabled."
740
- };
741
- }
742
- function unavailableStatus(config, reason, message) {
743
- return {
744
- enabled: true,
745
- ready: false,
746
- reason,
747
- installed: false,
748
- pluginEnabled: false,
749
- mcpServerAvailable: false,
750
- pluginName: config.pluginName,
751
- mcpServerName: config.mcpServerName,
752
- ...config.marketplaceName ? { marketplaceName: config.marketplaceName } : {},
753
- ...config.marketplacePath ? { marketplacePath: config.marketplacePath } : {},
754
- tools: [],
755
- installation: {
756
- status: reason === "marketplace_missing" ? "marketplace_missing" : "not_installed",
757
- ok: false,
758
- message
759
- },
760
- exposure: {
761
- status: "skipped",
762
- ok: false,
763
- message: "MCP exposure was not checked because Computer Use installation is not ready."
764
- },
765
- liveTest: skippedLiveTestStatus(config, "Computer Use live test was not run because installation is not ready."),
766
- warnings: [],
767
- message
768
- };
769
- }
770
736
  function installationStatusFromPlugin(plugin, message) {
771
- if (!plugin.summary.installed) return {
772
- status: "not_installed",
773
- ok: false,
774
- message
775
- };
776
- if (!plugin.summary.enabled) return {
777
- status: "installed_disabled",
778
- ok: false,
779
- message
780
- };
737
+ const installed = plugin.summary.installed && plugin.summary.enabled;
781
738
  return {
782
- status: "installed",
783
- ok: true,
784
- message: "Computer Use plugin is installed and enabled."
739
+ status: !plugin.summary.installed ? "not_installed" : installed ? "installed" : "installed_disabled",
740
+ ok: installed,
741
+ message: installed ? "Computer Use plugin is installed and enabled." : message
785
742
  };
786
743
  }
787
744
  function exposureStatusFromTools(config, tools) {
788
- if (tools.length === 0) return {
789
- status: "missing",
790
- ok: false,
791
- message: `Computer Use MCP server ${config.mcpServerName} is not exposed.`
792
- };
745
+ const available = tools.length > 0;
793
746
  return {
794
- status: "available",
795
- ok: true,
796
- message: `Computer Use MCP server ${config.mcpServerName} exposes ${tools.length} tools.`
747
+ status: available ? "available" : "missing",
748
+ ok: available,
749
+ message: available ? `Computer Use MCP server ${config.mcpServerName} exposes ${tools.length} tools.` : `Computer Use MCP server ${config.mcpServerName} is not exposed.`
797
750
  };
798
751
  }
799
- function pluginWarnings(plugin) {
800
- const warnings = [];
801
- const source = plugin.summary.source;
802
- if (source && typeof source === "object" && "type" in source && source.type === "remote") warnings.push("Computer Use plugin is resolved from a remote marketplace; live local bundles are preferred.");
803
- return warnings;
804
- }
805
752
  function resolveComputerUseConfig(params) {
806
753
  const overrides = params.forceEnable ? {
807
754
  ...params.overrides,
@@ -815,7 +762,6 @@ function resolveComputerUseConfig(params) {
815
762
  //#endregion
816
763
  //#region extensions/codex/src/app-server/plugin-metadata-cache.ts
817
764
  const CODEX_PLUGIN_METADATA_CACHE_TTL_MS = 36e5;
818
- /** Process-local plugin metadata cache with coalesced loads per query. */
819
765
  var CodexPluginMetadataCache = class {
820
766
  constructor(nowMs = Date.now) {
821
767
  this.nowMs = nowMs;
@@ -824,7 +770,6 @@ var CodexPluginMetadataCache = class {
824
770
  this.generations = /* @__PURE__ */ new Map();
825
771
  this.clearGeneration = 0;
826
772
  }
827
- /** Returns a fresh cached snapshot without issuing a request. */
828
773
  read(appCacheKey, queryKind, requestParams, catalogScope) {
829
774
  const entryKey = buildMetadataCacheEntryKey(appCacheKey, queryKind, requestParams, catalogScope);
830
775
  const entry = this.entries.get(entryKey);
@@ -857,7 +802,7 @@ var CodexPluginMetadataCache = class {
857
802
  queryKind: params.queryKind,
858
803
  response
859
804
  };
860
- if (generation === (this.generations.get(params.appCacheKey) ?? 0) && clearGeneration === this.clearGeneration && !hasMarketplaceLoadErrors(response) && (params.cacheable?.(response) ?? true)) this.entries.set(entryKey, {
805
+ if (generation === (this.generations.get(params.appCacheKey) ?? 0) && clearGeneration === this.clearGeneration && response.marketplaceLoadErrors.length === 0 && (params.cacheable?.(response) ?? true)) this.entries.set(entryKey, {
861
806
  snapshot,
862
807
  expiresAtMs: this.nowMs() + CODEX_PLUGIN_METADATA_CACHE_TTL_MS
863
808
  });
@@ -873,7 +818,6 @@ var CodexPluginMetadataCache = class {
873
818
  if (this.inFlight.get(entryKey)?.promise === promise) this.inFlight.delete(entryKey);
874
819
  }
875
820
  }
876
- /** Invalidates all plugin metadata queries for one app-server runtime. */
877
821
  invalidate(appCacheKey) {
878
822
  this.generations.set(appCacheKey, (this.generations.get(appCacheKey) ?? 0) + 1);
879
823
  for (const [entryKey, entry] of this.entries) if (entry.snapshot.appCacheKey === appCacheKey) this.entries.delete(entryKey);
@@ -887,11 +831,7 @@ var CodexPluginMetadataCache = class {
887
831
  this.inFlight.clear();
888
832
  }
889
833
  };
890
- /** Shared plugin metadata cache used by Codex app-server runtime paths. */
891
834
  const defaultCodexPluginMetadataCache = new CodexPluginMetadataCache();
892
- function hasMarketplaceLoadErrors(response) {
893
- return response.marketplaceLoadErrors.length > 0;
894
- }
895
835
  function buildMetadataCacheEntryKey(appCacheKey, queryKind, requestParams, catalogScope) {
896
836
  if (queryKind !== "installed") {
897
837
  const listParams = requestParams;
@@ -913,4 +853,4 @@ function buildMetadataCacheEntryKey(appCacheKey, queryKind, requestParams, catal
913
853
  ]);
914
854
  }
915
855
  //#endregion
916
- export { runCodexComputerUseLiveTest as a, readCodexComputerUseStatus as i, ensureCodexComputerUse as n, installCodexComputerUse as r, defaultCodexPluginMetadataCache as t };
856
+ export { createComputerUseRequest as a, readCodexComputerUseStatus as i, ensureCodexComputerUse as n, runCodexComputerUseLiveTest as o, installCodexComputerUse as r, defaultCodexPluginMetadataCache as t };
@@ -1,10 +1,5 @@
1
+ import { t as isOnlyMigrationKind } from "./scope-DOC1Xjc8.mjs";
1
2
  //#region extensions/codex/src/migration/provider.ts
2
- function isMemoryOnlyMigration(ctx) {
3
- return Boolean(ctx.itemKinds && ctx.itemKinds.length > 0 && ctx.itemKinds.every((kind) => kind === "memory"));
4
- }
5
- function isAuthOnlyMigration(ctx) {
6
- return Boolean(ctx.itemKinds && ctx.itemKinds.length > 0 && ctx.itemKinds.every((kind) => kind === "auth"));
7
- }
8
3
  function buildCodexMigrationProvider(params = {}) {
9
4
  return {
10
5
  id: "codex",
@@ -16,13 +11,15 @@ function buildCodexMigrationProvider(params = {}) {
16
11
  ].join(" "),
17
12
  supportedItemKinds: ["memory", "auth"],
18
13
  async detect(ctx) {
19
- const { discoverCodexSource, hasCodexSource } = await import("./source-CUzJq5WN.mjs").then((n) => n.a);
14
+ const { discoverCodexSource, hasCodexSource } = await import("./source-CJis_1EF.mjs").then((n) => n.a);
15
+ const memoryOnly = isOnlyMigrationKind(ctx, "memory");
16
+ const authOnly = isOnlyMigrationKind(ctx, "auth");
20
17
  const source = await discoverCodexSource({
21
18
  input: ctx.source,
22
- memoryOnly: isMemoryOnlyMigration(ctx),
23
- authOnly: isAuthOnlyMigration(ctx)
19
+ memoryOnly,
20
+ authOnly
24
21
  });
25
- const found = isMemoryOnlyMigration(ctx) ? source.memoryFiles.length > 0 : isAuthOnlyMigration(ctx) ? Boolean(source.authPath) : hasCodexSource(source);
22
+ const found = memoryOnly ? source.memoryFiles.length > 0 : authOnly ? Boolean(source.authPath) : hasCodexSource(source);
26
23
  return {
27
24
  found,
28
25
  source: source.root,
@@ -32,16 +29,16 @@ function buildCodexMigrationProvider(params = {}) {
32
29
  };
33
30
  },
34
31
  async plan(ctx) {
35
- const { buildCodexMigrationPlan } = await import("./plan-CN3VwfNU.mjs");
32
+ const { buildCodexMigrationPlan } = await import("./plan-DPdMk1Oy.mjs");
36
33
  return buildCodexMigrationPlan(ctx);
37
34
  },
38
35
  deferredApply: { retrySafe: true },
39
36
  prepareApply(ctx) {
40
- if (isMemoryOnlyMigration(ctx) || isAuthOnlyMigration(ctx)) return;
41
- return import("./apply-DDOi8uNx.mjs").then(({ prepareTargetCodexAppServer }) => prepareTargetCodexAppServer(ctx));
37
+ if (isOnlyMigrationKind(ctx, "memory") || isOnlyMigrationKind(ctx, "auth")) return;
38
+ return import("./apply-Cqb-YoCS.mjs").then(({ prepareTargetCodexAppServer }) => prepareTargetCodexAppServer(ctx));
42
39
  },
43
40
  async apply(ctx, plan) {
44
- const { applyCodexMigrationPlan } = await import("./apply-DDOi8uNx.mjs");
41
+ const { applyCodexMigrationPlan } = await import("./apply-Cqb-YoCS.mjs");
45
42
  return await applyCodexMigrationPlan({
46
43
  ctx,
47
44
  plan,
@@ -1,5 +1,5 @@
1
- import { h as releaseLeasedSharedCodexAppServerClient } from "./shared-client-DA4VR4Eb.mjs";
2
- import { ut as normalizeCodexDynamicToolName } from "./thread-requests-BLvGkP2R.mjs";
1
+ import { h as releaseLeasedSharedCodexAppServerClient } from "./shared-client-CJCTeFpQ.mjs";
2
+ import { dt as normalizeCodexDynamicToolName } from "./thread-requests-OWGOiDaV.mjs";
3
3
  import { pinExecToolTarget } from "openclaw/plugin-sdk/codex-mcp-projection";
4
4
  import { loadNodeExecAvailability } from "openclaw/plugin-sdk/node-selection-runtime";
5
5
  //#region extensions/codex/src/app-server/shell-dynamic-tools.ts
@@ -7,7 +7,6 @@ const CODEX_NODE_EXEC_DYNAMIC_TOOL_NAME = "node_exec";
7
7
  const CODEX_GATEWAY_EXEC_DYNAMIC_TOOL_NAME = "gateway_exec";
8
8
  const CODEX_GATEWAY_PROCESS_DYNAMIC_TOOL_NAME = "gateway_process";
9
9
  const PROCESS_FOLLOWUP_TEXT = "Use process (list/poll/log/write/send-keys/submit/paste/kill/clear/remove) for follow-up.";
10
- /** Returns true when plugin config explicitly removes any named dynamic tool. */
11
10
  function isCodexDynamicToolExcluded(config, names) {
12
11
  const normalizedNames = new Set(names.map((name) => normalizeCodexDynamicToolName(name)));
13
12
  return (config.codexDynamicToolsExclude ?? []).some((name) => normalizedNames.has(normalizeCodexDynamicToolName(name)));
@@ -21,18 +20,11 @@ async function createNodeExecAliasDynamicTool(execTool, node, discoverySignal, a
21
20
  host: "node",
22
21
  ...pinnedNode ? { node: pinnedNode } : {}
23
22
  });
24
- const execute = async (toolCallId, args, signal, onUpdate) => {
25
- const result = await pinnedTool.execute(toolCallId, args, signal, onUpdate);
26
- return {
27
- ...result,
28
- content: result.content.map((item) => item.type === "text" ? Object.assign({}, item, { text: item.text.replace(PROCESS_FOLLOWUP_TEXT, "Remote-node background follow-up is unavailable. Wait for the command to complete.") }) : item)
29
- };
30
- };
31
23
  return {
32
24
  ...pinnedTool,
33
25
  name: CODEX_NODE_EXEC_DYNAMIC_TOOL_NAME,
34
26
  description: pinnedNode ? "Run a shell command to completion on the OpenClaw configured remote node for this session. This tool always uses OpenClaw host=node internally and follows the existing node exec approval and allowlist policy. Remote-node background follow-up is unavailable. Use Codex's native shell for local app-server work when it is available." : "Run a shell command to completion on an OpenClaw remote node. The sole connected node that can execute commands is selected automatically; select by name or id when several can. This tool always uses OpenClaw host=node internally and follows the existing node exec approval and allowlist policy. Remote-node background follow-up is unavailable. Use Codex's native shell for local app-server work when it is available.",
35
- execute
27
+ execute: withProcessFollowupText(pinnedTool, "Remote-node background follow-up is unavailable. Wait for the command to complete.")
36
28
  };
37
29
  }
38
30
  function createGatewayExecProjection(createProjection, execTool, params) {
@@ -56,13 +48,16 @@ function createSandboxExecProjection(execTool) {
56
48
  ...execTool,
57
49
  name: "sandbox_exec",
58
50
  description: "Run a shell command through OpenClaw's configured sandbox backend for this session. Use when OpenClaw sandboxing is active or when a command must execute in the sandbox backend, such as an SSH-backed sandbox or Docker container-path bind layout. Use Codex's native shell only when no OpenClaw sandbox is active and native Code Mode is available.",
59
- execute: async (toolCallId, args, signal, onUpdate) => {
60
- const result = await execTool.execute(toolCallId, args, signal, onUpdate);
61
- return {
62
- ...result,
63
- content: result.content.map((item) => item.type === "text" ? Object.assign({}, item, { text: item.text.replace(PROCESS_FOLLOWUP_TEXT, "Use sandbox_process (list/poll/log/write/send-keys/submit/paste/kill/clear/remove) for follow-up.") }) : item)
64
- };
65
- }
51
+ execute: withProcessFollowupText(execTool, "Use sandbox_process (list/poll/log/write/send-keys/submit/paste/kill/clear/remove) for follow-up.")
52
+ };
53
+ }
54
+ function withProcessFollowupText(tool, followupText) {
55
+ return async (toolCallId, args, signal, onUpdate) => {
56
+ const result = await tool.execute(toolCallId, args, signal, onUpdate);
57
+ return {
58
+ ...result,
59
+ content: result.content.map((item) => item.type === "text" ? Object.assign({}, item, { text: item.text.replace(PROCESS_FOLLOWUP_TEXT, followupText) }) : item)
60
+ };
66
61
  };
67
62
  }
68
63
  function createSandboxProcessProjection(processTool) {