@codexhost/cli-linux-arm64 0.18.0-beta.4 → 0.18.0
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/README.md +1 -1
- package/app/codexhost-distribution.json +1 -1
- package/app/console-server.mjs +98 -55
- package/app/console-web.js +276 -188
- package/app/desktop-controller.mjs +283 -113
- package/app/host-runtime.mjs +2129 -1529
- package/app/plugins/antigravity/plugin.mjs +787 -303
- package/app/plugins/claude-code/plugin.mjs +85 -45
- package/app/plugins/codebuddy/plugin.mjs +99 -59
- package/app/plugins/codex-usage/plugin.mjs +85 -45
- package/app/plugins/copilot/plugin.mjs +90 -50
- package/app/plugins/cursor-cli/plugin.mjs +113 -73
- package/app/plugins/deepseek-harness/plugin.mjs +116 -76
- package/app/plugins/devin/plugin.mjs +90 -50
- package/app/plugins/grok/plugin.mjs +96 -56
- package/app/plugins/hermes/plugin.mjs +77 -37
- package/app/plugins/kimi-code/plugin.mjs +94 -54
- package/app/plugins/kiro-cli/plugin.mjs +90 -50
- package/app/plugins/omp/plugin.mjs +81 -41
- package/app/plugins/opencode/plugin.mjs +78 -38
- package/app/plugins/pi/plugin.mjs +94 -54
- package/app/plugins/qoder/plugin.mjs +106 -66
- package/app/plugins/qoder-cn/plugin.mjs +106 -66
- package/app/plugins/qwen-code/plugin.mjs +101 -61
- package/app/plugins/workbuddy/plugin.mjs +99 -59
- package/app/plugins/zcode/plugin.mjs +82 -42
- package/app/renderer-extension.js +435 -361
- package/app/web/assets/{index-D1dOzBMI.js → index-C0aXz2jD.js} +63 -63
- package/app/web/codex-agent.png +0 -0
- package/app/web/codexhost-settings.js +229 -175
- package/app/web/index.html +1 -1
- package/app/web/plugins/deepseek-ai__dsh-api-remotes/client.js +1 -1
- package/app/web/plugins/deepseek-ai__dsh-api-session-controller/client.js +61 -61
- package/app/web/plugins/deepseek-ai__dsh-client-ui-chat/client.js +8 -8
- package/app/web/plugins/deepseek-ai__dsh-client-ui-codexhost/client.js +2 -2
- package/app/web/plugins/deepseek-ai__dsh-client-ui-conversation/client.js +12 -12
- package/app/web/plugins/deepseek-ai__dsh-client-ui-permission-presets/client.js +1 -1
- package/app/web/plugins/deepseek-ai__dsh-client-ui-settings/client.js +1 -1
- package/app/web/plugins/deepseek-ai__dsh-client-ui-settings-general/client.js +3 -3
- package/app/web/plugins/deepseek-ai__dsh-client-ui-theme/client.js +1 -1
- package/app/web/plugins/deepseek-ai__dsh-client-ui-tool/client.js +18 -18
- package/app/web/plugins/deepseek-ai__dsh-client-ui-workspace/client.js +8 -8
- package/app/web/sw.js +41 -6
- package/app/web-modules/server.mjs +2079 -1201
- package/bin/codexhost +0 -0
- package/libexec/codexhost-shim +0 -0
- package/libexec/codexhost-updater +0 -0
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createRequire as __codexhostCreateRequire } from "node:module"; const require = __codexhostCreateRequire(import.meta.url);
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __export = (
|
|
3
|
+
var __export = (target2, all) => {
|
|
4
4
|
for (var name in all)
|
|
5
|
-
__defProp(
|
|
5
|
+
__defProp(target2, name, { get: all[name], enumerable: true });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
// ../../harness-broker/dist/client.js
|
|
@@ -758,8 +758,8 @@ function defineLazy(object2, key, getter) {
|
|
|
758
758
|
function objectClone(obj) {
|
|
759
759
|
return Object.create(Object.getPrototypeOf(obj), Object.getOwnPropertyDescriptors(obj));
|
|
760
760
|
}
|
|
761
|
-
function assignProp(
|
|
762
|
-
Object.defineProperty(
|
|
761
|
+
function assignProp(target2, prop, value) {
|
|
762
|
+
Object.defineProperty(target2, prop, {
|
|
763
763
|
value,
|
|
764
764
|
writable: true,
|
|
765
765
|
enumerable: true,
|
|
@@ -942,35 +942,35 @@ function normalizeParams(_params) {
|
|
|
942
942
|
return params;
|
|
943
943
|
}
|
|
944
944
|
function createTransparentProxy(getter) {
|
|
945
|
-
let
|
|
945
|
+
let target2;
|
|
946
946
|
return new Proxy({}, {
|
|
947
947
|
get(_3, prop, receiver) {
|
|
948
|
-
|
|
949
|
-
return Reflect.get(
|
|
948
|
+
target2 ?? (target2 = getter());
|
|
949
|
+
return Reflect.get(target2, prop, receiver);
|
|
950
950
|
},
|
|
951
951
|
set(_3, prop, value, receiver) {
|
|
952
|
-
|
|
953
|
-
return Reflect.set(
|
|
952
|
+
target2 ?? (target2 = getter());
|
|
953
|
+
return Reflect.set(target2, prop, value, receiver);
|
|
954
954
|
},
|
|
955
955
|
has(_3, prop) {
|
|
956
|
-
|
|
957
|
-
return Reflect.has(
|
|
956
|
+
target2 ?? (target2 = getter());
|
|
957
|
+
return Reflect.has(target2, prop);
|
|
958
958
|
},
|
|
959
959
|
deleteProperty(_3, prop) {
|
|
960
|
-
|
|
961
|
-
return Reflect.deleteProperty(
|
|
960
|
+
target2 ?? (target2 = getter());
|
|
961
|
+
return Reflect.deleteProperty(target2, prop);
|
|
962
962
|
},
|
|
963
963
|
ownKeys(_3) {
|
|
964
|
-
|
|
965
|
-
return Reflect.ownKeys(
|
|
964
|
+
target2 ?? (target2 = getter());
|
|
965
|
+
return Reflect.ownKeys(target2);
|
|
966
966
|
},
|
|
967
967
|
getOwnPropertyDescriptor(_3, prop) {
|
|
968
|
-
|
|
969
|
-
return Reflect.getOwnPropertyDescriptor(
|
|
968
|
+
target2 ?? (target2 = getter());
|
|
969
|
+
return Reflect.getOwnPropertyDescriptor(target2, prop);
|
|
970
970
|
},
|
|
971
971
|
defineProperty(_3, prop, descriptor) {
|
|
972
|
-
|
|
973
|
-
return Reflect.defineProperty(
|
|
972
|
+
target2 ?? (target2 = getter());
|
|
973
|
+
return Reflect.defineProperty(target2, prop, descriptor);
|
|
974
974
|
}
|
|
975
975
|
});
|
|
976
976
|
}
|
|
@@ -11422,15 +11422,15 @@ function _stringFormat(Class2, format, fnOrRegex, _params = {}) {
|
|
|
11422
11422
|
|
|
11423
11423
|
// ../../../node_modules/zod/v4/core/to-json-schema.js
|
|
11424
11424
|
function initializeContext(params) {
|
|
11425
|
-
let
|
|
11426
|
-
if (
|
|
11427
|
-
|
|
11428
|
-
if (
|
|
11429
|
-
|
|
11425
|
+
let target2 = params?.target ?? "draft-2020-12";
|
|
11426
|
+
if (target2 === "draft-4")
|
|
11427
|
+
target2 = "draft-04";
|
|
11428
|
+
if (target2 === "draft-7")
|
|
11429
|
+
target2 = "draft-07";
|
|
11430
11430
|
return {
|
|
11431
11431
|
processors: params.processors ?? {},
|
|
11432
11432
|
metadataRegistry: params?.metadata ?? globalRegistry,
|
|
11433
|
-
target,
|
|
11433
|
+
target: target2,
|
|
11434
11434
|
unrepresentable: params?.unrepresentable ?? "throw",
|
|
11435
11435
|
override: params?.override ?? (() => {
|
|
11436
11436
|
}),
|
|
@@ -11772,8 +11772,8 @@ var createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
|
|
|
11772
11772
|
return finalize(ctx, schema);
|
|
11773
11773
|
};
|
|
11774
11774
|
var createStandardJSONSchemaMethod = (schema, io2, processors = {}) => (params) => {
|
|
11775
|
-
const { libraryOptions, target } = params ?? {};
|
|
11776
|
-
const ctx = initializeContext({ ...libraryOptions ?? {}, target, io: io2, processors });
|
|
11775
|
+
const { libraryOptions, target: target2 } = params ?? {};
|
|
11776
|
+
const ctx = initializeContext({ ...libraryOptions ?? {}, target: target2, io: io2, processors });
|
|
11777
11777
|
process2(schema, ctx);
|
|
11778
11778
|
extractDefs(ctx, schema);
|
|
11779
11779
|
return finalize(ctx, schema);
|
|
@@ -12832,8 +12832,8 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
|
12832
12832
|
catch(params) {
|
|
12833
12833
|
return _catch2(this, params);
|
|
12834
12834
|
},
|
|
12835
|
-
pipe(
|
|
12836
|
-
return pipe(this,
|
|
12835
|
+
pipe(target2) {
|
|
12836
|
+
return pipe(this, target2);
|
|
12837
12837
|
},
|
|
12838
12838
|
readonly() {
|
|
12839
12839
|
return readonly(this);
|
|
@@ -15063,15 +15063,15 @@ var threadOwnershipListResultSchema = external_exports.object({
|
|
|
15063
15063
|
threads: external_exports.array(threadOwnershipSchema).min(1).max(THREAD_OWNERSHIP_LIST_MAX_LENGTH)
|
|
15064
15064
|
}).strict().superRefine(({ threads }, context) => {
|
|
15065
15065
|
const seen = /* @__PURE__ */ new Set();
|
|
15066
|
-
for (const [index,
|
|
15067
|
-
if (seen.has(
|
|
15066
|
+
for (const [index, thread2] of threads.entries()) {
|
|
15067
|
+
if (seen.has(thread2.threadId)) {
|
|
15068
15068
|
context.addIssue({
|
|
15069
15069
|
code: "custom",
|
|
15070
15070
|
message: "Thread ownership-list results must be unique",
|
|
15071
15071
|
path: ["threads", index, "threadId"]
|
|
15072
15072
|
});
|
|
15073
15073
|
}
|
|
15074
|
-
seen.add(
|
|
15074
|
+
seen.add(thread2.threadId);
|
|
15075
15075
|
}
|
|
15076
15076
|
});
|
|
15077
15077
|
var threadSteeringInspectParamsSchema = external_exports.object({
|
|
@@ -16409,6 +16409,44 @@ var remoteSshSetupParamsSchema = external_exports.object({
|
|
|
16409
16409
|
}).strict();
|
|
16410
16410
|
var remoteSshSetupResultSchema = external_exports.object({ state: external_exports.enum(["installed", "not-installed"]) }).strict();
|
|
16411
16411
|
|
|
16412
|
+
// ../../shared-contracts/dist/remote-sessions.js
|
|
16413
|
+
var REMOTE_CONTROLLER_REQUEST_MAX_BYTES = 16 * 1024;
|
|
16414
|
+
var identity = external_exports.string().min(1).max(1024);
|
|
16415
|
+
var target = { hostId: identity.regex(/^remote-(?:ssh(?:-|:)|control:)/u) };
|
|
16416
|
+
var thread = { ...target, threadId: identity };
|
|
16417
|
+
var remoteSessionOperationSchema = external_exports.discriminatedUnion("kind", [
|
|
16418
|
+
external_exports.strictObject({ kind: external_exports.literal("hosts") }),
|
|
16419
|
+
external_exports.strictObject({
|
|
16420
|
+
kind: external_exports.literal("list"),
|
|
16421
|
+
...target,
|
|
16422
|
+
cursor: external_exports.string().nullable(),
|
|
16423
|
+
archived: external_exports.boolean()
|
|
16424
|
+
}),
|
|
16425
|
+
external_exports.strictObject({ kind: external_exports.literal("read"), ...thread }),
|
|
16426
|
+
external_exports.strictObject({
|
|
16427
|
+
kind: external_exports.literal("prompt"),
|
|
16428
|
+
...thread,
|
|
16429
|
+
epoch: identity,
|
|
16430
|
+
text: external_exports.string().min(1).max(8e3),
|
|
16431
|
+
requestId: identity.optional()
|
|
16432
|
+
}),
|
|
16433
|
+
external_exports.strictObject({ kind: external_exports.literal("interrupt"), ...thread, epoch: identity, turnId: identity }),
|
|
16434
|
+
external_exports.strictObject({
|
|
16435
|
+
kind: external_exports.literal("rename"),
|
|
16436
|
+
...thread,
|
|
16437
|
+
epoch: identity,
|
|
16438
|
+
name: external_exports.string().min(1).max(512)
|
|
16439
|
+
}),
|
|
16440
|
+
external_exports.strictObject({ kind: external_exports.literal("archive"), ...thread, epoch: identity, archived: external_exports.boolean() }),
|
|
16441
|
+
external_exports.strictObject({
|
|
16442
|
+
kind: external_exports.literal("respond"),
|
|
16443
|
+
...thread,
|
|
16444
|
+
epoch: identity,
|
|
16445
|
+
requestId: external_exports.union([identity, external_exports.number().int()]),
|
|
16446
|
+
result: external_exports.record(external_exports.string(), external_exports.unknown())
|
|
16447
|
+
})
|
|
16448
|
+
]);
|
|
16449
|
+
|
|
16412
16450
|
// ../../shared-contracts/dist/remote-connections.js
|
|
16413
16451
|
var hostId = external_exports.string().min(1).max(1024);
|
|
16414
16452
|
var codexSshConnectionSchema = external_exports.object({
|
|
@@ -16429,7 +16467,9 @@ var codexSshDraftSchema = external_exports.strictObject({
|
|
|
16429
16467
|
identity: external_exports.string().max(4096).nullable()
|
|
16430
16468
|
});
|
|
16431
16469
|
var remoteConnectionsRequestSchema = external_exports.discriminatedUnion("action", [
|
|
16470
|
+
external_exports.strictObject({ action: external_exports.literal("session"), operation: remoteSessionOperationSchema }),
|
|
16432
16471
|
external_exports.strictObject({ action: external_exports.literal("list") }),
|
|
16472
|
+
external_exports.strictObject({ action: external_exports.literal("catalog") }),
|
|
16433
16473
|
external_exports.strictObject({
|
|
16434
16474
|
action: external_exports.literal("read-thread"),
|
|
16435
16475
|
hostId: hostId.refine((id2) => id2 !== "local"),
|
|
@@ -17504,15 +17544,15 @@ async function startBrokerLaunchAgent(harnessId, environment) {
|
|
|
17504
17544
|
const uid = process.getuid?.();
|
|
17505
17545
|
if (uid === void 0)
|
|
17506
17546
|
return;
|
|
17507
|
-
const
|
|
17508
|
-
if (await runLaunchctl(["kickstart",
|
|
17547
|
+
const target2 = `gui/${uid}/${harnessBrokerLaunchAgentLabel(harnessId)}`;
|
|
17548
|
+
if (await runLaunchctl(["kickstart", target2]))
|
|
17509
17549
|
return;
|
|
17510
17550
|
await runLaunchctl([
|
|
17511
17551
|
"bootstrap",
|
|
17512
17552
|
`gui/${uid}`,
|
|
17513
17553
|
harnessBrokerLaunchAgentPlistPath(environment, harnessId)
|
|
17514
17554
|
]);
|
|
17515
|
-
await runLaunchctl(["kickstart",
|
|
17555
|
+
await runLaunchctl(["kickstart", target2]);
|
|
17516
17556
|
}
|
|
17517
17557
|
var BrokerConnection = class _BrokerConnection {
|
|
17518
17558
|
#onClose;
|
|
@@ -54736,9 +54776,9 @@ import path8 from "node:path";
|
|
|
54736
54776
|
function referencesNpmBin(shim, name, bin) {
|
|
54737
54777
|
if (bin.includes(".."))
|
|
54738
54778
|
return false;
|
|
54739
|
-
const
|
|
54779
|
+
const target2 = `node_modules/${name}/${bin.replace(/^\.\//, "")}`.toLowerCase();
|
|
54740
54780
|
const text2 = shim.replaceAll("\\", "/").toLowerCase();
|
|
54741
|
-
return text2.includes(`%dp0%/${
|
|
54781
|
+
return text2.includes(`%dp0%/${target2}"`) || text2.includes(`%~dp0/${target2}"`);
|
|
54742
54782
|
}
|
|
54743
54783
|
async function npmInstallation(command, packages, environment) {
|
|
54744
54784
|
let selected = await realpath4(command);
|
|
@@ -54777,8 +54817,8 @@ async function npmInstallation(command, packages, environment) {
|
|
|
54777
54817
|
const launchers = await Promise.all(Object.entries(bins).map(async ([bin, entry]) => {
|
|
54778
54818
|
if (path8.basename(bin) !== bin || entry.includes(".."))
|
|
54779
54819
|
return false;
|
|
54780
|
-
const
|
|
54781
|
-
if (
|
|
54820
|
+
const target2 = await realpath4(path8.join(directory, entry)).catch(() => "");
|
|
54821
|
+
if (target2.toLowerCase() !== selected.toLowerCase())
|
|
54782
54822
|
return false;
|
|
54783
54823
|
const shim = await readFile3(path8.join(prefix, `${bin}.cmd`), "utf8").catch(() => "");
|
|
54784
54824
|
return referencesNpmBin(shim, name, entry);
|
|
@@ -60730,10 +60770,10 @@ var ClaudeHarnessSession = class {
|
|
|
60730
60770
|
},
|
|
60731
60771
|
onEvent: (event) => this.#deliverLiveEvent(this.#autonomousTarget, event),
|
|
60732
60772
|
onTerminal: (result) => {
|
|
60733
|
-
const
|
|
60773
|
+
const target2 = this.#autonomousTarget;
|
|
60734
60774
|
this.#autonomousTarget = null;
|
|
60735
|
-
if (
|
|
60736
|
-
this.#finishResult(
|
|
60775
|
+
if (target2)
|
|
60776
|
+
this.#finishResult(target2, result);
|
|
60737
60777
|
}
|
|
60738
60778
|
});
|
|
60739
60779
|
transport.setThreadEventHandler((event) => {
|
|
@@ -61293,13 +61333,13 @@ var ClaudeHarnessSession = class {
|
|
|
61293
61333
|
return active;
|
|
61294
61334
|
}
|
|
61295
61335
|
/** Live native events outside a requested Root Segment; settlements stay Thread-level. */
|
|
61296
|
-
#deliverLiveEvent(
|
|
61336
|
+
#deliverLiveEvent(target2, event) {
|
|
61297
61337
|
if (event.type === "usage.request") {
|
|
61298
61338
|
this.#meterUsage(event.record);
|
|
61299
61339
|
return;
|
|
61300
61340
|
}
|
|
61301
|
-
if (
|
|
61302
|
-
this.#handleTurnEvent(
|
|
61341
|
+
if (target2 && this.#active === target2) {
|
|
61342
|
+
this.#handleTurnEvent(target2, event);
|
|
61303
61343
|
return;
|
|
61304
61344
|
}
|
|
61305
61345
|
if (event.type === "subagent.settled")
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createRequire as __codexhostCreateRequire } from "node:module"; const require = __codexhostCreateRequire(import.meta.url);
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
-
var __export = (
|
|
3
|
+
var __export = (target2, all) => {
|
|
4
4
|
for (var name in all)
|
|
5
|
-
__defProp(
|
|
5
|
+
__defProp(target2, name, { get: all[name], enumerable: true });
|
|
6
6
|
};
|
|
7
7
|
|
|
8
8
|
// ../../harness-discovery/dist/environment.js
|
|
@@ -360,9 +360,9 @@ import path4 from "node:path";
|
|
|
360
360
|
function referencesNpmBin(shim, name, bin) {
|
|
361
361
|
if (bin.includes(".."))
|
|
362
362
|
return false;
|
|
363
|
-
const
|
|
363
|
+
const target2 = `node_modules/${name}/${bin.replace(/^\.\//, "")}`.toLowerCase();
|
|
364
364
|
const text2 = shim.replaceAll("\\", "/").toLowerCase();
|
|
365
|
-
return text2.includes(`%dp0%/${
|
|
365
|
+
return text2.includes(`%dp0%/${target2}"`) || text2.includes(`%~dp0/${target2}"`);
|
|
366
366
|
}
|
|
367
367
|
async function npmInstallation(command, packages, environment) {
|
|
368
368
|
let selected = await realpath(command);
|
|
@@ -401,8 +401,8 @@ async function npmInstallation(command, packages, environment) {
|
|
|
401
401
|
const launchers = await Promise.all(Object.entries(bins).map(async ([bin, entry]) => {
|
|
402
402
|
if (path4.basename(bin) !== bin || entry.includes(".."))
|
|
403
403
|
return false;
|
|
404
|
-
const
|
|
405
|
-
if (
|
|
404
|
+
const target2 = await realpath(path4.join(directory, entry)).catch(() => "");
|
|
405
|
+
if (target2.toLowerCase() !== selected.toLowerCase())
|
|
406
406
|
return false;
|
|
407
407
|
const shim = await readFile(path4.join(prefix, `${bin}.cmd`), "utf8").catch(() => "");
|
|
408
408
|
return referencesNpmBin(shim, name, entry);
|
|
@@ -1234,8 +1234,8 @@ function defineLazy(object2, key, getter) {
|
|
|
1234
1234
|
function objectClone(obj) {
|
|
1235
1235
|
return Object.create(Object.getPrototypeOf(obj), Object.getOwnPropertyDescriptors(obj));
|
|
1236
1236
|
}
|
|
1237
|
-
function assignProp(
|
|
1238
|
-
Object.defineProperty(
|
|
1237
|
+
function assignProp(target2, prop, value) {
|
|
1238
|
+
Object.defineProperty(target2, prop, {
|
|
1239
1239
|
value,
|
|
1240
1240
|
writable: true,
|
|
1241
1241
|
enumerable: true,
|
|
@@ -1418,35 +1418,35 @@ function normalizeParams(_params) {
|
|
|
1418
1418
|
return params;
|
|
1419
1419
|
}
|
|
1420
1420
|
function createTransparentProxy(getter) {
|
|
1421
|
-
let
|
|
1421
|
+
let target2;
|
|
1422
1422
|
return new Proxy({}, {
|
|
1423
1423
|
get(_, prop, receiver) {
|
|
1424
|
-
|
|
1425
|
-
return Reflect.get(
|
|
1424
|
+
target2 ?? (target2 = getter());
|
|
1425
|
+
return Reflect.get(target2, prop, receiver);
|
|
1426
1426
|
},
|
|
1427
1427
|
set(_, prop, value, receiver) {
|
|
1428
|
-
|
|
1429
|
-
return Reflect.set(
|
|
1428
|
+
target2 ?? (target2 = getter());
|
|
1429
|
+
return Reflect.set(target2, prop, value, receiver);
|
|
1430
1430
|
},
|
|
1431
1431
|
has(_, prop) {
|
|
1432
|
-
|
|
1433
|
-
return Reflect.has(
|
|
1432
|
+
target2 ?? (target2 = getter());
|
|
1433
|
+
return Reflect.has(target2, prop);
|
|
1434
1434
|
},
|
|
1435
1435
|
deleteProperty(_, prop) {
|
|
1436
|
-
|
|
1437
|
-
return Reflect.deleteProperty(
|
|
1436
|
+
target2 ?? (target2 = getter());
|
|
1437
|
+
return Reflect.deleteProperty(target2, prop);
|
|
1438
1438
|
},
|
|
1439
1439
|
ownKeys(_) {
|
|
1440
|
-
|
|
1441
|
-
return Reflect.ownKeys(
|
|
1440
|
+
target2 ?? (target2 = getter());
|
|
1441
|
+
return Reflect.ownKeys(target2);
|
|
1442
1442
|
},
|
|
1443
1443
|
getOwnPropertyDescriptor(_, prop) {
|
|
1444
|
-
|
|
1445
|
-
return Reflect.getOwnPropertyDescriptor(
|
|
1444
|
+
target2 ?? (target2 = getter());
|
|
1445
|
+
return Reflect.getOwnPropertyDescriptor(target2, prop);
|
|
1446
1446
|
},
|
|
1447
1447
|
defineProperty(_, prop, descriptor) {
|
|
1448
|
-
|
|
1449
|
-
return Reflect.defineProperty(
|
|
1448
|
+
target2 ?? (target2 = getter());
|
|
1449
|
+
return Reflect.defineProperty(target2, prop, descriptor);
|
|
1450
1450
|
}
|
|
1451
1451
|
});
|
|
1452
1452
|
}
|
|
@@ -11898,15 +11898,15 @@ function _stringFormat(Class2, format, fnOrRegex, _params = {}) {
|
|
|
11898
11898
|
|
|
11899
11899
|
// ../../../node_modules/zod/v4/core/to-json-schema.js
|
|
11900
11900
|
function initializeContext(params) {
|
|
11901
|
-
let
|
|
11902
|
-
if (
|
|
11903
|
-
|
|
11904
|
-
if (
|
|
11905
|
-
|
|
11901
|
+
let target2 = params?.target ?? "draft-2020-12";
|
|
11902
|
+
if (target2 === "draft-4")
|
|
11903
|
+
target2 = "draft-04";
|
|
11904
|
+
if (target2 === "draft-7")
|
|
11905
|
+
target2 = "draft-07";
|
|
11906
11906
|
return {
|
|
11907
11907
|
processors: params.processors ?? {},
|
|
11908
11908
|
metadataRegistry: params?.metadata ?? globalRegistry,
|
|
11909
|
-
target,
|
|
11909
|
+
target: target2,
|
|
11910
11910
|
unrepresentable: params?.unrepresentable ?? "throw",
|
|
11911
11911
|
override: params?.override ?? (() => {
|
|
11912
11912
|
}),
|
|
@@ -12248,8 +12248,8 @@ var createToJSONSchemaMethod = (schema, processors = {}) => (params) => {
|
|
|
12248
12248
|
return finalize(ctx, schema);
|
|
12249
12249
|
};
|
|
12250
12250
|
var createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params) => {
|
|
12251
|
-
const { libraryOptions, target } = params ?? {};
|
|
12252
|
-
const ctx = initializeContext({ ...libraryOptions ?? {}, target, io, processors });
|
|
12251
|
+
const { libraryOptions, target: target2 } = params ?? {};
|
|
12252
|
+
const ctx = initializeContext({ ...libraryOptions ?? {}, target: target2, io, processors });
|
|
12253
12253
|
process2(schema, ctx);
|
|
12254
12254
|
extractDefs(ctx, schema);
|
|
12255
12255
|
return finalize(ctx, schema);
|
|
@@ -13308,8 +13308,8 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
|
13308
13308
|
catch(params) {
|
|
13309
13309
|
return _catch2(this, params);
|
|
13310
13310
|
},
|
|
13311
|
-
pipe(
|
|
13312
|
-
return pipe(this,
|
|
13311
|
+
pipe(target2) {
|
|
13312
|
+
return pipe(this, target2);
|
|
13313
13313
|
},
|
|
13314
13314
|
readonly() {
|
|
13315
13315
|
return readonly(this);
|
|
@@ -15539,15 +15539,15 @@ var threadOwnershipListResultSchema = external_exports.object({
|
|
|
15539
15539
|
threads: external_exports.array(threadOwnershipSchema).min(1).max(THREAD_OWNERSHIP_LIST_MAX_LENGTH)
|
|
15540
15540
|
}).strict().superRefine(({ threads }, context) => {
|
|
15541
15541
|
const seen = /* @__PURE__ */ new Set();
|
|
15542
|
-
for (const [index,
|
|
15543
|
-
if (seen.has(
|
|
15542
|
+
for (const [index, thread2] of threads.entries()) {
|
|
15543
|
+
if (seen.has(thread2.threadId)) {
|
|
15544
15544
|
context.addIssue({
|
|
15545
15545
|
code: "custom",
|
|
15546
15546
|
message: "Thread ownership-list results must be unique",
|
|
15547
15547
|
path: ["threads", index, "threadId"]
|
|
15548
15548
|
});
|
|
15549
15549
|
}
|
|
15550
|
-
seen.add(
|
|
15550
|
+
seen.add(thread2.threadId);
|
|
15551
15551
|
}
|
|
15552
15552
|
});
|
|
15553
15553
|
var threadSteeringInspectParamsSchema = external_exports.object({
|
|
@@ -16885,6 +16885,44 @@ var remoteSshSetupParamsSchema = external_exports.object({
|
|
|
16885
16885
|
}).strict();
|
|
16886
16886
|
var remoteSshSetupResultSchema = external_exports.object({ state: external_exports.enum(["installed", "not-installed"]) }).strict();
|
|
16887
16887
|
|
|
16888
|
+
// ../../shared-contracts/dist/remote-sessions.js
|
|
16889
|
+
var REMOTE_CONTROLLER_REQUEST_MAX_BYTES = 16 * 1024;
|
|
16890
|
+
var identity = external_exports.string().min(1).max(1024);
|
|
16891
|
+
var target = { hostId: identity.regex(/^remote-(?:ssh(?:-|:)|control:)/u) };
|
|
16892
|
+
var thread = { ...target, threadId: identity };
|
|
16893
|
+
var remoteSessionOperationSchema = external_exports.discriminatedUnion("kind", [
|
|
16894
|
+
external_exports.strictObject({ kind: external_exports.literal("hosts") }),
|
|
16895
|
+
external_exports.strictObject({
|
|
16896
|
+
kind: external_exports.literal("list"),
|
|
16897
|
+
...target,
|
|
16898
|
+
cursor: external_exports.string().nullable(),
|
|
16899
|
+
archived: external_exports.boolean()
|
|
16900
|
+
}),
|
|
16901
|
+
external_exports.strictObject({ kind: external_exports.literal("read"), ...thread }),
|
|
16902
|
+
external_exports.strictObject({
|
|
16903
|
+
kind: external_exports.literal("prompt"),
|
|
16904
|
+
...thread,
|
|
16905
|
+
epoch: identity,
|
|
16906
|
+
text: external_exports.string().min(1).max(8e3),
|
|
16907
|
+
requestId: identity.optional()
|
|
16908
|
+
}),
|
|
16909
|
+
external_exports.strictObject({ kind: external_exports.literal("interrupt"), ...thread, epoch: identity, turnId: identity }),
|
|
16910
|
+
external_exports.strictObject({
|
|
16911
|
+
kind: external_exports.literal("rename"),
|
|
16912
|
+
...thread,
|
|
16913
|
+
epoch: identity,
|
|
16914
|
+
name: external_exports.string().min(1).max(512)
|
|
16915
|
+
}),
|
|
16916
|
+
external_exports.strictObject({ kind: external_exports.literal("archive"), ...thread, epoch: identity, archived: external_exports.boolean() }),
|
|
16917
|
+
external_exports.strictObject({
|
|
16918
|
+
kind: external_exports.literal("respond"),
|
|
16919
|
+
...thread,
|
|
16920
|
+
epoch: identity,
|
|
16921
|
+
requestId: external_exports.union([identity, external_exports.number().int()]),
|
|
16922
|
+
result: external_exports.record(external_exports.string(), external_exports.unknown())
|
|
16923
|
+
})
|
|
16924
|
+
]);
|
|
16925
|
+
|
|
16888
16926
|
// ../../shared-contracts/dist/remote-connections.js
|
|
16889
16927
|
var hostId = external_exports.string().min(1).max(1024);
|
|
16890
16928
|
var codexSshConnectionSchema = external_exports.object({
|
|
@@ -16905,7 +16943,9 @@ var codexSshDraftSchema = external_exports.strictObject({
|
|
|
16905
16943
|
identity: external_exports.string().max(4096).nullable()
|
|
16906
16944
|
});
|
|
16907
16945
|
var remoteConnectionsRequestSchema = external_exports.discriminatedUnion("action", [
|
|
16946
|
+
external_exports.strictObject({ action: external_exports.literal("session"), operation: remoteSessionOperationSchema }),
|
|
16908
16947
|
external_exports.strictObject({ action: external_exports.literal("list") }),
|
|
16948
|
+
external_exports.strictObject({ action: external_exports.literal("catalog") }),
|
|
16909
16949
|
external_exports.strictObject({
|
|
16910
16950
|
action: external_exports.literal("read-thread"),
|
|
16911
16951
|
hostId: hostId.refine((id) => id !== "local"),
|
|
@@ -22595,11 +22635,11 @@ var AgentApp = class {
|
|
|
22595
22635
|
[runAgentConnectHandlers](connection) {
|
|
22596
22636
|
runConnectHandlers(connection, this.connectHandlers);
|
|
22597
22637
|
}
|
|
22598
|
-
connect(
|
|
22599
|
-
return this.connectConnection(
|
|
22638
|
+
connect(target2, options = {}) {
|
|
22639
|
+
return this.connectConnection(target2, options).connection;
|
|
22600
22640
|
}
|
|
22601
|
-
connectWith(
|
|
22602
|
-
const { rawConnection, connection } = this.connectConnection(
|
|
22641
|
+
connectWith(target2, op) {
|
|
22642
|
+
const { rawConnection, connection } = this.connectConnection(target2);
|
|
22603
22643
|
return rawConnection.runUntil(() => op(connection.client));
|
|
22604
22644
|
}
|
|
22605
22645
|
/**
|
|
@@ -22640,22 +22680,22 @@ var AgentApp = class {
|
|
|
22640
22680
|
registerAppNotification(this.builder, spec, (params, cx, signal) => agentNotificationContext(params, AgentContext.create(cx), signal), handler);
|
|
22641
22681
|
return this;
|
|
22642
22682
|
}
|
|
22643
|
-
connectConnection(
|
|
22644
|
-
if (isStream(
|
|
22645
|
-
const state2 = this.openStreamConnection(
|
|
22683
|
+
connectConnection(target2, options = {}) {
|
|
22684
|
+
if (isStream(target2)) {
|
|
22685
|
+
const state2 = this.openStreamConnection(target2);
|
|
22646
22686
|
if (!options.deferConnectHandlers) {
|
|
22647
22687
|
this[runAgentConnectHandlers](state2.connection);
|
|
22648
22688
|
}
|
|
22649
22689
|
return state2;
|
|
22650
22690
|
}
|
|
22651
22691
|
const [thisStream, peerStream] = memoryStreamPair();
|
|
22652
|
-
const peerRawConnection =
|
|
22692
|
+
const peerRawConnection = target2[appBuilder]().connect(peerStream, stableConnectionOptions);
|
|
22653
22693
|
const peerConnection = clientConnection(peerRawConnection);
|
|
22654
22694
|
const state = this.openStreamConnection(thisStream);
|
|
22655
22695
|
void state.rawConnection.closed.then(() => peerConnection.close());
|
|
22656
22696
|
void peerRawConnection.closed.then(() => state.connection.close());
|
|
22657
22697
|
try {
|
|
22658
|
-
|
|
22698
|
+
target2[runClientConnectHandlers](peerConnection);
|
|
22659
22699
|
this[runAgentConnectHandlers](state.connection);
|
|
22660
22700
|
} catch (error51) {
|
|
22661
22701
|
peerConnection.close(error51);
|
|
@@ -22695,11 +22735,11 @@ var ClientApp = class {
|
|
|
22695
22735
|
[runClientConnectHandlers](connection) {
|
|
22696
22736
|
runConnectHandlers(connection, this.connectHandlers);
|
|
22697
22737
|
}
|
|
22698
|
-
connect(
|
|
22699
|
-
return this.connectConnection(
|
|
22738
|
+
connect(target2) {
|
|
22739
|
+
return this.connectConnection(target2).connection;
|
|
22700
22740
|
}
|
|
22701
|
-
connectWith(
|
|
22702
|
-
const { rawConnection, connection } = this.connectConnection(
|
|
22741
|
+
connectWith(target2, op) {
|
|
22742
|
+
const { rawConnection, connection } = this.connectConnection(target2);
|
|
22703
22743
|
return rawConnection.runUntil(() => op(connection.agent));
|
|
22704
22744
|
}
|
|
22705
22745
|
/**
|
|
@@ -22740,20 +22780,20 @@ var ClientApp = class {
|
|
|
22740
22780
|
registerAppNotification(this.builder, spec, (params, cx, signal) => clientNotificationContext(params, ClientContext.create(cx), signal), handler);
|
|
22741
22781
|
return this;
|
|
22742
22782
|
}
|
|
22743
|
-
connectConnection(
|
|
22744
|
-
if (isStream(
|
|
22745
|
-
const state2 = this.openStreamConnection(
|
|
22783
|
+
connectConnection(target2) {
|
|
22784
|
+
if (isStream(target2)) {
|
|
22785
|
+
const state2 = this.openStreamConnection(target2);
|
|
22746
22786
|
this[runClientConnectHandlers](state2.connection);
|
|
22747
22787
|
return state2;
|
|
22748
22788
|
}
|
|
22749
22789
|
const [thisStream, peerStream] = memoryStreamPair();
|
|
22750
|
-
const peerRawConnection =
|
|
22790
|
+
const peerRawConnection = target2[appBuilder]().connect(peerStream, stableConnectionOptions);
|
|
22751
22791
|
const peerConnection = agentConnection(peerRawConnection);
|
|
22752
22792
|
const state = this.openStreamConnection(thisStream);
|
|
22753
22793
|
void state.rawConnection.closed.then(() => peerConnection.close());
|
|
22754
22794
|
void peerRawConnection.closed.then(() => state.connection.close());
|
|
22755
22795
|
try {
|
|
22756
|
-
|
|
22796
|
+
target2[runAgentConnectHandlers](peerConnection);
|
|
22757
22797
|
this[runClientConnectHandlers](state.connection);
|
|
22758
22798
|
} catch (error51) {
|
|
22759
22799
|
peerConnection.close(error51);
|
|
@@ -23634,7 +23674,7 @@ async function validateCodeBuddyChildContents(contents, parent, childId, cwd, to
|
|
|
23634
23674
|
throw new CodeBuddyError("protocolError", "Inherited Subagent identity changed");
|
|
23635
23675
|
inheritedEntries = prefixParsed.entries;
|
|
23636
23676
|
}
|
|
23637
|
-
const
|
|
23677
|
+
const target2 = await realpath4(cwd);
|
|
23638
23678
|
const inheritedCwds = inheritedEntries.flatMap((row) => typeof row.cwd === "string" ? [row.cwd] : []);
|
|
23639
23679
|
const suffixCwds = parsed.entries.slice(inheritedEntries.length).flatMap((row) => typeof row.cwd === "string" ? [row.cwd] : []);
|
|
23640
23680
|
const canonical = await canonicalCwds(suffixCwds);
|
|
@@ -23646,7 +23686,7 @@ async function validateCodeBuddyChildContents(contents, parent, childId, cwd, to
|
|
|
23646
23686
|
}
|
|
23647
23687
|
for (const value of suffixCwds) {
|
|
23648
23688
|
const actual = canonical.get(value);
|
|
23649
|
-
if (!actual || !equalPath(actual,
|
|
23689
|
+
if (!actual || !equalPath(actual, target2))
|
|
23650
23690
|
throw new CodeBuddyError("invalidRequest", "Subagent workspace differs from parent");
|
|
23651
23691
|
}
|
|
23652
23692
|
const bindings = new Map((inherited?.workspaceBindings ?? []).map((binding) => [
|
|
@@ -26440,15 +26480,15 @@ async function startBrokerLaunchAgent(harnessId, environment) {
|
|
|
26440
26480
|
const uid = process.getuid?.();
|
|
26441
26481
|
if (uid === void 0)
|
|
26442
26482
|
return;
|
|
26443
|
-
const
|
|
26444
|
-
if (await runLaunchctl(["kickstart",
|
|
26483
|
+
const target2 = `gui/${uid}/${harnessBrokerLaunchAgentLabel(harnessId)}`;
|
|
26484
|
+
if (await runLaunchctl(["kickstart", target2]))
|
|
26445
26485
|
return;
|
|
26446
26486
|
await runLaunchctl([
|
|
26447
26487
|
"bootstrap",
|
|
26448
26488
|
`gui/${uid}`,
|
|
26449
26489
|
harnessBrokerLaunchAgentPlistPath(environment, harnessId)
|
|
26450
26490
|
]);
|
|
26451
|
-
await runLaunchctl(["kickstart",
|
|
26491
|
+
await runLaunchctl(["kickstart", target2]);
|
|
26452
26492
|
}
|
|
26453
26493
|
var BrokerConnection = class _BrokerConnection {
|
|
26454
26494
|
#onClose;
|