@kitman-sh/cli 0.45.0 → 0.46.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.
Files changed (28) hide show
  1. package/dist/{chunk-tqv14b4c.js → chunk-0511zsxk.js} +429 -54
  2. package/dist/{chunk-9qvgbp6k.js → chunk-16wyj1eq.js} +36 -27
  3. package/dist/{chunk-5smh4dp2.js → chunk-2xeq2a7j.js} +21 -155
  4. package/dist/{chunk-4vxbxjf8.js → chunk-5tgpa02q.js} +1 -1
  5. package/dist/{chunk-fqh4pj6b.js → chunk-6evexbdx.js} +2 -2
  6. package/dist/{chunk-8gkrs473.js → chunk-7wq13jgx.js} +3 -3
  7. package/dist/{chunk-fmvdwf5h.js → chunk-8qbem52x.js} +23 -23
  8. package/dist/{chunk-a71b15k3.js → chunk-9hqskzqc.js} +2 -2
  9. package/dist/{chunk-04wqa07j.js → chunk-apv9h5tz.js} +1 -1
  10. package/dist/{chunk-tx9aey19.js → chunk-bc40mcq9.js} +17 -17
  11. package/dist/{chunk-0dfg674z.js → chunk-c6pnj2aj.js} +4 -4
  12. package/dist/{chunk-zx86g3dw.js → chunk-e1v0c57f.js} +7 -7
  13. package/dist/{chunk-f957cxrx.js → chunk-j0b47jdz.js} +3 -3
  14. package/dist/{chunk-9ykh05hz.js → chunk-k1fdsn2c.js} +1 -1
  15. package/dist/{chunk-es6rnmyw.js → chunk-m5wqyzhk.js} +3 -3
  16. package/dist/{chunk-tfwgeqx5.js → chunk-mxy4wzhs.js} +4 -4
  17. package/dist/{chunk-n3jpxd14.js → chunk-n00cpb86.js} +2 -2
  18. package/dist/{chunk-k462v2v7.js → chunk-n381rqax.js} +157 -13
  19. package/dist/{chunk-qzwsh96c.js → chunk-nyagtr2t.js} +2 -2
  20. package/dist/{chunk-69y8j7fs.js → chunk-pty4b78m.js} +189 -16
  21. package/dist/{chunk-5pjbxhxy.js → chunk-qfwhsqej.js} +3 -3
  22. package/dist/{chunk-g26y214g.js → chunk-qy0enebe.js} +4 -4
  23. package/dist/{chunk-k7eh8tac.js → chunk-t2x4p5sp.js} +4 -4
  24. package/dist/{chunk-e3dv8hzy.js → chunk-tsw66qp3.js} +1 -1
  25. package/dist/{chunk-yyz9xrc1.js → chunk-w0tzm3fg.js} +6 -6
  26. package/dist/{chunk-5gbt1vhm.js → chunk-x38fytew.js} +87 -21
  27. package/dist/index.js +4 -4
  28. package/package.json +1 -1
@@ -109,7 +109,7 @@ import {
109
109
  decodeJsonStringOption,
110
110
  encodeJsonStringSync,
111
111
  encodePrettyJsonString
112
- } from "./chunk-k462v2v7.js";
112
+ } from "./chunk-n381rqax.js";
113
113
  import {
114
114
  currentTimeMillis,
115
115
  tap,
@@ -122,7 +122,11 @@ import {
122
122
  withDefault,
123
123
  option,
124
124
  String2
125
- } from "./chunk-5smh4dp2.js";
125
+ } from "./chunk-2xeq2a7j.js";
126
+ import {
127
+ ChildProcessSpawner,
128
+ make2
129
+ } from "./chunk-6evexbdx.js";
126
130
  import {
127
131
  SecureRandom,
128
132
  layerWebCrypto,
@@ -160,6 +164,7 @@ import {
160
164
  outlineText,
161
165
  outlineMermaid,
162
166
  runOutlineText,
167
+ answerAccepts,
163
168
  RunDisplayStates,
164
169
  RunnerExecutionBackend,
165
170
  PinnedImage,
@@ -252,15 +257,11 @@ import {
252
257
  harnessNames,
253
258
  herdrRunnerCapabilities2,
254
259
  declaredChecks
255
- } from "./chunk-69y8j7fs.js";
256
- import {
257
- ChildProcessSpawner,
258
- make2
259
- } from "./chunk-fqh4pj6b.js";
260
+ } from "./chunk-pty4b78m.js";
260
261
  import {
261
262
  Id,
262
263
  Timestamp
263
- } from "./chunk-4vxbxjf8.js";
264
+ } from "./chunk-5tgpa02q.js";
264
265
 
265
266
  // apps/cli/src/cli-error.ts
266
267
  function cliErrorCode(error, status) {
@@ -1328,10 +1329,10 @@ var sandboxMissing = (sandbox, missing) => ({
1328
1329
  var personalCheckBackend = (agentSandbox, dockerAvailable) => agentSandbox === "srt" || agentSandbox === "docker" && dockerAvailable ? agentSandbox : undefined;
1329
1330
  var herdrCoreSession = (runnerId, personal) => personal ? undefined : `kitman-${sha2562(runnerId).slice(0, 16)}`;
1330
1331
  var OpenHerdrCore = Reference("kitman/cli/OpenHerdrCore", {
1331
- defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-k7eh8tac.js")), ({ HerdrCore, herdrCoreLayer }) => provide3(service(HerdrCore), herdrCoreLayer(options)))
1332
+ defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-t2x4p5sp.js")), ({ HerdrCore, herdrCoreLayer }) => provide3(service(HerdrCore), herdrCoreLayer(options)))
1332
1333
  });
1333
1334
  var UpdateHerdrCore = Reference("kitman/cli/UpdateHerdrCore", {
1334
- defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-k7eh8tac.js")), (module) => module.updateHerdrCore(options))
1335
+ defaultValue: () => (options) => flatMap3(promise(() => import("./chunk-t2x4p5sp.js")), (module) => module.updateHerdrCore(options))
1335
1336
  });
1336
1337
  var herdrCoreMissing = (error) => {
1337
1338
  if (isTagged(error, "HerdrCoreMissing"))
@@ -1798,7 +1799,7 @@ var syncTargets = (harness) => gen(function* () {
1798
1799
  });
1799
1800
  var syncKits = (input) => gen(function* () {
1800
1801
  const fs = yield* FileSystem;
1801
- const { syncKitSetup } = yield* promise(() => import("./chunk-zx86g3dw.js"));
1802
+ const { syncKitSetup } = yield* promise(() => import("./chunk-e1v0c57f.js"));
1802
1803
  const harnesses = yield* syncTargets(input.harness);
1803
1804
  const chain = yield* input.client.getKitChain(input.workspaceId);
1804
1805
  for (const { name, problem } of chain.skipped)
@@ -2007,13 +2008,14 @@ var questionLines = (question) => {
2007
2008
  }),
2008
2009
  ...recommended !== undefined && !options.includes(recommended) ? [` Recommended: ${recommended}`, ...reason === undefined ? [] : [indent(`Why: ${reason}`, " ")]] : [],
2009
2010
  ...question.informationOnly === true && reason !== undefined ? [` No recommendation: ${reason}`] : [],
2010
- ...options.length > 0 && question.freeText === true ? [" Or answer in your own words."] : []
2011
+ ...options.length > 0 && question.freeText === true ? [" Or answer in your own words."] : [],
2012
+ ...question.answerSchema === undefined ? [] : [indent(`Answer in JSON: ${answerAccepts(question.answerSchema)}`, " ")]
2011
2013
  ];
2012
2014
  };
2013
2015
  var answerPrompt = (question) => {
2014
2016
  const count = question.options?.length ?? 0;
2015
- const choices = count === 0 ? "Your answer" : `Answer 1${count === 1 ? "" : `-${count}`}`;
2016
2017
  const recommended = enterAnswer(question);
2018
+ const choices = count > 0 ? `Answer 1${count === 1 ? "" : `-${count}`}` : question.answerSchema === undefined ? "Your answer" : "Your answer, in JSON";
2017
2019
  return `${choices}${recommended === undefined ? "" : `, Enter for ${recommended}`}: `;
2018
2020
  };
2019
2021
  var readReply = (question, typed) => {
@@ -3293,7 +3295,7 @@ var shipped_steps_generated_default = {
3293
3295
  };
3294
3296
 
3295
3297
  // apps/cli/src/scaffold-files.ts
3296
- var cliVersion = "0.45.0";
3298
+ var cliVersion = "0.46.0";
3297
3299
  var shippedLoopSteps = new Map(Object.entries(shipped_steps_generated_default));
3298
3300
  var loopSteps = (loop) => shippedLoopSteps.get(loop) ?? [];
3299
3301
  var replacedStep = (loop) => loopSteps(loop).find((step) => step.from === defaultKitName && step.exported?.startsWith("steps.") === true);
@@ -3558,7 +3560,7 @@ var scaffoldKit = (directory, scaffold = {}) => gen(function* () {
3558
3560
 
3559
3561
  // apps/cli/src/commands.ts
3560
3562
  var ClientId = "kitman-cli";
3561
- var agentRuntime = promise(() => import("./chunk-tx9aey19.js"));
3563
+ var agentRuntime = promise(() => import("./chunk-bc40mcq9.js"));
3562
3564
  var TuiLauncher = Reference("kitman/cli/TuiLauncher", {
3563
3565
  defaultValue: () => gen(function* () {
3564
3566
  const tui = yield* tryPromise({
@@ -5097,7 +5099,7 @@ var SandboxHostProbe = Reference("kitman/cli/SandboxHostProbe", {
5097
5099
  });
5098
5100
  var OpenRunnerRpc = Reference("kitman/cli/OpenRunnerRpc", {
5099
5101
  defaultValue: () => (options) => gen(function* () {
5100
- const { makeRunnerRpcClient, runnerRpcUrl, runnerWebSocketProtocol } = yield* promise(() => import("./chunk-yyz9xrc1.js"));
5102
+ const { makeRunnerRpcClient, runnerRpcUrl, runnerWebSocketProtocol } = yield* promise(() => import("./chunk-w0tzm3fg.js"));
5101
5103
  return yield* makeRunnerRpcClient({
5102
5104
  runnerId: options.runnerId,
5103
5105
  bearer: options.bearer,
@@ -5709,7 +5711,7 @@ function mcpCommand(args) {
5709
5711
  if (command.action === "run") {
5710
5712
  if (command.args.length > 0)
5711
5713
  return yield* new CliError({ message: `Unknown command: ${args.join(" ")}` });
5712
- const { runMcpServerCommand } = yield* promise(() => import("./chunk-fmvdwf5h.js"));
5714
+ const { runMcpServerCommand } = yield* promise(() => import("./chunk-8qbem52x.js"));
5713
5715
  return yield* runMcpServerCommand({ flags: command.flags });
5714
5716
  }
5715
5717
  if (command.action !== "setup")
@@ -6209,7 +6211,7 @@ function programLoopCommand(command) {
6209
6211
  return yield* new CliError({ message: `Unknown loop command: ${command.action}` });
6210
6212
  });
6211
6213
  }
6212
- var docsModule = promise(() => import("./chunk-e3dv8hzy.js"));
6214
+ var docsModule = promise(() => import("./chunk-tsw66qp3.js"));
6213
6215
  function docsCommand(args) {
6214
6216
  return gen(function* () {
6215
6217
  const command = parseCommand(args);
@@ -6454,18 +6456,25 @@ var launchContext = (flags) => gen(function* () {
6454
6456
  };
6455
6457
  });
6456
6458
  var questionLines2 = (questions) => questions.flatMap(questionLines);
6459
+ var refusedReplies = new Set(["answer_not_accepted", "answer_not_offered"]);
6457
6460
  var answerInTerminal = (client, runId, questions) => forEach(questions, (question, index) => gen(function* () {
6458
6461
  const progress = questions.length > 1 ? [`(${index + 1} of ${questions.length})`] : [];
6459
6462
  yield* forEach([...progress, ...questionLines(question)], (line) => log(line), {
6460
6463
  discard: true
6461
6464
  });
6462
- let reply = readReply(question, yield* promptLine(answerPrompt(question)));
6463
- while ("retry" in reply) {
6464
- yield* log(` ${reply.retry}`);
6465
- reply = readReply(question, yield* promptLine(answerPrompt(question)));
6465
+ for (;; ) {
6466
+ let reply = readReply(question, yield* promptLine(answerPrompt(question)));
6467
+ while ("retry" in reply) {
6468
+ yield* log(` ${reply.retry}`);
6469
+ reply = readReply(question, yield* promptLine(answerPrompt(question)));
6470
+ }
6471
+ const key = yield* idempotencyKey(undefined, "run-answer");
6472
+ const { answer } = reply;
6473
+ const refused = yield* client.answerRun(runId, { value: answer, question: question.id, idempotencyKey: key }).pipe(andThen2(log(`Answered ${question.stepKey}: ${answer}`)), as(undefined), catchIf((error) => error instanceof KitmanClientError && error.code === "question_not_open", (error) => log(`Not answered: ${question.stepKey} was settled while it waited here. ${error.responseMessage ?? error.message}`).pipe(as(undefined))), catchIf((error) => error instanceof KitmanClientError && refusedReplies.has(error.code ?? ""), (error) => succeed6(error instanceof KitmanClientError ? error.responseMessage ?? error.message : "")));
6474
+ if (refused === undefined)
6475
+ return;
6476
+ yield* log(` ${refused}`);
6466
6477
  }
6467
- const key = yield* idempotencyKey(undefined, "run-answer");
6468
- yield* client.answerRun(runId, { value: reply.answer, question: question.id, idempotencyKey: key }).pipe(andThen2(log(`Answered ${question.stepKey}: ${reply.answer}`)), catchIf((error) => error instanceof KitmanClientError && error.code === "question_not_open", (error) => log(`Not answered: ${question.stepKey} was settled while it waited here. ${error.responseMessage ?? error.message}`)));
6469
6478
  }), { discard: true });
6470
6479
  var claimLines = (step) => step.output === undefined ? [] : isJsonObject(toJsonValue(step.output)) ? Object.entries(toJsonObject(step.output)).map(([field, value]) => ` Claim ${field}: ${isString2(value) ? value : encodeJsonStringSync(value)}`) : [` Claim: ${encodeJsonStringSync(toJsonValue(step.output))}`];
6471
6480
  var evidenceLines = (evidence) => evidence.flatMap((entry) => {
@@ -7213,7 +7222,7 @@ function changeRequestCommand(args) {
7213
7222
  yield* log(command.action === "approve" ? `Approved ${short} of ${changeRequest.title}. A Run waiting on approval of ${short} resumes; one waiting on another head does not.` : `Requested changes to ${short} of ${changeRequest.title}`);
7214
7223
  });
7215
7224
  }
7216
- var readOutlines = (directory) => flatMap3(promise(() => import("./chunk-tqv14b4c.js")), (build) => build.readOutlines(directory)).pipe(mapError2((error) => new CliError({ message: error.message })));
7225
+ var readOutlines = (directory) => flatMap3(promise(() => import("./chunk-0511zsxk.js")), (build) => build.readOutlines(directory)).pipe(mapError2((error) => new CliError({ message: error.message })));
7217
7226
  var loopOutline = (command) => gen(function* () {
7218
7227
  const path = yield* Path;
7219
7228
  const loop = requiredArg(command, "a Loop id");
@@ -7233,9 +7242,9 @@ var loopOutline = (command) => gen(function* () {
7233
7242
  `).pipe(mapError2((error) => new CliError({ message: error.message })));
7234
7243
  yield* log(`Wrote the outline of ${loop} to ${out}`);
7235
7244
  });
7236
- var KitWriter = map9(promise(() => import("./chunk-tqv14b4c.js")), (build) => build.writeKit);
7245
+ var KitWriter = map9(promise(() => import("./chunk-0511zsxk.js")), (build) => build.writeKit);
7237
7246
  var KitBuilder = Reference("kitman/cli/KitBuilder", {
7238
- defaultValue: () => (directory) => flatMap3(promise(() => import("./chunk-tqv14b4c.js")), (build) => build.buildKit(directory))
7247
+ defaultValue: () => (directory) => flatMap3(promise(() => import("./chunk-0511zsxk.js")), (build) => build.buildKit(directory))
7239
7248
  });
7240
7249
  var uploadKit = (client, workspaceId, built) => gen(function* () {
7241
7250
  yield* client.uploadKitBundle(workspaceId, built.digest, { bundle: encode2(built.bundle) });
@@ -191,6 +191,7 @@ import {
191
191
  mapEager,
192
192
  flatMapEager,
193
193
  catchEager,
194
+ fromInputUnsafe2,
194
195
  Pointer,
195
196
  passthrough,
196
197
  transformEffect,
@@ -206,7 +207,7 @@ import {
206
207
  String4,
207
208
  toCodecStringTree,
208
209
  encodeUnknownJsonStringSync
209
- } from "./chunk-k462v2v7.js";
210
+ } from "./chunk-n381rqax.js";
210
211
 
211
212
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Iterable.js
212
213
  var headUnsafe = (self) => {
@@ -260,141 +261,6 @@ var makeEquivalence = (equivalence) => {
260
261
  var Clock = ClockRef;
261
262
  var currentTimeMillis = currentTimeMillis2;
262
263
 
263
- // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/ByteSize.js
264
- var bigint0 = /* @__PURE__ */ BigInt(0);
265
- var bigint1 = /* @__PURE__ */ BigInt(1);
266
- var decimalBase = /* @__PURE__ */ BigInt(1000);
267
- var binaryBase = /* @__PURE__ */ BigInt(1024);
268
- var decimalUnits = [{
269
- symbol: "B",
270
- factor: bigint1,
271
- names: ["B", "byte", "bytes"]
272
- }, {
273
- symbol: "kB",
274
- factor: decimalBase,
275
- names: ["kB", "kilobyte", "kilobytes"]
276
- }, {
277
- symbol: "MB",
278
- factor: decimalBase ** /* @__PURE__ */ BigInt(2),
279
- names: ["MB", "megabyte", "megabytes"]
280
- }, {
281
- symbol: "GB",
282
- factor: decimalBase ** /* @__PURE__ */ BigInt(3),
283
- names: ["GB", "gigabyte", "gigabytes"]
284
- }, {
285
- symbol: "TB",
286
- factor: decimalBase ** /* @__PURE__ */ BigInt(4),
287
- names: ["TB", "terabyte", "terabytes"]
288
- }, {
289
- symbol: "PB",
290
- factor: decimalBase ** /* @__PURE__ */ BigInt(5),
291
- names: ["PB", "petabyte", "petabytes"]
292
- }, {
293
- symbol: "EB",
294
- factor: decimalBase ** /* @__PURE__ */ BigInt(6),
295
- names: ["EB", "exabyte", "exabytes"]
296
- }, {
297
- symbol: "ZB",
298
- factor: decimalBase ** /* @__PURE__ */ BigInt(7),
299
- names: ["ZB", "zettabyte", "zettabytes"]
300
- }, {
301
- symbol: "YB",
302
- factor: decimalBase ** /* @__PURE__ */ BigInt(8),
303
- names: ["YB", "yottabyte", "yottabytes"]
304
- }, {
305
- symbol: "RB",
306
- factor: decimalBase ** /* @__PURE__ */ BigInt(9),
307
- names: ["RB", "ronnabyte", "ronnabytes"]
308
- }, {
309
- symbol: "QB",
310
- factor: decimalBase ** /* @__PURE__ */ BigInt(10),
311
- names: ["QB", "quettabyte", "quettabytes"]
312
- }];
313
- var binaryUnits = [decimalUnits[0], {
314
- symbol: "KiB",
315
- factor: binaryBase,
316
- names: ["KiB", "kibibyte", "kibibytes"]
317
- }, {
318
- symbol: "MiB",
319
- factor: binaryBase ** /* @__PURE__ */ BigInt(2),
320
- names: ["MiB", "mebibyte", "mebibytes"]
321
- }, {
322
- symbol: "GiB",
323
- factor: binaryBase ** /* @__PURE__ */ BigInt(3),
324
- names: ["GiB", "gibibyte", "gibibytes"]
325
- }, {
326
- symbol: "TiB",
327
- factor: binaryBase ** /* @__PURE__ */ BigInt(4),
328
- names: ["TiB", "tebibyte", "tebibytes"]
329
- }, {
330
- symbol: "PiB",
331
- factor: binaryBase ** /* @__PURE__ */ BigInt(5),
332
- names: ["PiB", "pebibyte", "pebibytes"]
333
- }, {
334
- symbol: "EiB",
335
- factor: binaryBase ** /* @__PURE__ */ BigInt(6),
336
- names: ["EiB", "exbibyte", "exbibytes"]
337
- }, {
338
- symbol: "ZiB",
339
- factor: binaryBase ** /* @__PURE__ */ BigInt(7),
340
- names: ["ZiB", "zebibyte", "zebibytes"]
341
- }, {
342
- symbol: "YiB",
343
- factor: binaryBase ** /* @__PURE__ */ BigInt(8),
344
- names: ["YiB", "yobibyte", "yobibytes"]
345
- }];
346
- var allUnits = [...decimalUnits, .../* @__PURE__ */ binaryUnits.slice(1)];
347
- var unitsByName = /* @__PURE__ */ new Map(/* @__PURE__ */ allUnits.flatMap((unit) => unit.names.map((name) => [name, unit])));
348
- var make = (value) => value;
349
- var invalid = (message) => {
350
- throw new Error(`Invalid ByteSize: ${message}`);
351
- };
352
- var fromNumber = (input) => {
353
- if (!Number.isSafeInteger(input) || input < 0) {
354
- return invalid(`expected a non-negative safe integer, received ${input}`);
355
- }
356
- return make(BigInt(input));
357
- };
358
- var maxSafeInteger = /* @__PURE__ */ BigInt(Number.MAX_SAFE_INTEGER);
359
- var scaleDecimal = (quantity, factor) => {
360
- const match = /^(\d+)(?:\.(\d+))?(?:e([+-]\d+))?$/.exec(quantity);
361
- if (match === null)
362
- return;
363
- const fraction = match[2] ?? "";
364
- const numerator = BigInt(match[1] + fraction) * factor;
365
- const shift = Number(match[3] ?? 0) - fraction.length;
366
- if (shift >= 0)
367
- return numerator * BigInt(10) ** BigInt(shift);
368
- const scale = BigInt(10) ** BigInt(-shift);
369
- return numerator % scale === bigint0 ? numerator / scale : undefined;
370
- };
371
- var fromStringUnsafe = (input) => {
372
- const match = /^\s*(\d+(?:\.\d+)?)\s*([A-Za-z]+)\s*$/.exec(input);
373
- if (match === null)
374
- return invalid(`unsupported syntax ${JSON.stringify(input)}`);
375
- const unit = unitsByName.get(match[2]);
376
- if (unit === undefined)
377
- return invalid(`unsupported unit ${JSON.stringify(match[2])}`);
378
- const value = scaleDecimal(match[1], unit.factor);
379
- if (value === undefined)
380
- return invalid(`${JSON.stringify(input)} does not represent an integral number of bytes`);
381
- return make(value);
382
- };
383
- var fromInputUnsafe2 = (input) => {
384
- switch (typeof input) {
385
- case "bigint":
386
- if (input < bigint0)
387
- return invalid(`expected a non-negative bigint, received ${input}`);
388
- return make(input);
389
- case "number":
390
- return fromNumber(input);
391
- case "string":
392
- return fromStringUnsafe(input);
393
- }
394
- return invalid(`unsupported input ${input}`);
395
- };
396
- var bytes = (value) => typeof value === "bigint" ? fromInputUnsafe2(value) : fromNumber(value);
397
-
398
264
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Fiber.js
399
265
  var join = fiberJoin;
400
266
  var interrupt = fiberInterrupt;
@@ -948,7 +814,7 @@ var isIgnorable = (error) => isMissing(error) || error.reason._tag === "Permissi
948
814
  var isNotLink = (error) => isIgnorable(error) || error.reason._tag === "Unknown";
949
815
  var DIRECTORY_CONCURRENCY = 16;
950
816
  var byName = /* @__PURE__ */ mapInput(String3, (entry) => entry.name);
951
- var make2 = (fs) => (pattern, options) => walk(fs, compile([pattern], options?.dot ?? false), options);
817
+ var make = (fs) => (pattern, options) => walk(fs, compile([pattern], options?.dot ?? false), options);
952
818
  var walk = /* @__PURE__ */ fnUntraced(function* (fs, compiled, options) {
953
819
  if (compiled.initial.size === 0) {
954
820
  return [];
@@ -1126,7 +992,7 @@ var badArgument = (options) => new PlatformError(new BadArgument(options));
1126
992
 
1127
993
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Latch.js
1128
994
  var makeUnsafe2 = makeLatchUnsafe;
1129
- var make3 = makeLatch;
995
+ var make2 = makeLatch;
1130
996
 
1131
997
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/MutableRef.js
1132
998
  var TypeId2 = "~effect/MutableRef";
@@ -1152,7 +1018,7 @@ var set = /* @__PURE__ */ dual(2, (self, value) => {
1152
1018
 
1153
1019
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/MutableList.js
1154
1020
  var Empty = /* @__PURE__ */ Symbol.for("effect/MutableList/Empty");
1155
- var make4 = () => ({
1021
+ var make3 = () => ({
1156
1022
  head: undefined,
1157
1023
  tail: undefined,
1158
1024
  length: 0
@@ -1301,8 +1167,8 @@ var remove = (self, value) => filter2(self, (v) => v !== value);
1301
1167
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/PubSub.js
1302
1168
  var TypeId3 = "~effect/PubSub";
1303
1169
  var SubscriptionTypeId = "~effect/PubSub/Subscription";
1304
- var make5 = (options) => sync2(() => makePubSubUnsafe(options.atomicPubSub(), new Map, makeUnsafe6(), makeUnsafe2(false), make7(false), options.strategy(), make7(none())));
1305
- var unbounded = (options) => make5({
1170
+ var make4 = (options) => sync2(() => makePubSubUnsafe(options.atomicPubSub(), new Map, makeUnsafe6(), makeUnsafe2(false), make7(false), options.strategy(), make7(none())));
1171
+ var unbounded = (options) => make4({
1306
1172
  atomicPubSub: () => makeAtomicUnbounded(options),
1307
1173
  strategy: () => new DroppingStrategy
1308
1174
  });
@@ -1396,7 +1262,7 @@ var removeSubscribers = (subscribers, subscription, pollers) => {
1396
1262
  subscribers.delete(subscription);
1397
1263
  }
1398
1264
  };
1399
- var makeSubscriptionUnsafe = (pubsub, subscribers, strategy, ended) => new SubscriptionImpl(pubsub, subscribers, pubsub.subscribe(), make4(), makeUnsafe2(false), make7(false), strategy, pubsub.replayWindow(), ended);
1265
+ var makeSubscriptionUnsafe = (pubsub, subscribers, strategy, ended) => new SubscriptionImpl(pubsub, subscribers, pubsub.subscribe(), make3(), makeUnsafe2(false), make7(false), strategy, pubsub.replayWindow(), ended);
1400
1266
  class UnboundedPubSub {
1401
1267
  publisherHead = {
1402
1268
  value: AbsentValue,
@@ -1818,7 +1684,7 @@ var make8 = (options) => withFiber((fiber) => {
1818
1684
  self.dispatcher = fiber.currentDispatcher;
1819
1685
  self.capacity = options?.capacity ?? Number.POSITIVE_INFINITY;
1820
1686
  self.strategy = options?.strategy ?? "suspend";
1821
- self.messages = make4();
1687
+ self.messages = make3();
1822
1688
  self.scheduleRunning = false;
1823
1689
  self.state = {
1824
1690
  _tag: "Open",
@@ -2510,7 +2376,7 @@ var mergeAll = /* @__PURE__ */ dual(2, (channels, {
2510
2376
  }) => fromTransformBracket(fnUntraced(function* (upstream, scope, forkedScope) {
2511
2377
  const concurrencyN = concurrency === "unbounded" ? Number.MAX_SAFE_INTEGER : Math.max(1, concurrency);
2512
2378
  const semaphore = switch_ ? undefined : makeUnsafe3(concurrencyN);
2513
- const doneLatch = yield* make3(true);
2379
+ const doneLatch = yield* make2(true);
2514
2380
  const fibers = new Map;
2515
2381
  const queue = yield* bounded(bufferSize);
2516
2382
  yield* addFinalizer(forkedScope, shutdown(queue));
@@ -2854,7 +2720,7 @@ class RcRefImpl {
2854
2720
  this.idleTimeToLive = idleTimeToLive;
2855
2721
  }
2856
2722
  }
2857
- var make6 = (options) => withFiber2((fiber) => {
2723
+ var make5 = (options) => withFiber2((fiber) => {
2858
2724
  const context = fiber.context;
2859
2725
  const scope = get4(context, Scope);
2860
2726
  const ref = new RcRefImpl(options.acquire, context, scope, options.idleTimeToLive !== undefined ? fromInputUnsafe(options.idleTimeToLive) : undefined);
@@ -2963,7 +2829,7 @@ var release = (self, state) => {
2963
2829
  };
2964
2830
 
2965
2831
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/RcRef.js
2966
- var make9 = make6;
2832
+ var make9 = make5;
2967
2833
  var get3 = get2;
2968
2834
 
2969
2835
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Stream.js
@@ -3179,7 +3045,7 @@ var FileSystem = /* @__PURE__ */ Service2("effect/FileSystem");
3179
3045
  var make11 = (impl) => FileSystem.of({
3180
3046
  ...impl,
3181
3047
  [TypeId10]: TypeId10,
3182
- glob: make2(impl),
3048
+ glob: make(impl),
3183
3049
  exists: (path) => pipe(impl.access(path), as(true), catchTag("PlatformError", (e) => e.reason._tag === "NotFound" ? succeed6(false) : fail7(e))),
3184
3050
  readFileString: (path, encoding) => flatMap3(impl.readFile(path), (_) => try_2({
3185
3051
  try: () => new TextDecoder(encoding).decode(_),
@@ -3311,7 +3177,7 @@ function makeProvider(load, mapInput) {
3311
3177
  function makeSource(get, transform) {
3312
3178
  return makeProvider((path) => get(transform(path)), (f) => makeSource(get, (path) => f(transform(path))));
3313
3179
  }
3314
- function make13(get) {
3180
+ function make6(get) {
3315
3181
  return makeSource(get, identityPath);
3316
3182
  }
3317
3183
  function emptyStringAsMissing(value, preserveEmptyStrings) {
@@ -3320,7 +3186,7 @@ function emptyStringAsMissing(value, preserveEmptyStrings) {
3320
3186
  function fromEnvRecord(env, options) {
3321
3187
  const preserveEmptyStrings = options?.preserveEmptyStrings === true;
3322
3188
  const trie = buildEnvTrie(env);
3323
- return make13((path) => succeed6(nodeAtEnv(trie, env, path, preserveEmptyStrings)));
3189
+ return make6((path) => succeed6(nodeAtEnv(trie, env, path, preserveEmptyStrings)));
3324
3190
  }
3325
3191
  function fromEnv(options) {
3326
3192
  const env = options?.env ?? {
@@ -3402,7 +3268,7 @@ var Proto2 = {
3402
3268
  };
3403
3269
  }
3404
3270
  };
3405
- function make14(evaluator) {
3271
+ function make13(evaluator) {
3406
3272
  const self = Object.create(Proto2);
3407
3273
  self.evaluator = evaluator;
3408
3274
  self.parse = (provider) => flatMapEager(evaluator(provider, []), fromResult);
@@ -3410,14 +3276,14 @@ function make14(evaluator) {
3410
3276
  }
3411
3277
  var evaluateAt = (self, provider, pathPrefix) => self.evaluator(provider, pathPrefix);
3412
3278
  var map3 = /* @__PURE__ */ dual(2, (self, f) => {
3413
- return make14((provider, pathPrefix) => map9(evaluateAt(self, provider, pathPrefix), map5(f)));
3279
+ return make13((provider, pathPrefix) => map9(evaluateAt(self, provider, pathPrefix), map5(f)));
3414
3280
  });
3415
3281
  function all(arg) {
3416
3282
  const configs = globalThis.Array.isArray(arg) ? arg : (Symbol.iterator in arg) ? [...arg] : arg;
3417
- return make14((provider, pathPrefix) => globalThis.Array.isArray(configs) ? mapEager(all3(configs.map((config) => evaluateAt(config, provider, pathPrefix))), all2) : mapEager(all3(map(configs, (config) => evaluateAt(config, provider, pathPrefix))), all2));
3283
+ return make13((provider, pathPrefix) => globalThis.Array.isArray(configs) ? mapEager(all3(configs.map((config) => evaluateAt(config, provider, pathPrefix))), all2) : mapEager(all3(map(configs, (config) => evaluateAt(config, provider, pathPrefix))), all2));
3418
3284
  }
3419
3285
  var withDefault = /* @__PURE__ */ dual(2, (self, defaultValue) => {
3420
- return make14((provider, pathPrefix) => mapEager(evaluateAt(self, provider, pathPrefix), (resolution) => isFailure(resolution) ? succeed(defaultValue) : resolution));
3286
+ return make13((provider, pathPrefix) => mapEager(evaluateAt(self, provider, pathPrefix), (resolution) => isFailure(resolution) ? succeed(defaultValue) : resolution));
3421
3287
  });
3422
3288
  var option = (self) => self.pipe(map3(some), withDefault(none()));
3423
3289
  var isSourceError = (u) => isTagged(u, "SourceError");
@@ -3536,7 +3402,7 @@ function schema(codec, path) {
3536
3402
  const encodedAst = toEncoded(codecStringTree.ast);
3537
3403
  const decodeCursor = decodeUnknownEffect(make17(toConfigCursorAST(codecStringTree.ast)));
3538
3404
  const localPath = typeof path === "string" ? [path] : path ?? [];
3539
- return make14((provider, pathPrefix) => {
3405
+ return make13((provider, pathPrefix) => {
3540
3406
  const fullPath = [...pathPrefix, ...localPath];
3541
3407
  return loadCursor(provider, fullPath).pipe(flatMapEager((cursor) => decodeCursor(cursor).pipe(mapEager(succeed), catchEager((issue) => {
3542
3408
  const error = new ConfigError(new SchemaError(fullPath.length > 0 ? new Pointer(fullPath, issue) : issue));
@@ -3666,4 +3532,4 @@ var srtArgv2 = (srtCommand, settingsFile, argv) => [
3666
3532
  ...argv
3667
3533
  ];
3668
3534
 
3669
- export { empty2, map, makeEquivalence, Clock, currentTimeMillis, bytes, join, interrupt, interruptAll, getCurrent, BadArgument, systemError, badArgument, makeUnsafe2, make7, unbounded, publishUnsafe, make8, bounded, sliding, unbounded2, offer, offerUnsafe, offerAll, fail, failCause, failCauseUnsafe, end, endUnsafe, shutdownUnsafe, take, poll, makeUnsafe3, fromTransform, mapDone, isSink, fromChannel, drain, make9, get3, isStream, fromChannel2, callback, empty3, make10, suspend, fail2, fromQueue, fromPubSub, fromReadableStream, unwrap, map2, tap, drainFork, concat, merge2, filter, catchCause, tapError, mapError, take2, mapAccum, transduce, decodeText, encodeText, splitLines, interruptWhen, ensuring, provideContext, run, runCollect, runFold, runHead, runForEach, runDrain, toPull, mkString, mkArrayBuffer, toReadableStreamEffect, FileSystem, make11, FileTypeId, WatchBackend, Path, make12, embeddedFile, extractEmbeddedFile, map3, all, withDefault, option, String2, optionalEnv, operatorConfigHome, tempDirectoryScoped, harnessesUnsupportedInSrt2, harnessesUnsupportedInDocker2, compiled2, pinnedSrtCommand2, pinnedSrtStepCommand2, runSrtCli2, kitmanCacheDirectory2, srtSettings2, srtCacheEnvironment2, srtInheritedEnv2, inheritedEnvironment2, withOnlyEnvironment2, writeSrtSettings2, srtStepArgv2, srtArgv2 };
3535
+ export { empty2, map, makeEquivalence, Clock, currentTimeMillis, join, interrupt, interruptAll, getCurrent, BadArgument, systemError, badArgument, makeUnsafe2, make7, unbounded, publishUnsafe, make8, bounded, sliding, unbounded2, offer, offerUnsafe, offerAll, fail, failCause, failCauseUnsafe, end, endUnsafe, shutdownUnsafe, take, poll, makeUnsafe3, fromTransform, mapDone, isSink, fromChannel, drain, make9, get3, isStream, fromChannel2, callback, empty3, make10, suspend, fail2, fromQueue, fromPubSub, fromReadableStream, unwrap, map2, tap, drainFork, concat, merge2, filter, catchCause, tapError, mapError, take2, mapAccum, transduce, decodeText, encodeText, splitLines, interruptWhen, ensuring, provideContext, run, runCollect, runFold, runHead, runForEach, runDrain, toPull, mkString, mkArrayBuffer, toReadableStreamEffect, FileSystem, make11, FileTypeId, WatchBackend, Path, make12, embeddedFile, extractEmbeddedFile, map3, all, withDefault, option, String2, optionalEnv, operatorConfigHome, tempDirectoryScoped, harnessesUnsupportedInSrt2, harnessesUnsupportedInDocker2, compiled2, pinnedSrtCommand2, pinnedSrtStepCommand2, runSrtCli2, kitmanCacheDirectory2, srtSettings2, srtCacheEnvironment2, srtInheritedEnv2, inheritedEnvironment2, withOnlyEnvironment2, writeSrtSettings2, srtStepArgv2, srtArgv2 };
@@ -18,7 +18,7 @@ import {
18
18
  isMinLength,
19
19
  isMaxLength,
20
20
  FiniteFromString
21
- } from "./chunk-k462v2v7.js";
21
+ } from "./chunk-n381rqax.js";
22
22
 
23
23
  // packages/core/src/schema.ts
24
24
  var Days = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
@@ -18,7 +18,7 @@ import {
18
18
  isRedacted,
19
19
  make16,
20
20
  value
21
- } from "./chunk-k462v2v7.js";
21
+ } from "./chunk-n381rqax.js";
22
22
  import {
23
23
  unwrap,
24
24
  drainFork,
@@ -27,7 +27,7 @@ import {
27
27
  runCollect,
28
28
  runDrain,
29
29
  mkString
30
- } from "./chunk-5smh4dp2.js";
30
+ } from "./chunk-2xeq2a7j.js";
31
31
 
32
32
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Brand.js
33
33
  function nominal() {
@@ -35,7 +35,7 @@ import {
35
35
  isJsonObject,
36
36
  isString2,
37
37
  encodeUnknownJsonStringSync
38
- } from "./chunk-k462v2v7.js";
38
+ } from "./chunk-n381rqax.js";
39
39
  import {
40
40
  currentTimeMillis,
41
41
  make10,
@@ -43,11 +43,11 @@ import {
43
43
  toPull,
44
44
  FileSystem,
45
45
  compiled2
46
- } from "./chunk-5smh4dp2.js";
46
+ } from "./chunk-2xeq2a7j.js";
47
47
  import {
48
48
  ChildProcessSpawner,
49
49
  make2
50
- } from "./chunk-fqh4pj6b.js";
50
+ } from "./chunk-6evexbdx.js";
51
51
 
52
52
  // packages/agent-runtime/src/opencode-store.ts
53
53
  import { lstatSync, readFileSync, realpathSync, writeSync } from "fs";