@kitman-sh/cli 0.10.55 → 0.10.57

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.
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-61k67vxh.js";
10
10
  import {
11
11
  runForEach
12
- } from "./chunk-xgwjcq4z.js";
12
+ } from "./chunk-cy5fbrfm.js";
13
13
  import {
14
14
  WebSocketConstructor,
15
15
  layerWebSocketConstructorGlobal,
@@ -19,13 +19,13 @@ import {
19
19
  RunnerReplicaRpcs,
20
20
  RunnerRunFileRpcs,
21
21
  ProgramRpcs
22
- } from "./chunk-m32wb6t0.js";
22
+ } from "./chunk-qhpyzn7c.js";
23
23
  import {
24
24
  layerJson,
25
25
  make4,
26
26
  withHeaders,
27
27
  layerProtocolSocket
28
- } from "./chunk-148mjppg.js";
28
+ } from "./chunk-de4cfe40.js";
29
29
 
30
30
  // packages/live/src/rpc/runner-client.ts
31
31
  var proxiedWebSocket = (proxy) => succeed5(WebSocketConstructor)((target) => {
@@ -7,10 +7,10 @@ import {
7
7
  decoded2,
8
8
  readOpencode2,
9
9
  runOpencodeReader2
10
- } from "./chunk-vtn088tq.js";
11
- import"./chunk-mmetyep8.js";
10
+ } from "./chunk-jc920h47.js";
11
+ import"./chunk-5tfxtw9z.js";
12
12
  import"./chunk-7evwar6b.js";
13
- import"./chunk-xgwjcq4z.js";
13
+ import"./chunk-cy5fbrfm.js";
14
14
  import"./chunk-61k67vxh.js";
15
15
  export {
16
16
  decoded2 as decoded,
@@ -31,7 +31,7 @@ import {
31
31
  runCollect,
32
32
  runDrain,
33
33
  mkString
34
- } from "./chunk-xgwjcq4z.js";
34
+ } from "./chunk-cy5fbrfm.js";
35
35
 
36
36
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/internal/redacted.js
37
37
  var redactedRegistry = /* @__PURE__ */ new WeakMap;
@@ -28,7 +28,7 @@ import {
28
28
  import {
29
29
  withDefault,
30
30
  String2
31
- } from "./chunk-xgwjcq4z.js";
31
+ } from "./chunk-cy5fbrfm.js";
32
32
  import {
33
33
  digestSha256,
34
34
  digestSha512,
@@ -36,9 +36,9 @@ import {
36
36
  schemaBodyJson,
37
37
  filterStatusOk,
38
38
  get2,
39
- layer2,
39
+ layer4,
40
40
  KitDigest
41
- } from "./chunk-m32wb6t0.js";
41
+ } from "./chunk-qhpyzn7c.js";
42
42
 
43
43
  // packages/core/src/npm-registry.ts
44
44
  var KitManifest = Struct({
@@ -107,7 +107,7 @@ var npmRegistryAt = (url = registryUrl) => {
107
107
  message: `npm did not answer for ${name}@${version}: ${error.message}; try again`
108
108
  });
109
109
  const packument = (name, version) => gen(function* () {
110
- const response = yield* get2(`${yield* base}/${name.replace("/", "%2F")}`).pipe(mapError2(unreachable(name, version)), provide3(layer2));
110
+ const response = yield* get2(`${yield* base}/${name.replace("/", "%2F")}`).pipe(mapError2(unreachable(name, version)), provide3(layer4));
111
111
  if (response.status === 404)
112
112
  return yield* new NpmRegistryError({ kind: "not_found", message: `npm has no package ${name}` });
113
113
  return yield* filterStatusOk(response).pipe(flatMap3(schemaBodyJson(Packument)), mapError2(unreachable(name, version)));
@@ -123,7 +123,7 @@ var npmRegistryAt = (url = registryUrl) => {
123
123
  const dist = found.versions[version]?.dist;
124
124
  if (dist === undefined)
125
125
  return yield* new NpmRegistryError({ kind: "not_found", message: `npm has no ${name}@${wanted}` });
126
- const tarball = yield* get2(dist.tarball).pipe(flatMap3(filterStatusOk), flatMap3((response) => response.arrayBuffer), map8((buffer) => new Uint8Array(buffer)), mapError2(unreachable(name, version)), provide3(layer2));
126
+ const tarball = yield* get2(dist.tarball).pipe(flatMap3(filterStatusOk), flatMap3((response) => response.arrayBuffer), map8((buffer) => new Uint8Array(buffer)), mapError2(unreachable(name, version)), provide3(layer4));
127
127
  if (!tarballMatches(tarball, dist))
128
128
  return yield* new NpmRegistryError({
129
129
  kind: "integrity",
@@ -79,6 +79,8 @@ import {
79
79
  fiberRunIn,
80
80
  makeLatchUnsafe,
81
81
  makeLatch,
82
+ ClockRef,
83
+ currentTimeMillis2,
82
84
  succeed3,
83
85
  failCause2,
84
86
  fail4,
@@ -248,6 +250,10 @@ var makeEquivalence = (equivalence) => {
248
250
  return (self, that) => is(self, that) && is(that, self);
249
251
  };
250
252
 
253
+ // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Clock.js
254
+ var Clock = ClockRef;
255
+ var currentTimeMillis = currentTimeMillis2;
256
+
251
257
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/ByteSize.js
252
258
  var bigint0 = /* @__PURE__ */ BigInt(0);
253
259
  var bigint1 = /* @__PURE__ */ BigInt(1);
@@ -3471,13 +3477,16 @@ var pinnedSrtCommand2 = () => compiled2 ? [process.execPath, "srt"] : [process.e
3471
3477
  var pinnedSrtStepCommand2 = () => compiled2 ? [process.execPath, "srt-step"] : [process.execPath, fileURLToPath(new URL("./srt-step.main.ts", import.meta.url))];
3472
3478
  var srtPackageDir = () => fileURLToPath(new URL("../", import.meta.resolve("@anthropic-ai/sandbox-runtime/dist/cli.js")));
3473
3479
  var runSrtCli2 = () => import("@anthropic-ai/sandbox-runtime/dist/cli.js");
3480
+ var kitmanCacheDirectory2 = gen(function* () {
3481
+ const path = yield* Path;
3482
+ const cacheHome = yield* String2("XDG_CACHE_HOME").pipe(withDefault(""));
3483
+ return path.join(cacheHome === "" ? path.join(homedir(), ".cache") : cacheHome, "kitman");
3484
+ });
3474
3485
  var embeddedApplySeccomp = gen(function* () {
3475
3486
  const file = compiled2 && process.platform === "linux" ? embeddedFile(Bun.embeddedFiles, "apply-seccomp") : undefined;
3476
3487
  if (file === undefined)
3477
3488
  return;
3478
- const path = yield* Path;
3479
- const cacheHome = yield* String2("XDG_CACHE_HOME").pipe(withDefault(""));
3480
- return yield* extractEmbeddedFile(path.join(cacheHome === "" ? path.join(homedir(), ".cache") : cacheHome, "kitman"), file, "apply-seccomp");
3489
+ return yield* extractEmbeddedFile(yield* kitmanCacheDirectory2, file, "apply-seccomp");
3481
3490
  }).pipe(orDie);
3482
3491
  var globCharacters = /[*?[\]{}]/;
3483
3492
  var readAllowEntry = (path) => globCharacters.test(path) ? { path, literal: true } : path;
@@ -3548,4 +3557,4 @@ var srtArgv2 = (srtCommand, settingsFile, argv) => [
3548
3557
  ...argv
3549
3558
  ];
3550
3559
 
3551
- export { map, makeEquivalence, bytes, join, interrupt, getCurrent, BadArgument, systemError, badArgument, makeUnsafe2, make8, unbounded, publishUnsafe, make9, bounded, sliding, unbounded2, offer, offerUnsafe, offerAll, fail, failCause, failCauseUnsafe, end, endUnsafe, shutdownUnsafe, take, poll, makeUnsafe3, fromTransform, mapDone, isSink, fromChannel, drain, make10, get3, isStream, fromChannel2, callback, empty2, make11, suspend, fail2, fromQueue, fromPubSub, fromReadableStream, unwrap, map2, tap, drainFork, concat, merge2, filter, catchCause, tapError, mapError, transduce, decodeText, encodeText, splitLines, interruptWhen, ensuring, provideContext, run, runCollect, runFold, runHead, runForEach, runDrain, mkString, mkArrayBuffer, toReadableStreamEffect, FileSystem, make12, FileTypeId, WatchBackend, Path, make13, embeddedFile, extractEmbeddedFile, map3, all, withDefault, option, String2, optionalEnv, harnessesUnsupportedInSrt2, compiled2, pinnedSrtCommand2, pinnedSrtStepCommand2, runSrtCli2, srtSettings2, srtCacheEnvironment2, srtInheritedEnv2, inheritedEnvironment2, withOnlyEnvironment2, writeSrtSettings2, srtStepArgv2, srtArgv2 };
3560
+ export { map, makeEquivalence, Clock, currentTimeMillis, bytes, join, interrupt, getCurrent, BadArgument, systemError, badArgument, makeUnsafe2, make8, unbounded, publishUnsafe, make9, bounded, sliding, unbounded2, offer, offerUnsafe, offerAll, fail, failCause, failCauseUnsafe, end, endUnsafe, shutdownUnsafe, take, poll, makeUnsafe3, fromTransform, mapDone, isSink, fromChannel, drain, make10, get3, isStream, fromChannel2, callback, empty2, make11, suspend, fail2, fromQueue, fromPubSub, fromReadableStream, unwrap, map2, tap, drainFork, concat, merge2, filter, catchCause, tapError, mapError, transduce, decodeText, encodeText, splitLines, interruptWhen, ensuring, provideContext, run, runCollect, runFold, runHead, runForEach, runDrain, mkString, mkArrayBuffer, toReadableStreamEffect, FileSystem, make12, FileTypeId, WatchBackend, Path, make13, embeddedFile, extractEmbeddedFile, map3, all, withDefault, option, String2, optionalEnv, harnessesUnsupportedInSrt2, compiled2, pinnedSrtCommand2, pinnedSrtStepCommand2, runSrtCli2, kitmanCacheDirectory2, srtSettings2, srtCacheEnvironment2, srtInheritedEnv2, inheritedEnvironment2, withOnlyEnvironment2, writeSrtSettings2, srtStepArgv2, srtArgv2 };
@@ -98,6 +98,7 @@ import {
98
98
  toCodecJson
99
99
  } from "./chunk-61k67vxh.js";
100
100
  import {
101
+ Clock,
101
102
  interrupt,
102
103
  getCurrent,
103
104
  makeUnsafe2,
@@ -108,9 +109,8 @@ import {
108
109
  shutdownUnsafe,
109
110
  fromQueue,
110
111
  unwrap
111
- } from "./chunk-xgwjcq4z.js";
112
+ } from "./chunk-cy5fbrfm.js";
112
113
  import {
113
- Clock,
114
114
  empty,
115
115
  fromInput,
116
116
  merge,
@@ -123,7 +123,7 @@ import {
123
123
  ParseOptions,
124
124
  RpcClientDefect,
125
125
  RpcClientError
126
- } from "./chunk-m32wb6t0.js";
126
+ } from "./chunk-qhpyzn7c.js";
127
127
 
128
128
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/workers/Transferable.js
129
129
  class Collector extends (/* @__PURE__ */ Service2()("effect/workers/Transferable/Collector")) {
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import"./chunk-mmetyep8.js";
2
+ import"./chunk-5tfxtw9z.js";
3
3
  import {
4
4
  HERDR_CORE_GENERATION2,
5
5
  HERDR_CORE_INSTALL_COMMAND2,
@@ -12,8 +12,8 @@ import {
12
12
  herdrCoreLayer2,
13
13
  herdrCoreTransportLayer2,
14
14
  updateHerdrCore2
15
- } from "./chunk-m32wb6t0.js";
16
- import"./chunk-xgwjcq4z.js";
15
+ } from "./chunk-qhpyzn7c.js";
16
+ import"./chunk-cy5fbrfm.js";
17
17
  import"./chunk-61k67vxh.js";
18
18
  export {
19
19
  HERDR_CORE_GENERATION2 as HERDR_CORE_GENERATION,
@@ -104,7 +104,6 @@ import {
104
104
  encodePrettyJsonString
105
105
  } from "./chunk-61k67vxh.js";
106
106
  import {
107
- currentTimeMillis,
108
107
  SecureRandom,
109
108
  makeUnsafe,
110
109
  formatIso,
@@ -153,7 +152,7 @@ import {
153
152
  runMcpEffect,
154
153
  createAgentAuthSignedFetch,
155
154
  setupMcpAgentCredential
156
- } from "./chunk-m32wb6t0.js";
155
+ } from "./chunk-qhpyzn7c.js";
157
156
  import {
158
157
  guard,
159
158
  Id,
@@ -175,6 +174,7 @@ import {
175
174
  kindOf
176
175
  } from "./chunk-7evwar6b.js";
177
176
  import {
177
+ currentTimeMillis,
178
178
  join,
179
179
  interrupt,
180
180
  runForEach,
@@ -187,7 +187,7 @@ import {
187
187
  withDefault,
188
188
  option,
189
189
  String2
190
- } from "./chunk-xgwjcq4z.js";
190
+ } from "./chunk-cy5fbrfm.js";
191
191
  import {
192
192
  nextInt
193
193
  } from "./chunk-gwcqz1bj.js";
@@ -197,7 +197,7 @@ import {
197
197
  withHeaders,
198
198
  layerProtocolSocket,
199
199
  ConnectionHooks
200
- } from "./chunk-148mjppg.js";
200
+ } from "./chunk-de4cfe40.js";
201
201
 
202
202
  // apps/cli/src/mcp.ts
203
203
  import { tmpdir } from "os";
@@ -32,15 +32,15 @@ import {
32
32
  FileSystem,
33
33
  Path,
34
34
  optionalEnv
35
- } from "./chunk-xgwjcq4z.js";
35
+ } from "./chunk-cy5fbrfm.js";
36
36
  import {
37
37
  AgentHarnessIds,
38
38
  sha2562,
39
39
  runCommand2
40
- } from "./chunk-m32wb6t0.js";
40
+ } from "./chunk-qhpyzn7c.js";
41
41
  import {
42
42
  NpmRegistry
43
- } from "./chunk-twp7aprz.js";
43
+ } from "./chunk-a1yf46xt.js";
44
44
 
45
45
  // packages/agent-runtime/src/config-convergence.ts
46
46
  var writeAgentEnvironmentConfigFile2 = fnUntraced(function* (file, content, keep = {}) {
@@ -32,11 +32,11 @@ import {
32
32
  make11,
33
33
  runForEach,
34
34
  compiled2
35
- } from "./chunk-xgwjcq4z.js";
35
+ } from "./chunk-cy5fbrfm.js";
36
36
  import {
37
37
  ChildProcessSpawner,
38
38
  make3
39
- } from "./chunk-mmetyep8.js";
39
+ } from "./chunk-5tfxtw9z.js";
40
40
 
41
41
  // packages/agent-runtime/src/opencode-store.ts
42
42
  import { lstatSync, readFileSync, realpathSync } from "fs";
@@ -87,6 +87,7 @@ import {
87
87
  encodePrettyJsonString
88
88
  } from "./chunk-61k67vxh.js";
89
89
  import {
90
+ currentTimeMillis,
90
91
  tap,
91
92
  mapError,
92
93
  decodeText,
@@ -97,15 +98,14 @@ import {
97
98
  withDefault,
98
99
  option,
99
100
  String2
100
- } from "./chunk-xgwjcq4z.js";
101
+ } from "./chunk-cy5fbrfm.js";
101
102
  import {
102
- currentTimeMillis,
103
103
  SecureRandom,
104
104
  layerWebCrypto,
105
105
  runMain,
106
106
  Stdio,
107
107
  Terminal,
108
- layer,
108
+ layer3,
109
109
  error,
110
110
  log,
111
111
  toIso,
@@ -141,7 +141,7 @@ import {
141
141
  HttpClient,
142
142
  execute,
143
143
  Fetch,
144
- layer2,
144
+ layer4,
145
145
  runDisplayLabels,
146
146
  listedSummary,
147
147
  defaultKitName,
@@ -197,7 +197,7 @@ import {
197
197
  harnessNames,
198
198
  herdrRunnerCapabilities2,
199
199
  declaredChecks
200
- } from "./chunk-m32wb6t0.js";
200
+ } from "./chunk-qhpyzn7c.js";
201
201
  import {
202
202
  Id
203
203
  } from "./chunk-4kssrezn.js";
@@ -214,7 +214,7 @@ import {
214
214
  import {
215
215
  ChildProcessSpawner,
216
216
  make3
217
- } from "./chunk-mmetyep8.js";
217
+ } from "./chunk-5tfxtw9z.js";
218
218
 
219
219
  // apps/cli/src/cli-error.ts
220
220
  function cliErrorCode(error, status) {
@@ -504,10 +504,10 @@ var checkDockerImageSetting = pinnedImage;
504
504
  var checkRegistryImageSetting = pinnedImage;
505
505
  var herdrCoreSession = (runnerId, personal) => personal ? undefined : `kitman-${sha2562(runnerId).slice(0, 16)}`;
506
506
  var OpenHerdrCore = Reference("kitman/cli/OpenHerdrCore", {
507
- defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-mtgkvbk4.js")), ({ HerdrCore, herdrCoreLayer }) => provide3(service(HerdrCore), herdrCoreLayer(options)))
507
+ defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-fmhy6tss.js")), ({ HerdrCore, herdrCoreLayer }) => provide3(service(HerdrCore), herdrCoreLayer(options)))
508
508
  });
509
509
  var UpdateHerdrCore = Reference("kitman/cli/UpdateHerdrCore", {
510
- defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-mtgkvbk4.js")), (module) => module.updateHerdrCore(options))
510
+ defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-fmhy6tss.js")), (module) => module.updateHerdrCore(options))
511
511
  });
512
512
  var herdrCoreMissing = (error) => {
513
513
  if (isTagged(error, "HerdrCoreMissing"))
@@ -733,7 +733,7 @@ var syncTargets = (harness) => gen(function* () {
733
733
  });
734
734
  var syncKits = (input) => gen(function* () {
735
735
  const fs = yield* FileSystem;
736
- const { syncKitSetup } = yield* promise(() => import("./chunk-eerh2t20.js"));
736
+ const { syncKitSetup } = yield* promise(() => import("./chunk-mjzvfh9d.js"));
737
737
  const harnesses = yield* syncTargets(input.harness);
738
738
  const chain = yield* input.client.getKitChain(input.workspaceId);
739
739
  for (const { name, problem } of chain.skipped)
@@ -765,7 +765,7 @@ var syncKits = (input) => gen(function* () {
765
765
 
766
766
  // apps/cli/src/assets.ts
767
767
  function send(request, failure) {
768
- return execute(request).pipe(mapError2((error) => failure(error.cause ?? error)), provide3(layer2));
768
+ return execute(request).pipe(mapError2((error) => failure(error.cause ?? error)), provide3(layer4));
769
769
  }
770
770
  function putPresignedAsset(upload, bytes) {
771
771
  return gen(function* () {
@@ -1651,7 +1651,7 @@ var package_default = {
1651
1651
  };
1652
1652
 
1653
1653
  // apps/cli/src/scaffold.ts
1654
- var cliVersion = "0.10.55";
1654
+ var cliVersion = "0.10.57";
1655
1655
  var packageJson = (name, scaffold) => `${JSON.stringify({
1656
1656
  name,
1657
1657
  private: true,
@@ -1900,7 +1900,7 @@ var Usage = [
1900
1900
  "Every run, loop, agent, verify, constraint, secret, claim, deploy, dev and kit command takes --json."
1901
1901
  ].join(`
1902
1902
  `);
1903
- var agentRuntime = promise(() => import("./chunk-dgb6s5vq.js"));
1903
+ var agentRuntime = promise(() => import("./chunk-q5s64k8g.js"));
1904
1904
  var TuiLauncher = Reference("kitman/cli/TuiLauncher", {
1905
1905
  defaultValue: () => gen(function* () {
1906
1906
  const tui = yield* tryPromise({
@@ -2746,7 +2746,7 @@ var SandboxHostProbe = Reference("kitman/cli/SandboxHostProbe", {
2746
2746
  });
2747
2747
  var OpenRunnerRpc = Reference("kitman/cli/OpenRunnerRpc", {
2748
2748
  defaultValue: () => (options) => gen(function* () {
2749
- const { makeRunnerRpcClient, runnerRpcUrl, runnerWebSocketProtocol } = yield* promise(() => import("./chunk-dkpqwk0q.js"));
2749
+ const { makeRunnerRpcClient, runnerRpcUrl, runnerWebSocketProtocol } = yield* promise(() => import("./chunk-nrkwrajj.js"));
2750
2750
  return yield* makeRunnerRpcClient({
2751
2751
  runnerId: options.runnerId,
2752
2752
  bearer: options.bearer,
@@ -2905,7 +2905,7 @@ function startCanonicalHerdrRunnerCommand(input) {
2905
2905
  sandboxBackends: host.backends,
2906
2906
  ...inSrt === undefined ? undefined : { srtBinaries: inSrt.binaries },
2907
2907
  ...docker === undefined ? undefined : { docker: { ...docker, runnerId: input.runnerId } }
2908
- }).pipe(provide2(succeed5(HerdrCore, core)), provide2(layer));
2908
+ }).pipe(provide2(succeed5(HerdrCore, core)), provide2(layer3));
2909
2909
  const activeSlots = new Set;
2910
2910
  let claimsInFlight = 0;
2911
2911
  const updater = runnerUpdater({
@@ -2986,7 +2986,7 @@ function startCanonicalHerdrRunnerCommand(input) {
2986
2986
  ...secrets.length === 0 ? undefined : { secrets }
2987
2987
  });
2988
2988
  };
2989
- const storage = yield* provide3(service(HttpClient), layer2);
2989
+ const storage = yield* provide3(service(HttpClient), layer4);
2990
2990
  const runAgentStep = agentStepExecutor({
2991
2991
  rootDir: path.join(runnerRootDir, ".kitman"),
2992
2992
  sandbox,
@@ -3104,7 +3104,7 @@ function startCanonicalHerdrRunnerCommand(input) {
3104
3104
  });
3105
3105
  return yield* raceFirst(stopWhenRefused(supervised), _await(updated));
3106
3106
  }));
3107
- }).pipe(ensuring2(ignore(controlPlane.client.stopRunnerReplica(input.runnerId, replica.id))), provide3(provideMerge(root, layer)));
3107
+ }).pipe(ensuring2(ignore(controlPlane.client.stopRunnerReplica(input.runnerId, replica.id))), provide3(provideMerge(root, layer3)));
3108
3108
  }).pipe(scoped, catchTag("RunnerStopped", ({ problem }) => error(`Runner stopped (${problem.code}): ${problem.message}
3109
3109
  Fix: ${problem.fix}`)));
3110
3110
  }
@@ -3130,7 +3130,7 @@ function mcpCommand(args) {
3130
3130
  if (command.action === "run") {
3131
3131
  if (command.args.length > 0)
3132
3132
  return yield* new CliError({ message: `Unknown command: ${args.join(" ")}` });
3133
- const { runMcpServerCommand } = yield* promise(() => import("./chunk-q0yna8sw.js"));
3133
+ const { runMcpServerCommand } = yield* promise(() => import("./chunk-h8s4vh47.js"));
3134
3134
  return yield* runMcpServerCommand({ flags: command.flags });
3135
3135
  }
3136
3136
  if (command.action !== "setup")
@@ -4332,9 +4332,9 @@ function claimCommand(args) {
4332
4332
  }
4333
4333
  });
4334
4334
  }
4335
- var KitWriter = map8(promise(() => import("./chunk-axdmbr61.js")), (build) => build.writeKit);
4335
+ var KitWriter = map8(promise(() => import("./chunk-v43h8s08.js")), (build) => build.writeKit);
4336
4336
  var KitBuilder = Reference("kitman/cli/KitBuilder", {
4337
- defaultValue: () => (directory) => flatMap3(promise(() => import("./chunk-axdmbr61.js")), (build) => build.buildKit(directory))
4337
+ defaultValue: () => (directory) => flatMap3(promise(() => import("./chunk-v43h8s08.js")), (build) => build.buildKit(directory))
4338
4338
  });
4339
4339
  var uploadKit = (client, workspaceId, built) => gen(function* () {
4340
4340
  yield* client.uploadKitBundle(workspaceId, built.digest, { bundle: encode2(built.bundle) });
@@ -5378,7 +5378,7 @@ var runCli = (args) => {
5378
5378
  const program = runEffect(args).pipe(tapCause((cause) => {
5379
5379
  const error2 = squash(cause);
5380
5380
  return args.includes("--json") ? printJson(cliErrorJson(error2)) : error(cliErrorLine(error2));
5381
- }), provide3(layer));
5381
+ }), provide3(layer3));
5382
5382
  runMain(program, { disableErrorReporting: true });
5383
5383
  };
5384
5384
  export {
@@ -20,22 +20,22 @@ import {
20
20
  import {
21
21
  FileSystem,
22
22
  Path
23
- } from "./chunk-xgwjcq4z.js";
23
+ } from "./chunk-cy5fbrfm.js";
24
24
  import {
25
25
  tomlTableHeader2,
26
26
  tomlKeyPath2,
27
27
  kitmanSkillEntry,
28
28
  isPathWithin2
29
- } from "./chunk-5y5axze6.js";
29
+ } from "./chunk-hwd2gg2f.js";
30
30
  import {
31
31
  instructionsStart,
32
32
  instructionsEnd,
33
33
  renderMcpServer,
34
34
  materializeKitSetup,
35
35
  tomlInline
36
- } from "./chunk-m32wb6t0.js";
37
- import"./chunk-twp7aprz.js";
38
- import"./chunk-mmetyep8.js";
36
+ } from "./chunk-qhpyzn7c.js";
37
+ import"./chunk-a1yf46xt.js";
38
+ import"./chunk-5tfxtw9z.js";
39
39
 
40
40
  // packages/agent-runtime/src/kit-setup-sync.ts
41
41
  class KitSyncError extends TaggedError("KitSyncError") {
@@ -4,12 +4,12 @@ import {
4
4
  runnerRpcUrl2,
5
5
  makeRunnerRpcClient2,
6
6
  makeProgramRpcClient2
7
- } from "./chunk-5j3cxsnp.js";
8
- import"./chunk-148mjppg.js";
9
- import"./chunk-m32wb6t0.js";
7
+ } from "./chunk-23vene3j.js";
8
+ import"./chunk-de4cfe40.js";
9
+ import"./chunk-qhpyzn7c.js";
10
10
  import"./chunk-4kssrezn.js";
11
11
  import"./chunk-7evwar6b.js";
12
- import"./chunk-xgwjcq4z.js";
12
+ import"./chunk-cy5fbrfm.js";
13
13
  import"./chunk-61k67vxh.js";
14
14
  export {
15
15
  makeProgramRpcClient2 as makeProgramRpcClient,
@@ -51,6 +51,7 @@ import {
51
51
  makeUnsafe6,
52
52
  provide,
53
53
  effect,
54
+ mergeAll,
54
55
  die2,
55
56
  findErrorOption,
56
57
  pretty,
@@ -160,9 +161,10 @@ import {
160
161
  secretReference
161
162
  } from "./chunk-4kssrezn.js";
162
163
  import {
163
- currentTimeMillis,
164
164
  SecureRandom,
165
165
  layerWebCrypto,
166
+ layer,
167
+ layer2,
166
168
  toDate,
167
169
  toIso,
168
170
  wallClockMillis,
@@ -221,8 +223,9 @@ import {
221
223
  installCommand,
222
224
  checkServicesFile,
223
225
  checkServices
224
- } from "./chunk-m32wb6t0.js";
226
+ } from "./chunk-qhpyzn7c.js";
225
227
  import {
228
+ currentTimeMillis,
226
229
  join,
227
230
  interrupt,
228
231
  unbounded,
@@ -243,12 +246,15 @@ import {
243
246
  runForEach,
244
247
  FileSystem,
245
248
  Path,
249
+ embeddedFile,
250
+ extractEmbeddedFile,
246
251
  optionalEnv,
247
252
  harnessesUnsupportedInSrt2,
248
253
  compiled2,
249
254
  pinnedSrtCommand2,
250
255
  pinnedSrtStepCommand2,
251
256
  runSrtCli2,
257
+ kitmanCacheDirectory2,
252
258
  srtSettings2,
253
259
  srtCacheEnvironment2,
254
260
  srtInheritedEnv2,
@@ -257,7 +263,7 @@ import {
257
263
  writeSrtSettings2,
258
264
  srtStepArgv2,
259
265
  srtArgv2
260
- } from "./chunk-xgwjcq4z.js";
266
+ } from "./chunk-cy5fbrfm.js";
261
267
  import {
262
268
  writeAgentEnvironmentConfigFile2,
263
269
  readManifestSkillPaths2,
@@ -273,8 +279,8 @@ import {
273
279
  applyAgentEnvironmentMaterialization2,
274
280
  isPathWithin2,
275
281
  skillIdentity2
276
- } from "./chunk-5y5axze6.js";
277
- import"./chunk-twp7aprz.js";
282
+ } from "./chunk-hwd2gg2f.js";
283
+ import"./chunk-a1yf46xt.js";
278
284
  import {
279
285
  sliceBytes2,
280
286
  maxLineBytes2,
@@ -282,7 +288,7 @@ import {
282
288
  decodedOption2,
283
289
  decoded2,
284
290
  readOpencode2
285
- } from "./chunk-vtn088tq.js";
291
+ } from "./chunk-jc920h47.js";
286
292
  import {
287
293
  writeSecretRegistry,
288
294
  secretRefusalLog,
@@ -294,16 +300,16 @@ import {
294
300
  rpcRunFiles,
295
301
  programHostsEnv,
296
302
  undeclaredHostsEnv
297
- } from "./chunk-g7vk5tjp.js";
298
- import"./chunk-5j3cxsnp.js";
303
+ } from "./chunk-wd0rvdt4.js";
304
+ import"./chunk-23vene3j.js";
299
305
  import {
300
306
  nextInt
301
307
  } from "./chunk-gwcqz1bj.js";
302
308
  import {
303
309
  ChildProcessSpawner,
304
310
  make3
305
- } from "./chunk-mmetyep8.js";
306
- import"./chunk-148mjppg.js";
311
+ } from "./chunk-5tfxtw9z.js";
312
+ import"./chunk-de4cfe40.js";
307
313
 
308
314
  // packages/core/src/sync-kit.ts
309
315
  import { createHash } from "crypto";
@@ -2577,8 +2583,19 @@ var prepareDockerHome = (input) => gen(function* () {
2577
2583
  }
2578
2584
  });
2579
2585
 
2580
- // packages/agent-runtime/src/docker-sandbox.ts
2586
+ // packages/agent-runtime/src/helper-scripts.ts
2581
2587
  import { fileURLToPath } from "url";
2588
+ var helperScriptPath = (name) => gen(function* () {
2589
+ if (!compiled2)
2590
+ return fileURLToPath(import.meta.resolve(`./${name}`));
2591
+ const path = yield* Path;
2592
+ const file = embeddedFile(Bun.embeddedFiles, name.replace(/\.ts$/, ""));
2593
+ if (file === undefined)
2594
+ return yield* die3(new Error(`This Runner was compiled without ${name}`));
2595
+ return yield* extractEmbeddedFile(path.join(yield* kitmanCacheDirectory2, "helper-scripts"), file, name);
2596
+ }).pipe(orDie, provide3(mergeAll(layer, layer2)));
2597
+
2598
+ // packages/agent-runtime/src/docker-sandbox.ts
2582
2599
  var RunnerLabel = "kitman.runner";
2583
2600
  var StepAttemptLabel = "kitman.step-attempt";
2584
2601
  var EgressProxyImage = "oven/bun@sha256:4cf82f5686b196504fe119db3fcd9185b191f82ece82c40680e597228ec6070a";
@@ -2661,7 +2678,7 @@ var startDockerSandbox = (input) => gen(function* () {
2661
2678
  labels,
2662
2679
  mounts: [
2663
2680
  {
2664
- source: fileURLToPath(import.meta.resolve("./egress-proxy.ts")),
2681
+ source: yield* helperScriptPath("egress-proxy.ts"),
2665
2682
  target: "/kitman/egress-proxy.ts",
2666
2683
  readOnly: true
2667
2684
  }
@@ -5310,9 +5327,6 @@ var harnessesInSrt = (input) => gen(function* () {
5310
5327
  binaries: Object.fromEntries(probed.flatMap((entry) => entry.binary === undefined ? [] : [[entry.harness, entry.binary]]))
5311
5328
  };
5312
5329
  });
5313
- // packages/agent-runtime/src/check-docker.ts
5314
- import { fileURLToPath as fileURLToPath2 } from "url";
5315
-
5316
5330
  // packages/agent-runtime/src/loopback-tunnel.ts
5317
5331
  import * as net from "net";
5318
5332
 
@@ -5633,7 +5647,7 @@ var dockerCheckDaemon = (input) => ({ id, network: allowed }) => gen(function* (
5633
5647
  const proxy = allowed === "open" ? undefined : yield* gen(function* () {
5634
5648
  yield* helper(proxyContainer, [
5635
5649
  "--volume",
5636
- `${fileURLToPath2(import.meta.resolve("./egress-proxy.ts"))}:/kitman/egress-proxy.ts:ro`,
5650
+ `${yield* helperScriptPath("egress-proxy.ts")}:/kitman/egress-proxy.ts:ro`,
5637
5651
  input.proxyImage ?? EgressProxyImage,
5638
5652
  "bun",
5639
5653
  "/kitman/egress-proxy.ts",
@@ -5653,7 +5667,7 @@ var dockerCheckDaemon = (input) => ({ id, network: allowed }) => gen(function* (
5653
5667
  "--publish",
5654
5668
  `127.0.0.1::${checkDockerPort}`,
5655
5669
  "--volume",
5656
- `${fileURLToPath2(import.meta.resolve("./tcp-forwarder.ts"))}:/kitman/tcp-forwarder.ts:ro`,
5670
+ `${yield* helperScriptPath("tcp-forwarder.ts")}:/kitman/tcp-forwarder.ts:ro`,
5657
5671
  input.proxyImage ?? EgressProxyImage,
5658
5672
  "bun",
5659
5673
  "/kitman/tcp-forwarder.ts",
@@ -6040,15 +6054,14 @@ if (false)
6040
6054
  ;
6041
6055
 
6042
6056
  // packages/agent-runtime/src/verification-executor.ts
6043
- import { fileURLToPath as fileURLToPath3 } from "url";
6044
6057
  var checkTimeout = "30 minutes";
6045
6058
  var checkFilesPerVerification = 50;
6046
- var halfCloseEncoder = [process.execPath, fileURLToPath3(import.meta.resolve("./half-close-relay.ts"))];
6047
- var srtDockerTunnel = (relayPort) => srtLoopbackTunnel({
6059
+ var halfCloseListener = (encoder, listenPort, relayPort) => `BUN_BE_BUN=1 ${encoder.map(quoted).join(" ")} ${listenPort} "$HTTP_PROXY" ${relayPort}`;
6060
+ var srtDockerTunnel = (relayPort, encoder) => srtLoopbackTunnel({
6048
6061
  service: "Docker daemon",
6049
6062
  hostPort: relayPort,
6050
6063
  listenPort: checkDockerPort,
6051
- listener: `${halfCloseEncoder.map(quoted).join(" ")} ${checkDockerPort} "$HTTP_PROXY" ${relayPort}`,
6064
+ listener: halfCloseListener(encoder, checkDockerPort, relayPort),
6052
6065
  probe: String.raw`printf 'GET /_ping HTTP/1.0\r\n\r\n'`,
6053
6066
  read: "tail -c 2",
6054
6067
  answers: "OK"
@@ -6088,7 +6101,7 @@ var dockerRoute = (backend, docker) => {
6088
6101
  hosts: [`127.0.0.1:${docker.route.port}`],
6089
6102
  unixSockets: [],
6090
6103
  services: [],
6091
- tunnel: srtDockerTunnel(docker.route.port)
6104
+ tunnel: srtDockerTunnel(docker.route.port, docker.route.encoder)
6092
6105
  };
6093
6106
  case "direct":
6094
6107
  throw new Error("A pipeline check in srt reaches its daemon through a socket or the relay, never directly.");
@@ -6130,13 +6143,14 @@ var postgresRoute = (backend, postgres) => {
6130
6143
  tunnel: srtPostgresTunnel(postgres.hostPort)
6131
6144
  };
6132
6145
  };
6133
- var checkSandboxPolicy = (work, sandbox, checkout, cache, filesDir, postgresHosts, clientDir) => ({
6146
+ var checkSandboxPolicy = (work, sandbox, checkout, cache, filesDir, postgresHosts, docker) => ({
6134
6147
  ...runnerStateSandboxPolicy(sandbox.runner, [
6135
6148
  repositoryClone(sandbox.runner.workRoot, work.repoBinding.id),
6136
6149
  checkout,
6137
- ...clientDir === undefined ? [] : [clientDir, ...halfCloseEncoder]
6150
+ ...docker === undefined ? [] : [docker.clientDir],
6151
+ ...docker?.route.kind === "relay" ? docker.route.encoder : []
6138
6152
  ]),
6139
- writablePaths: [checkout, cache, filesDir, ...clientDir === undefined ? [] : [clientDir]],
6153
+ writablePaths: [checkout, cache, filesDir, ...docker === undefined ? [] : [docker.clientDir]],
6140
6154
  network: verificationNetworkAllowlist({
6141
6155
  apiUrl: sandbox.apiUrl,
6142
6156
  storageOrigin: work.storageOrigin,
@@ -6164,7 +6178,7 @@ var checkRunner = (work, sandbox, cache, inherited) => (checkout) => ({ command,
6164
6178
  }
6165
6179
  const route = postgresRoute(sandbox.backend, postgres);
6166
6180
  const daemon = dockerRoute(sandbox.backend, docker);
6167
- const policy = checkSandboxPolicy(work, sandbox, checkout, cache, filesDir, [...route.hosts, ...daemon.hosts], docker?.clientDir);
6181
+ const policy = checkSandboxPolicy(work, sandbox, checkout, cache, filesDir, [...route.hosts, ...daemon.hosts], docker);
6168
6182
  const [tunnel, ...innerTunnels] = [route.tunnel, daemon.tunnel].filter((script) => script !== undefined);
6169
6183
  const tunnelled = innerTunnels.reduceRight((inner, script) => `sh -c ${quoted(script)} sh ${quoted(inner)}`, command);
6170
6184
  const sandboxCommand = {
@@ -6266,7 +6280,8 @@ var pipelineDaemon = (services, check) => gen(function* () {
6266
6280
  const { port } = yield* decodeListeningPort(relay.address()).pipe(mapError2(() => new ServicesUnavailable({
6267
6281
  reason: `The pipeline check ${check} cannot reach its Docker daemon: its relay has no port`
6268
6282
  })));
6269
- return { ...started, clientDir, route: { kind: "relay", port } };
6283
+ const encoder = [process.execPath, yield* helperScriptPath("half-close-relay.ts")];
6284
+ return { ...started, clientDir, route: { kind: "relay", port, encoder } };
6270
6285
  }
6271
6286
  return {
6272
6287
  ...started,
@@ -6592,6 +6607,7 @@ export {
6592
6607
  firstMessage,
6593
6608
  gitCheckouts2 as gitCheckouts,
6594
6609
  gitRemote,
6610
+ halfCloseListener,
6595
6611
  harnessAdapter,
6596
6612
  harnessConfigUnwritable,
6597
6613
  harnessesInSrt,
@@ -6610,6 +6626,7 @@ export {
6610
6626
  isPathWithin2 as isPathWithin,
6611
6627
  kitMcpHosts,
6612
6628
  kitmanBundles,
6629
+ kitmanCacheDirectory2 as kitmanCacheDirectory,
6613
6630
  kitmanMcpPreflight,
6614
6631
  kitmanMcpToolTimeout,
6615
6632
  kitmanMcpToolTimeoutSeconds,
@@ -6623,6 +6640,7 @@ export {
6623
6640
  orphanedCheckPostgres,
6624
6641
  pinnedSrtCommand2 as pinnedSrtCommand,
6625
6642
  pinnedSrtStepCommand2 as pinnedSrtStepCommand,
6643
+ pipelineDaemon,
6626
6644
  postgresSocketForwarder,
6627
6645
  prepareHarness,
6628
6646
  previewAgentEnvironmentConfigSync,
@@ -84,8 +84,6 @@ import {
84
84
  DisablePropagation,
85
85
  sync,
86
86
  map7,
87
- ClockRef,
88
- currentTimeMillis2,
89
87
  ConsoleRef,
90
88
  succeed3,
91
89
  fail4,
@@ -252,6 +250,8 @@ import {
252
250
  import {
253
251
  map,
254
252
  makeEquivalence,
253
+ Clock,
254
+ currentTimeMillis,
255
255
  bytes,
256
256
  BadArgument,
257
257
  systemError,
@@ -315,7 +315,7 @@ import {
315
315
  String2,
316
316
  optionalEnv,
317
317
  harnessesUnsupportedInSrt2
318
- } from "./chunk-xgwjcq4z.js";
318
+ } from "./chunk-cy5fbrfm.js";
319
319
  import {
320
320
  isDateTime,
321
321
  Numeric,
@@ -355,15 +355,11 @@ import {
355
355
  make3,
356
356
  parseFdName,
357
357
  fdName
358
- } from "./chunk-mmetyep8.js";
358
+ } from "./chunk-5tfxtw9z.js";
359
359
 
360
360
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Tuple.js
361
361
  var makeEquivalence3 = Tuple;
362
362
 
363
- // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Clock.js
364
- var Clock = ClockRef;
365
- var currentTimeMillis = currentTimeMillis2;
366
-
367
363
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/internal/dateTime.js
368
364
  var TypeId = "~effect/DateTime";
369
365
  var TimeZoneTypeId = "~effect/DateTime/TimeZone";
@@ -1756,7 +1752,7 @@ var make19 = /* @__PURE__ */ gen(function* () {
1756
1752
  });
1757
1753
  return make2(spawnCommand);
1758
1754
  });
1759
- var layer3 = /* @__PURE__ */ effect(ChildProcessSpawner, make19);
1755
+ var layer5 = /* @__PURE__ */ effect(ChildProcessSpawner, make19);
1760
1756
  var flattenCommand = (command) => {
1761
1757
  const commands = [];
1762
1758
  const pipeOptions = [];
@@ -2270,10 +2266,10 @@ var makeFileSystem = /* @__PURE__ */ map8(/* @__PURE__ */ serviceOption(WatchBac
2270
2266
  },
2271
2267
  writeFile: writeFile2
2272
2268
  }));
2273
- var layer4 = /* @__PURE__ */ effect(FileSystem)(makeFileSystem);
2269
+ var layer6 = /* @__PURE__ */ effect(FileSystem)(makeFileSystem);
2274
2270
 
2275
2271
  // node_modules/.bun/@effect+platform-bun@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-bun/dist/BunFileSystem.js
2276
- var layer5 = layer4;
2272
+ var layer = layer6;
2277
2273
 
2278
2274
  // node_modules/.bun/@effect+platform-node-shared@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-node-shared/dist/NodePath.js
2279
2275
  import * as NodePath from "path";
@@ -2308,13 +2304,13 @@ var layerWin32 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make13({
2308
2304
  ...NodePath.win32,
2309
2305
  .../* @__PURE__ */ fileUrlOps(true)
2310
2306
  }));
2311
- var layer6 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make13({
2307
+ var layer7 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make13({
2312
2308
  ...NodePath,
2313
2309
  .../* @__PURE__ */ fileUrlOps(undefined)
2314
2310
  }));
2315
2311
 
2316
2312
  // node_modules/.bun/@effect+platform-bun@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-bun/dist/BunPath.js
2317
- var layer7 = layer6;
2313
+ var layer2 = layer7;
2318
2314
 
2319
2315
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Stdio.js
2320
2316
  var TypeId3 = "~effect/Stdio";
@@ -3174,7 +3170,7 @@ function defaultShouldQuit(input) {
3174
3170
  var layer11 = layer10;
3175
3171
 
3176
3172
  // node_modules/.bun/@effect+platform-bun@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-bun/dist/BunServices.js
3177
- var layer = /* @__PURE__ */ layer3.pipe(/* @__PURE__ */ provideMerge(/* @__PURE__ */ mergeAll(layer5, layer7, layer9, layer11)));
3173
+ var layer3 = /* @__PURE__ */ layer5.pipe(/* @__PURE__ */ provideMerge(/* @__PURE__ */ mergeAll(layer, layer2, layer9, layer11)));
3178
3174
 
3179
3175
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Console.js
3180
3176
  var Console = ConsoleRef;
@@ -3434,6 +3430,7 @@ function classifyAnything(key, value) {
3434
3430
  const text = value.replace(uuidPattern, "uuid");
3435
3431
  return VALUE_RULES.find(([, pattern]) => pattern.test(text))?.[0];
3436
3432
  }
3433
+ var durableTextLimit = 1024;
3437
3434
  function scanDurableSurface(value, path = "surface", options = {}) {
3438
3435
  const findings = [];
3439
3436
  scanValue(value, path, undefined, findings, 0, options);
@@ -3477,7 +3474,7 @@ function scanValue(value, path, key, findings, depth, options = {}) {
3477
3474
  const classification = classifyDurableSurfaceValue(key ?? path, value, options);
3478
3475
  if (classification !== undefined)
3479
3476
  findings.push(finding(path, classification, value));
3480
- else if (isString(value) && value.length > (options.maxTextLength ?? 1024))
3477
+ else if (isString(value) && value.length > (options.maxTextLength ?? durableTextLimit))
3481
3478
  findings.push(finding(path, "unknown", value, "unbounded-text"));
3482
3479
  }
3483
3480
  function finding(path, classification, value, rule = "classified-key") {
@@ -10125,7 +10122,7 @@ var fetch2 = /* @__PURE__ */ make27((request, url, signal, fiber) => {
10125
10122
  }
10126
10123
  return send(undefined);
10127
10124
  });
10128
- var layer2 = /* @__PURE__ */ layerMergedContext(/* @__PURE__ */ succeed6(fetch2));
10125
+ var layer4 = /* @__PURE__ */ layerMergedContext(/* @__PURE__ */ succeed6(fetch2));
10129
10126
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/socket/Socket.js
10130
10127
  var TypeId14 = "~effect/socket/Socket";
10131
10128
  var Socket = /* @__PURE__ */ Service2("effect/socket/Socket");
@@ -10867,7 +10864,7 @@ var collectorHttpClient = effect(HttpClient)(map8(HttpClient, (client) => transf
10867
10864
  description: `The collector did not answer in ${collectorTimeout}`
10868
10865
  })
10869
10866
  }))
10870
- })))).pipe(provide2(layer2));
10867
+ })))).pipe(provide2(layer4));
10871
10868
  var metricLabels = new Map;
10872
10869
  // packages/core/src/run-display.ts
10873
10870
  var runDisplayLabels = {
@@ -14606,7 +14603,7 @@ function stringValue(value) {
14606
14603
  // node_modules/.bun/@effect+platform-node-shared@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-node-shared/dist/NodeCrypto.js
14607
14604
  var layerSecureRandom = layerWebCrypto;
14608
14605
  // apps/mcp/src/platform.ts
14609
- var McpPlatformLive = mergeAll(layerSecureRandom, layer5, layer7);
14606
+ var McpPlatformLive = mergeAll(layerSecureRandom, layer, layer2);
14610
14607
  function runMcpEffect(effect) {
14611
14608
  return runPromise(provide3(effect, McpPlatformLive));
14612
14609
  }
@@ -15456,4 +15453,4 @@ function checkServices(declaration) {
15456
15453
  return isSome(decoded) ? [...new Set(decoded.value.services)] : undefined;
15457
15454
  }
15458
15455
 
15459
- export { Clock, currentTimeMillis, WebCrypto, SecureRandom, layerWebCrypto, makeUnsafe, formatIso, empty, fromInput, merge, runMain, Stdio, Terminal, layer, error, log, toDate, parseDate, toIso, currentDate, wallClockMillis, waitingOnWords, queueWords, scanDurableSurface, redactResponseSurface, redactCredentials, redactedOutputTail, SafeJson, AgentHarnessIds, AgentSkillRequirement, AgentMcpServerRequirement, AgentEnvironmentFragment, findForbiddenAgentEnvironmentSecretPath, RepoBindingProviders, RepoBindingCredentialProviderTypes, findForbiddenRepoBindingSecretPath, AgentSandboxNetwork, runnerAgentSandboxPolicy, agentNetworkAllowlist, verificationNetworkAllowlist, programNetworkHosts, ContextPackModes, DefaultContextPackMode, ProposalStatuses, ProposalTargetTypes, canonicalJson, canonicalSha256, AgentEfforts, AgentCapabilities, LoopDataSchemaRef, RunDisplayStates, LoopVersion, ProgramLoop, AgentFallback, ProgramWorkUnit, MeasureSample, MeasureEvidence, catchUpPathLimit, CatchUp, RunnerOwnership, defaultRunnerCapabilities, MemoryStatuses, MemoryScopes, MaxMemoryListLimit, DecisionStatuses, Session, SessionEnd, SessionUpdate, SessionUpdateCreate, FixFlowRecoveryActions, KitmanAgentCapabilityNames, sha2562, isRunFileRefusalReason, runFileRefusalWords, RunFileRefused, runFileContentType, repositoryKey, createId, digestSha256, digestSha512, digestWith, sha256Hasher, AgentEvent, raw, make5, get, put, setHeaders, bodyUint8Array, schemaBodyJson, filterStatusOk, HttpClient, execute, get2, Fetch, layer2, Socket, SocketReadError, SocketError, WebSocketConstructor, layerWebSocketConstructorGlobal, layerWebSocket, runDisplayLabels, listedSummary, KitName, KitDigest, defaultKitName, KitSetup, SetupArchive, kitMcpSecretNames, kitmanMcpServer, KitmanClientError, KitmanEffectClient, CliError, DefaultApiUrl, resolveConfig, apiUrlFromEnv, stepCredentialFromEnv, stepWorkspaceFromEnv, stepSkillsDirFromEnv, stepFittingSkillsFromEnv, stepOutputOnlyFromEnv, mcpCredentialNameFromEnv, userConfigPath, userAuthPath, userHarnessSyncPath, kitSetupCacheDir, bundleCacheDir, localConfigPath, readUserConfig, writeUserConfig, sessionForApi, readAuthStore, storeSession, removeSession, removeAllSessions, agentCredentialForApi, storeAgentCredential, removeAgentCredential, normalizeApiUrl, isStoredAgentCredential, isStreamSchema, getStreamSchemas, make6, exitSchema, ParseOptions, RpcClientDefect, RpcClientError, make7, Service, RunnerHeaders, RunnerRpcProtocolVersion, RunnerRpcError, RunSettled, UpdateAvailable, RunnerReplicaRpcs, RunnerRunFileRpcs, ProgramRpcs, parseCallbackUrl, revokeToken, toStoredSession, browserLogin, openBrowser, shouldRefresh, createSdkClient, refreshSession, AgentAuthClientError, executeAgentCapability, createAgentAuthBearerToken, McpPlatformLive, runMcpEffect, createAgentAuthSignedFetch, setupMcpAgentCredential, generateAgentKeyPair, HERDR_CORE_GENERATION2, HERDR_CORE_INSTALL_COMMAND2, HerdrCoreMissing2, HerdrCoreIncompatible2, HerdrCoreConnectionLost2, HerdrCoreRpcError2, HerdrCoreUpdateFailed2, HerdrCore2, herdrCoreLayer2, herdrCoreTransportLayer2, updateHerdrCore2, CommandFailed2, runCommand2, withoutPreloads2, shellOutputTailChars2, runProcess2, CommandRunner2, runShell2, detectHarnesses2, kitHarnesses, isKitHarness, instructionsStart, instructionsEnd, harnessNames, renderMcpServer, materializeKitSetup, tomlInline, herdrExecutionExtension2, herdrNativeExtensionIds2, herdrRunnerCapabilitiesForRepoBinding2, herdrRunnerCapabilities2, assertHerdrRunnerCapability2, declaredChecks, installCommand, checkServicesFile, checkServices };
15456
+ export { WebCrypto, SecureRandom, layerWebCrypto, makeUnsafe, formatIso, empty, fromInput, merge, runMain, layer, layer2, Stdio, Terminal, layer3, error, log, toDate, parseDate, toIso, currentDate, wallClockMillis, waitingOnWords, queueWords, scanDurableSurface, redactResponseSurface, redactCredentials, redactedOutputTail, SafeJson, AgentHarnessIds, AgentSkillRequirement, AgentMcpServerRequirement, AgentEnvironmentFragment, findForbiddenAgentEnvironmentSecretPath, RepoBindingProviders, RepoBindingCredentialProviderTypes, findForbiddenRepoBindingSecretPath, AgentSandboxNetwork, runnerAgentSandboxPolicy, agentNetworkAllowlist, verificationNetworkAllowlist, programNetworkHosts, ContextPackModes, DefaultContextPackMode, ProposalStatuses, ProposalTargetTypes, canonicalJson, canonicalSha256, AgentEfforts, AgentCapabilities, LoopDataSchemaRef, RunDisplayStates, LoopVersion, ProgramLoop, AgentFallback, ProgramWorkUnit, MeasureSample, MeasureEvidence, catchUpPathLimit, CatchUp, RunnerOwnership, defaultRunnerCapabilities, MemoryStatuses, MemoryScopes, MaxMemoryListLimit, DecisionStatuses, Session, SessionEnd, SessionUpdate, SessionUpdateCreate, FixFlowRecoveryActions, KitmanAgentCapabilityNames, sha2562, isRunFileRefusalReason, runFileRefusalWords, RunFileRefused, runFileContentType, repositoryKey, createId, digestSha256, digestSha512, digestWith, sha256Hasher, AgentEvent, raw, make5, get, put, setHeaders, bodyUint8Array, schemaBodyJson, filterStatusOk, HttpClient, execute, get2, Fetch, layer4, Socket, SocketReadError, SocketError, WebSocketConstructor, layerWebSocketConstructorGlobal, layerWebSocket, runDisplayLabels, listedSummary, KitName, KitDigest, defaultKitName, KitSetup, SetupArchive, kitMcpSecretNames, kitmanMcpServer, KitmanClientError, KitmanEffectClient, CliError, DefaultApiUrl, resolveConfig, apiUrlFromEnv, stepCredentialFromEnv, stepWorkspaceFromEnv, stepSkillsDirFromEnv, stepFittingSkillsFromEnv, stepOutputOnlyFromEnv, mcpCredentialNameFromEnv, userConfigPath, userAuthPath, userHarnessSyncPath, kitSetupCacheDir, bundleCacheDir, localConfigPath, readUserConfig, writeUserConfig, sessionForApi, readAuthStore, storeSession, removeSession, removeAllSessions, agentCredentialForApi, storeAgentCredential, removeAgentCredential, normalizeApiUrl, isStoredAgentCredential, isStreamSchema, getStreamSchemas, make6, exitSchema, ParseOptions, RpcClientDefect, RpcClientError, make7, Service, RunnerHeaders, RunnerRpcProtocolVersion, RunnerRpcError, RunSettled, UpdateAvailable, RunnerReplicaRpcs, RunnerRunFileRpcs, ProgramRpcs, parseCallbackUrl, revokeToken, toStoredSession, browserLogin, openBrowser, shouldRefresh, createSdkClient, refreshSession, AgentAuthClientError, executeAgentCapability, createAgentAuthBearerToken, McpPlatformLive, runMcpEffect, createAgentAuthSignedFetch, setupMcpAgentCredential, generateAgentKeyPair, HERDR_CORE_GENERATION2, HERDR_CORE_INSTALL_COMMAND2, HerdrCoreMissing2, HerdrCoreIncompatible2, HerdrCoreConnectionLost2, HerdrCoreRpcError2, HerdrCoreUpdateFailed2, HerdrCore2, herdrCoreLayer2, herdrCoreTransportLayer2, updateHerdrCore2, CommandFailed2, runCommand2, withoutPreloads2, shellOutputTailChars2, runProcess2, CommandRunner2, runShell2, detectHarnesses2, kitHarnesses, isKitHarness, instructionsStart, instructionsEnd, harnessNames, renderMcpServer, materializeKitSetup, tomlInline, herdrExecutionExtension2, herdrNativeExtensionIds2, herdrRunnerCapabilitiesForRepoBinding2, herdrRunnerCapabilities2, assertHerdrRunnerCapability2, declaredChecks, installCommand, checkServicesFile, checkServices };
@@ -35,14 +35,6 @@ import {
35
35
  } from "./chunk-61k67vxh.js";
36
36
  import"./chunk-4kssrezn.js";
37
37
  import"./chunk-7evwar6b.js";
38
- import {
39
- decodeText,
40
- mkString,
41
- FileSystem,
42
- Path,
43
- withDefault,
44
- String2
45
- } from "./chunk-xgwjcq4z.js";
46
38
  import {
47
39
  SecureRandom,
48
40
  layerWebCrypto,
@@ -51,26 +43,34 @@ import {
51
43
  schemaBodyJson,
52
44
  filterStatusOk,
53
45
  get2,
54
- layer2,
46
+ layer4,
55
47
  kitmanMcpServer,
56
48
  RunnerRpcProtocolVersion
57
- } from "./chunk-m32wb6t0.js";
49
+ } from "./chunk-qhpyzn7c.js";
50
+ import {
51
+ decodeText,
52
+ mkString,
53
+ FileSystem,
54
+ Path,
55
+ withDefault,
56
+ String2
57
+ } from "./chunk-cy5fbrfm.js";
58
58
  import {
59
59
  Packument,
60
60
  tarballMatches
61
- } from "./chunk-twp7aprz.js";
62
- import"./chunk-5j3cxsnp.js";
61
+ } from "./chunk-a1yf46xt.js";
62
+ import"./chunk-23vene3j.js";
63
63
  import {
64
64
  AgentDeclaration,
65
65
  KitDeclarations,
66
66
  describeFlag,
67
67
  Described
68
- } from "./chunk-g7vk5tjp.js";
68
+ } from "./chunk-wd0rvdt4.js";
69
69
  import {
70
70
  ChildProcessSpawner,
71
71
  make3
72
- } from "./chunk-mmetyep8.js";
73
- import"./chunk-148mjppg.js";
72
+ } from "./chunk-5tfxtw9z.js";
73
+ import"./chunk-de4cfe40.js";
74
74
 
75
75
  // packages/sdk/src/build/index.ts
76
76
  class DependencyInstallFailed extends TaggedError2()("DependencyInstallFailed", {
@@ -229,7 +229,7 @@ var fetchNpm = (name, wanted, what) => gen(function* () {
229
229
  if (!extracted.ok)
230
230
  return yield* failed(`the tarball does not extract: ${failure(extracted)}`);
231
231
  return yield* confined(directory, "package", what);
232
- }).pipe(provide3(layer2));
232
+ }).pipe(provide3(layer4));
233
233
  var sourceTree = (directory, source, what, checkouts) => gen(function* () {
234
234
  switch (source.kind) {
235
235
  case "local_path":
@@ -80,7 +80,6 @@ import {
80
80
  guard
81
81
  } from "./chunk-4kssrezn.js";
82
82
  import {
83
- currentTimeMillis,
84
83
  WebCrypto,
85
84
  SafeJson,
86
85
  AgentSandboxNetwork,
@@ -105,11 +104,12 @@ import {
105
104
  KitDigest,
106
105
  KitSetup,
107
106
  RunnerRpcError
108
- } from "./chunk-m32wb6t0.js";
107
+ } from "./chunk-qhpyzn7c.js";
109
108
  import {
109
+ currentTimeMillis,
110
110
  runForEach,
111
111
  FileSystem
112
- } from "./chunk-xgwjcq4z.js";
112
+ } from "./chunk-cy5fbrfm.js";
113
113
 
114
114
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/crypto/internal/webCrypto.js
115
115
  var subtleUnavailable = () => new Error("crypto.subtle is unavailable; browsers expose it only in secure contexts");
@@ -5,6 +5,7 @@ import {
5
5
  pinnedSrtCommand2,
6
6
  pinnedSrtStepCommand2,
7
7
  runSrtCli2,
8
+ kitmanCacheDirectory2,
8
9
  srtSettings2,
9
10
  srtCacheEnvironment2,
10
11
  srtInheritedEnv2,
@@ -13,12 +14,13 @@ import {
13
14
  writeSrtSettings2,
14
15
  srtStepArgv2,
15
16
  srtArgv2
16
- } from "./chunk-xgwjcq4z.js";
17
+ } from "./chunk-cy5fbrfm.js";
17
18
  import"./chunk-61k67vxh.js";
18
19
  export {
19
20
  compiled2 as compiled,
20
21
  harnessesUnsupportedInSrt2 as harnessesUnsupportedInSrt,
21
22
  inheritedEnvironment2 as inheritedEnvironment,
23
+ kitmanCacheDirectory2 as kitmanCacheDirectory,
22
24
  pinnedSrtCommand2 as pinnedSrtCommand,
23
25
  pinnedSrtStepCommand2 as pinnedSrtStepCommand,
24
26
  runSrtCli2 as runSrtCli,
package/dist/index.js CHANGED
@@ -5,15 +5,15 @@
5
5
  var args = process.argv.slice(2);
6
6
  if (args[0] === "srt") {
7
7
  process.argv.splice(2, 1);
8
- const { runSrtCli } = await import("./chunk-wczs5vrq.js");
8
+ const { runSrtCli } = await import("./chunk-x3mgznk2.js");
9
9
  await runSrtCli();
10
10
  } else if (args[0] === "srt-step") {
11
11
  const { runSrtStep } = await import("./chunk-99ver3za.js");
12
12
  await runSrtStep(args.slice(1));
13
13
  } else if (args[0] === "opencode-read") {
14
- const { runOpencodeReader } = await import("./chunk-rjfxnk05.js");
14
+ const { runOpencodeReader } = await import("./chunk-253add07.js");
15
15
  runOpencodeReader();
16
16
  } else {
17
- const { runCli } = await import("./chunk-dj7pp4w4.js");
17
+ const { runCli } = await import("./chunk-kyqsbr2n.js");
18
18
  runCli(args);
19
19
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kitman-sh/cli",
3
- "version": "0.10.55",
3
+ "version": "0.10.57",
4
4
  "type": "module",
5
5
  "license": "UNLICENSED",
6
6
  "bin": {