oh-my-codex 0.21.2 → 0.21.3

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 (53) hide show
  1. package/Cargo.toml +1 -1
  2. package/dist/cli/__tests__/index.test.js +21 -2
  3. package/dist/cli/__tests__/index.test.js.map +1 -1
  4. package/dist/cli/index.d.ts +5 -1
  5. package/dist/cli/index.d.ts.map +1 -1
  6. package/dist/cli/index.js +32 -4
  7. package/dist/cli/index.js.map +1 -1
  8. package/dist/scripts/notify-hook/team-leader-nudge.d.ts.map +1 -1
  9. package/dist/scripts/notify-hook/team-leader-nudge.js +6 -2
  10. package/dist/scripts/notify-hook/team-leader-nudge.js.map +1 -1
  11. package/dist/scripts/notify-hook/team-worker-stop.d.ts.map +1 -1
  12. package/dist/scripts/notify-hook/team-worker-stop.js +6 -2
  13. package/dist/scripts/notify-hook/team-worker-stop.js.map +1 -1
  14. package/dist/scripts/notify-hook/team-worker.d.ts.map +1 -1
  15. package/dist/scripts/notify-hook/team-worker.js +10 -2
  16. package/dist/scripts/notify-hook/team-worker.js.map +1 -1
  17. package/dist/team/__tests__/notice-ledger.test.js +66 -5
  18. package/dist/team/__tests__/notice-ledger.test.js.map +1 -1
  19. package/dist/team/__tests__/runtime.test.js +83 -1
  20. package/dist/team/__tests__/runtime.test.js.map +1 -1
  21. package/dist/team/__tests__/shutdown-fallback.test.js +11 -1
  22. package/dist/team/__tests__/shutdown-fallback.test.js.map +1 -1
  23. package/dist/team/__tests__/state.test.js +195 -2
  24. package/dist/team/__tests__/state.test.js.map +1 -1
  25. package/dist/team/__tests__/team-ops-contract.test.js +1 -0
  26. package/dist/team/__tests__/team-ops-contract.test.js.map +1 -1
  27. package/dist/team/__tests__/worker-runtime-identity.test.js +11 -1
  28. package/dist/team/__tests__/worker-runtime-identity.test.js.map +1 -1
  29. package/dist/team/mcp-comm.d.ts.map +1 -1
  30. package/dist/team/mcp-comm.js +130 -125
  31. package/dist/team/mcp-comm.js.map +1 -1
  32. package/dist/team/notice-ledger.d.ts +5 -0
  33. package/dist/team/notice-ledger.d.ts.map +1 -1
  34. package/dist/team/notice-ledger.js +82 -4
  35. package/dist/team/notice-ledger.js.map +1 -1
  36. package/dist/team/runtime.d.ts.map +1 -1
  37. package/dist/team/runtime.js +44 -13
  38. package/dist/team/runtime.js.map +1 -1
  39. package/dist/team/state/mailbox.js +22 -22
  40. package/dist/team/state/mailbox.js.map +1 -1
  41. package/dist/team/state.d.ts +2 -0
  42. package/dist/team/state.d.ts.map +1 -1
  43. package/dist/team/state.js +100 -4
  44. package/dist/team/state.js.map +1 -1
  45. package/dist/team/team-ops.d.ts +1 -0
  46. package/dist/team/team-ops.d.ts.map +1 -1
  47. package/dist/team/team-ops.js +1 -0
  48. package/dist/team/team-ops.js.map +1 -1
  49. package/package.json +1 -1
  50. package/plugins/oh-my-codex/.codex-plugin/plugin.json +1 -1
  51. package/src/scripts/notify-hook/team-leader-nudge.ts +6 -2
  52. package/src/scripts/notify-hook/team-worker-stop.ts +6 -2
  53. package/src/scripts/notify-hook/team-worker.ts +10 -2
package/Cargo.toml CHANGED
@@ -11,7 +11,7 @@ resolver = "2"
11
11
 
12
12
  [workspace.package]
13
13
 
14
- version = "0.21.2"
14
+ version = "0.21.3"
15
15
 
16
16
  edition = "2021"
17
17
  rust-version = "1.73"
@@ -7,7 +7,7 @@ import { delimiter, dirname, join } from "node:path";
7
7
  import { tmpdir } from "node:os";
8
8
  import { fileURLToPath } from "node:url";
9
9
  import TOML from "@iarna/toml";
10
- import { HELP, normalizeCodexLaunchArgs, buildTmuxShellCommand, buildTmuxPaneCommand, shouldSourceTmuxPaneShellRc, buildWindowsPromptCommand, buildWindowsDetachedChildCommand, buildTmuxSessionName, resolveCliInvocation, parseResumeCodexHomeSelection, isResumeCodexLaunch, CODEX_GLOBAL_OPTIONS_WITH_SPLIT_VALUE, isCodexVersionRequest, resolveUpdateChannelArg, commandOwnsLocalHelp, resolveCodexLaunchPolicy, resolveEffectiveLeaderLaunchPolicyOverride, resolveEnvLaunchPolicyOverride, resolveLeaderLaunchPolicyOverride, classifyCodexExecFailure, resolveSignalExitCode, parseTmuxPaneSnapshot, findHudWatchPaneIds, buildHudPaneCleanupTargets, readTopLevelTomlString, upsertTopLevelTomlString, collectInheritableTeamWorkerArgs, resolveTeamWorkerLaunchArgsEnv, injectModelInstructionsBypassArgs, resolveWorkerSparkModel, resolveSetupInstallModeArg, resolveSetupMcpModeArg, resolveSetupScopeArg, resolveSetupTeamModeArg, resolveSetupAgentsMergePolicyArg, resolveLaunchConfigRepairOptions, readPersistedSetupPreferences, readPersistedSetupScope, resolveCodexConfigPathForLaunch, resolveCodexHomeForLaunch, resolveProjectLocalCodexHomeForLaunch, shouldAutoIsolateMadmaxLaunch, createMadmaxIsolatedRoot, buildMadmaxDetachedLaunchContextKey, withMadmaxDetachedContextLock, executeDetachedLaunchStateMachine, isExactDetachedFinalization, resolveOmxRootForLaunch, resolveDisposableWorktreeOmxRootForLaunch, prepareCodexHomeForLaunch, prepareRuntimeCodexHomeForProjectLaunch, historyDestinationMode, acquireHistoryPersistenceLock, releaseHistoryPersistenceLock, captureMadmaxWorktreeRuntimeContext, persistProjectLaunchRuntimeAuthState, persistProjectLaunchRuntimeProjectTrustState, cleanupRuntimeCodexHome, runtimeCodexHomePath, buildDetachedSessionBootstrapSteps, buildDetachedTmuxSessionName, buildDetachedSessionFinalizeSteps, shouldAttachDetachedTmuxSession, buildDetachedSessionRollbackSteps, detectDetachedSessionWindowIndex, resolveNotifyTempContract, buildNotifyTempStartupMessages, buildNotifyFallbackWatcherEnv, shouldEnableNotifyFallbackWatcher, reapStaleNotifyFallbackWatcher, cleanupLaunchOrphanedMcpProcesses, reapPostLaunchOrphanedMcpProcesses, cleanupPostLaunchModeStateFiles, resolveBackgroundHelperLaunchMode, shouldDetachBackgroundHelper, resolveNotifyFallbackWatcherScript, resolveHookDerivedWatcherScript, resolveNotifyHookScript, acquireTmuxExtendedKeysLease, resolveNativeSessionName, releaseTmuxExtendedKeysLease, withTmuxExtendedKeys, serializeDetachedSessionParentEnv, buildInsideTmuxHudHookEnv, registerInsideTmuxHudResizeHook, buildDetachedHudHookEnv, registerDetachedHudLayoutReconcileHook, ensureOmxRuntimeCommandShim, omxRuntimeCommandShimPath, prependOmxRuntimeCommandShimToEnv, CODEX_SQLITE_HOME_ENV, DETACHED_TMUX_HISTORY_LIMIT, isExistingTmuxWindowTooCrampedForLaunchHud, guardDetachedHudDeferredMutation, DETACHED_LAUNCH_CONTROL_PLANE_KEYS, buildDetachedLaunchControlPlane, } from "../index.js";
10
+ import { HELP, normalizeCodexLaunchArgs, buildTmuxShellCommand, buildTmuxPaneCommand, shouldSourceTmuxPaneShellRc, buildWindowsPromptCommand, buildWindowsDetachedChildCommand, buildTmuxSessionName, resolveCliInvocation, parseResumeCodexHomeSelection, isResumeCodexLaunch, CODEX_GLOBAL_OPTIONS_WITH_SPLIT_VALUE, isCodexVersionRequest, resolveUpdateChannelArg, commandOwnsLocalHelp, resolveCodexLaunchPolicy, resolveEffectiveLeaderLaunchPolicyOverride, resolveEnvLaunchPolicyOverride, resolveLeaderLaunchPolicyOverride, classifyCodexExecFailure, resolveSignalExitCode, parseTmuxPaneSnapshot, findHudWatchPaneIds, buildHudPaneCleanupTargets, readTopLevelTomlString, upsertTopLevelTomlString, collectInheritableTeamWorkerArgs, resolveTeamWorkerLaunchArgsEnv, injectModelInstructionsBypassArgs, resolveWorkerSparkModel, resolveSetupInstallModeArg, resolveSetupMcpModeArg, resolveSetupScopeArg, resolveSetupTeamModeArg, resolveSetupAgentsMergePolicyArg, resolveLaunchConfigRepairOptions, readPersistedSetupPreferences, readPersistedSetupScope, resolveCodexConfigPathForLaunch, resolveCodexHomeForLaunch, resolveProjectLocalCodexHomeForLaunch, shouldAutoIsolateMadmaxLaunch, createMadmaxIsolatedRoot, buildMadmaxDetachedLaunchContextKey, withMadmaxDetachedContextLock, executeDetachedLaunchStateMachine, isExactDetachedFinalization, resolveOmxRootForLaunch, resolveDisposableWorktreeOmxRootForLaunch, prepareCodexHomeForLaunch, prepareRuntimeCodexHomeForProjectLaunch, historyDestinationMode, acquireHistoryPersistenceLock, releaseHistoryPersistenceLock, captureMadmaxWorktreeRuntimeContext, persistProjectLaunchRuntimeAuthState, persistProjectLaunchRuntimeProjectTrustState, cleanupRuntimeCodexHome, runtimeCodexHomePath, buildDetachedSessionBootstrapSteps, buildDetachedTmuxSessionName, buildDetachedSessionFinalizeSteps, shouldAttachDetachedTmuxSession, buildDetachedSessionRollbackSteps, detectDetachedSessionWindowIndex, resolveNotifyTempContract, buildNotifyTempStartupMessages, buildNotifyFallbackWatcherEnv, shouldEnableNotifyFallbackWatcher, reapStaleNotifyFallbackWatcher, cleanupLaunchOrphanedMcpProcesses, reapPostLaunchOrphanedMcpProcesses, cleanupPostLaunchModeStateFiles, resolveBackgroundHelperLaunchMode, shouldDetachBackgroundHelper, resolveNotifyFallbackWatcherScript, resolveHookDerivedWatcherScript, resolveNotifyHookScript, acquireTmuxExtendedKeysLease, resolveNativeSessionName, releaseTmuxExtendedKeysLease, withTmuxExtendedKeys, serializeDetachedSessionParentEnv, buildInsideTmuxHudHookEnv, registerInsideTmuxHudResizeHook, buildDetachedHudHookEnv, registerDetachedHudLayoutReconcileHook, ensureOmxRuntimeCommandShim, omxRuntimeCommandShimPath, prependOmxRuntimeCommandShimToEnv, CODEX_SQLITE_HOME_ENV, DETACHED_TMUX_HISTORY_LIMIT, DETACHED_TMUX_HISTORY_LIMIT_MAX, DETACHED_TMUX_HISTORY_LIMIT_MIN, resolveDetachedTmuxHistoryLimit, isExistingTmuxWindowTooCrampedForLaunchHud, guardDetachedHudDeferredMutation, DETACHED_LAUNCH_CONTROL_PLANE_KEYS, buildDetachedLaunchControlPlane, } from "../index.js";
11
11
  import { buildResumeArgsWithPreservedFlags, stripHotswapArg } from "../../auth/hotswap.js";
12
12
  import { writeSkillActiveStateCopiesForStateDir } from '../../state/skill-active.js';
13
13
  import { mergeConfig, repairConfigIfNeeded } from "../../config/generator.js";
@@ -4325,7 +4325,7 @@ exit 0
4325
4325
  assert.equal(attachIndex > scheduleIndex, true);
4326
4326
  assert.equal(names.includes("register-resize-hook"), true);
4327
4327
  assert.equal(names.includes("reconcile-hud-resize"), true);
4328
- assert.equal(DETACHED_TMUX_HISTORY_LIMIT, 500);
4328
+ assert.equal(DETACHED_TMUX_HISTORY_LIMIT, 5000);
4329
4329
  const historyHook = steps.find((step) => step.name === "register-detached-history-prune-hook");
4330
4330
  assert.ok(historyHook);
4331
4331
  assert.deepEqual(historyHook.args.slice(0, 3), ["set-hook", "-t", "omx-demo"]);
@@ -4958,4 +4958,23 @@ describe("detached control-plane binding", () => {
4958
4958
  assert.equal(payload.parentEnv?.Omx_Notify_Fallback, "1");
4959
4959
  });
4960
4960
  });
4961
+ describe("resolveDetachedTmuxHistoryLimit (#3611)", () => {
4962
+ it("defaults to a scrollback size that holds a real transcript", () => {
4963
+ assert.equal(resolveDetachedTmuxHistoryLimit({}), DETACHED_TMUX_HISTORY_LIMIT);
4964
+ assert.equal(DETACHED_TMUX_HISTORY_LIMIT >= 5000, true);
4965
+ });
4966
+ it("honors a valid operator override", () => {
4967
+ assert.equal(resolveDetachedTmuxHistoryLimit({ OMX_TMUX_HISTORY_LIMIT: "12000" }), 12000);
4968
+ assert.equal(resolveDetachedTmuxHistoryLimit({ OMX_TMUX_HISTORY_LIMIT: " 9000 " }), 9000);
4969
+ });
4970
+ it("clamps overrides into the supported range", () => {
4971
+ assert.equal(resolveDetachedTmuxHistoryLimit({ OMX_TMUX_HISTORY_LIMIT: "0" }), DETACHED_TMUX_HISTORY_LIMIT_MIN);
4972
+ assert.equal(resolveDetachedTmuxHistoryLimit({ OMX_TMUX_HISTORY_LIMIT: "99999999" }), DETACHED_TMUX_HISTORY_LIMIT_MAX);
4973
+ });
4974
+ it("falls back to the default for unusable overrides instead of shrinking scrollback", () => {
4975
+ for (const raw of ["", "abc", "-1", "1e4", "1_000", "500.5"]) {
4976
+ assert.equal(resolveDetachedTmuxHistoryLimit({ OMX_TMUX_HISTORY_LIMIT: raw }), DETACHED_TMUX_HISTORY_LIMIT, `expected default for ${JSON.stringify(raw)}`);
4977
+ }
4978
+ });
4979
+ });
4961
4980
  //# sourceMappingURL=index.test.js.map