@kitman-sh/cli 0.10.90 → 0.10.91

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 (26) hide show
  1. package/dist/{chunk-xb70ys3n.js → chunk-25q7mg6g.js} +17 -17
  2. package/dist/{chunk-x11j5jcj.js → chunk-2wsyg2g7.js} +46 -38
  3. package/dist/{chunk-py4t32pa.js → chunk-5fxxg02f.js} +340 -144
  4. package/dist/{chunk-e8zm8z3a.js → chunk-5tqy48a3.js} +10 -10
  5. package/dist/{chunk-75d425rk.js → chunk-6h0rz0zk.js} +4 -4
  6. package/dist/{chunk-j9frwmmt.js → chunk-947btdv6.js} +3 -3
  7. package/dist/{chunk-fq47a5yd.js → chunk-9m9cv82t.js} +2 -2
  8. package/dist/{chunk-76ctrqm6.js → chunk-c3k32vw4.js} +1 -1
  9. package/dist/{chunk-9zd52pda.js → chunk-cmtvcbxr.js} +5 -5
  10. package/dist/{chunk-bbvvx5z1.js → chunk-d82t42vr.js} +16 -16
  11. package/dist/{chunk-5vsqzmvf.js → chunk-d9wjvvbc.js} +5 -5
  12. package/dist/{chunk-jbwk6k6m.js → chunk-dstm8aen.js} +71 -28
  13. package/dist/{chunk-0gs7cjkt.js → chunk-fgnfx5mw.js} +7 -212
  14. package/dist/{chunk-mgmsx0bm.js → chunk-gncygm43.js} +9 -9
  15. package/dist/{chunk-yx90ye72.js → chunk-gykt7zjx.js} +7 -7
  16. package/dist/{chunk-62565d52.js → chunk-hsf2sj69.js} +2 -2
  17. package/dist/{chunk-tzz4fv17.js → chunk-k4fvnphp.js} +1 -1
  18. package/dist/{chunk-kgdppbdr.js → chunk-mbqeakm1.js} +1 -1
  19. package/dist/{chunk-dd5aa39j.js → chunk-r6d67qqa.js} +263 -34
  20. package/dist/{chunk-ky974pcr.js → chunk-rmsm8vnc.js} +4 -4
  21. package/dist/{chunk-rq6bn96v.js → chunk-sb8c2sgy.js} +16 -16
  22. package/dist/{chunk-jq8hhvdv.js → chunk-tmbhak7y.js} +8 -8
  23. package/dist/{chunk-98sg1yyd.js → chunk-w0sehmpd.js} +14 -60
  24. package/dist/{chunk-m1ewm9dy.js → chunk-y1tnxz9f.js} +25 -25
  25. package/dist/index.js +4 -4
  26. package/package.json +1 -1
@@ -38,7 +38,7 @@ import {
38
38
  assignProperty,
39
39
  PipeInspectableProto,
40
40
  withFiber,
41
- make14,
41
+ make13,
42
42
  strictEqual,
43
43
  Tuple,
44
44
  Number2,
@@ -58,7 +58,7 @@ import {
58
58
  Service2,
59
59
  makeUnsafe4,
60
60
  empty3,
61
- make15,
61
+ make14,
62
62
  add,
63
63
  getOrUndefined2,
64
64
  getOrUndefinedUnsafe,
@@ -91,7 +91,7 @@ import {
91
91
  fail4,
92
92
  isSuccess2,
93
93
  makeUnsafe5,
94
- make16,
94
+ make15,
95
95
  _await,
96
96
  fail5,
97
97
  isDone,
@@ -194,6 +194,9 @@ import {
194
194
  logError,
195
195
  effectify,
196
196
  decode,
197
+ isRedacted,
198
+ make16,
199
+ value,
197
200
  defaultParseOptions,
198
201
  omit,
199
202
  map9,
@@ -242,6 +245,7 @@ import {
242
245
  Class2,
243
246
  Error3,
244
247
  TaggedError2,
248
+ toEquivalence,
245
249
  toCodecJson,
246
250
  Json,
247
251
  JsonObject,
@@ -249,7 +253,45 @@ import {
249
253
  decodeJsonStringOption,
250
254
  encodeJsonStringSync,
251
255
  encodePrettyJsonString
252
- } from "./chunk-jbwk6k6m.js";
256
+ } from "./chunk-dstm8aen.js";
257
+ import {
258
+ ExitCode,
259
+ ProcessId,
260
+ makeHandle,
261
+ make,
262
+ ChildProcessSpawner,
263
+ display,
264
+ make2,
265
+ parseFdName,
266
+ fdName
267
+ } from "./chunk-w0sehmpd.js";
268
+ import {
269
+ isDateTime,
270
+ Numeric,
271
+ isWholeNumber,
272
+ guard,
273
+ Id,
274
+ Timestamp,
275
+ ActorType,
276
+ SecretName,
277
+ SecretScope,
278
+ SecretHosts,
279
+ isSecretReference
280
+ } from "./chunk-mbqeakm1.js";
281
+ import {
282
+ toJsonValue,
283
+ isOneOf,
284
+ isBigInt,
285
+ isBoolean,
286
+ isFunction,
287
+ isNumber,
288
+ isObject,
289
+ isJsonObject,
290
+ isString,
291
+ isSymbol,
292
+ isUndefined,
293
+ kindOf
294
+ } from "./chunk-k4fvnphp.js";
253
295
  import {
254
296
  map,
255
297
  makeEquivalence,
@@ -258,8 +300,8 @@ import {
258
300
  systemError,
259
301
  badArgument,
260
302
  makeUnsafe2,
303
+ make7,
261
304
  make8,
262
- make9,
263
305
  sliding,
264
306
  unbounded2,
265
307
  offer,
@@ -275,13 +317,13 @@ import {
275
317
  isSink,
276
318
  fromChannel,
277
319
  drain,
278
- make10,
320
+ make9,
279
321
  get3,
280
322
  isStream,
281
323
  fromChannel2,
282
324
  callback,
283
325
  empty2,
284
- make11,
326
+ make10,
285
327
  suspend,
286
328
  fail2,
287
329
  fromQueue,
@@ -307,57 +349,16 @@ import {
307
349
  mkArrayBuffer,
308
350
  toReadableStreamEffect,
309
351
  FileSystem,
310
- make12,
352
+ make11,
311
353
  FileTypeId,
312
354
  WatchBackend,
313
355
  Path,
314
- make13,
356
+ make12,
315
357
  option,
316
358
  String2,
317
359
  optionalEnv,
318
360
  harnessesUnsupportedInSrt2
319
- } from "./chunk-xb70ys3n.js";
320
- import {
321
- isDateTime,
322
- Numeric,
323
- isWholeNumber,
324
- guard,
325
- Id,
326
- Timestamp,
327
- ActorType,
328
- SecretName,
329
- SecretScope,
330
- SecretHosts,
331
- isSecretReference
332
- } from "./chunk-kgdppbdr.js";
333
- import {
334
- toJsonValue,
335
- isOneOf,
336
- isBigInt,
337
- isBoolean,
338
- isFunction,
339
- isNumber,
340
- isObject,
341
- isJsonObject,
342
- isString,
343
- isSymbol,
344
- isUndefined,
345
- kindOf
346
- } from "./chunk-tzz4fv17.js";
347
- import {
348
- isRedacted,
349
- make,
350
- value,
351
- ExitCode,
352
- ProcessId,
353
- makeHandle,
354
- make2,
355
- ChildProcessSpawner,
356
- display,
357
- make3,
358
- parseFdName,
359
- fdName
360
- } from "./chunk-98sg1yyd.js";
361
+ } from "./chunk-25q7mg6g.js";
361
362
 
362
363
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Tuple.js
363
364
  var makeEquivalence3 = Tuple;
@@ -520,7 +521,7 @@ var makeUnsafe6 = (input) => {
520
521
  var hasZone = (input) => /Z|GMT|[+-]\d{2}$|[+-]\d{2}:?\d{2}$|\]$/.test(input) || /z$|gmt$/i.test(input);
521
522
  var minEpochMillis = -8640000000000000 + 12 * 60 * 60 * 1000;
522
523
  var maxEpochMillis = 8640000000000000 - 14 * 60 * 60 * 1000;
523
- var make4 = /* @__PURE__ */ liftThrowable(makeUnsafe6);
524
+ var make3 = /* @__PURE__ */ liftThrowable(makeUnsafe6);
524
525
  var now = /* @__PURE__ */ map7(currentTimeMillis, makeUtc);
525
526
  var nowUnsafe = () => makeUtc(Date.now());
526
527
  var toDateUtc = (self) => new Date(self.epochMilliseconds);
@@ -910,7 +911,7 @@ var toNumber = (b) => {
910
911
 
911
912
  // node_modules/.bun/effect@4.1.2/node_modules/effect/dist/DateTime.js
912
913
  var makeUnsafe = makeUnsafe6;
913
- var make18 = make4;
914
+ var make18 = make3;
914
915
  var now2 = now;
915
916
  var nowUnsafe2 = nowUnsafe;
916
917
  var toDateUtc2 = toDateUtc;
@@ -1125,7 +1126,7 @@ var readableToPullUnsafe = (options) => {
1125
1126
  const readable = options.readable;
1126
1127
  const chunkSize = options.chunkSize ?? 4096;
1127
1128
  const closeOnDone = options.closeOnDone ?? true;
1128
- const exit = options.exit ?? make8(undefined);
1129
+ const exit = options.exit ?? make7(undefined);
1129
1130
  const latch = options.latch ?? makeUnsafe2(false);
1130
1131
  function onReadable() {
1131
1132
  latch.openUnsafe();
@@ -1689,7 +1690,7 @@ var make19 = /* @__PURE__ */ gen(function* () {
1689
1690
  const sourceStream = unwrap(succeed6(getSourceStream(handles[handles.length - 1], options.from)));
1690
1691
  const toOption = options.to ?? "stdin";
1691
1692
  if (toOption === "stdin") {
1692
- handles.push(yield* spawnCommand(make3(command.command, command.args, {
1693
+ handles.push(yield* spawnCommand(make2(command.command, command.args, {
1693
1694
  ...command.options,
1694
1695
  stdin: {
1695
1696
  ...stdinConfig,
@@ -1709,7 +1710,7 @@ var make19 = /* @__PURE__ */ gen(function* () {
1709
1710
  type: "input",
1710
1711
  stream: sourceStream
1711
1712
  };
1712
- handles.push(yield* spawnCommand(make3(command.command, command.args, {
1713
+ handles.push(yield* spawnCommand(make2(command.command, command.args, {
1713
1714
  ...command.options,
1714
1715
  additionalFds: {
1715
1716
  ...existingFds,
@@ -1717,7 +1718,7 @@ var make19 = /* @__PURE__ */ gen(function* () {
1717
1718
  }
1718
1719
  })));
1719
1720
  } else {
1720
- handles.push(yield* spawnCommand(make3(command.command, command.args, {
1721
+ handles.push(yield* spawnCommand(make2(command.command, command.args, {
1721
1722
  ...command.options,
1722
1723
  stdin: {
1723
1724
  ...stdinConfig,
@@ -1756,7 +1757,7 @@ var make19 = /* @__PURE__ */ gen(function* () {
1756
1757
  }
1757
1758
  }
1758
1759
  });
1759
- return make2(spawnCommand);
1760
+ return make(spawnCommand);
1760
1761
  });
1761
1762
  var layer5 = /* @__PURE__ */ effect(ChildProcessSpawner, make19);
1762
1763
  var flattenCommand = (command) => {
@@ -2242,7 +2243,7 @@ var writeFile2 = (path, data, options) => callback3((resume, signal) => {
2242
2243
  resume(fail7(handleBadArgument("writeFile")(err)));
2243
2244
  }
2244
2245
  });
2245
- var makeFileSystem = /* @__PURE__ */ map8(/* @__PURE__ */ serviceOption(WatchBackend), (backend) => make12({
2246
+ var makeFileSystem = /* @__PURE__ */ map8(/* @__PURE__ */ serviceOption(WatchBackend), (backend) => make11({
2246
2247
  access: access2,
2247
2248
  chmod: chmod2,
2248
2249
  chown: chown2,
@@ -2302,15 +2303,15 @@ var fileUrlOps = (windows) => ({
2302
2303
  })
2303
2304
  })
2304
2305
  });
2305
- var layerPosix = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make13({
2306
+ var layerPosix = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make12({
2306
2307
  ...NodePath.posix,
2307
2308
  .../* @__PURE__ */ fileUrlOps(false)
2308
2309
  }));
2309
- var layerWin32 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make13({
2310
+ var layerWin32 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make12({
2310
2311
  ...NodePath.win32,
2311
2312
  .../* @__PURE__ */ fileUrlOps(true)
2312
2313
  }));
2313
- var layer7 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make13({
2314
+ var layer7 = /* @__PURE__ */ succeed5(Path)(/* @__PURE__ */ make12({
2314
2315
  ...NodePath,
2315
2316
  .../* @__PURE__ */ fileUrlOps(undefined)
2316
2317
  }));
@@ -2832,12 +2833,12 @@ var redact2 = /* @__PURE__ */ dual(2, (self, key) => {
2832
2833
  if (typeof key === "string") {
2833
2834
  const k = key.toLowerCase();
2834
2835
  if (k in self) {
2835
- out[k] = make(self[k]);
2836
+ out[k] = make16(self[k]);
2836
2837
  }
2837
2838
  } else {
2838
2839
  for (const name in self) {
2839
2840
  if (name.search(key) !== -1) {
2840
- out[name] = make(self[name]);
2841
+ out[name] = make16(self[name]);
2841
2842
  }
2842
2843
  }
2843
2844
  }
@@ -2944,7 +2945,7 @@ var fromInputNested = (input) => {
2944
2945
  return out;
2945
2946
  };
2946
2947
  var coerce = (value) => isRedacted(value) ? value : String(value);
2947
- var Equivalence3 = /* @__PURE__ */ make14((a, b) => arrayEquivalence(a.params, b.params));
2948
+ var Equivalence3 = /* @__PURE__ */ make13((a, b) => arrayEquivalence(a.params, b.params));
2948
2949
  var arrayEquivalence = /* @__PURE__ */ makeEquivalence2(/* @__PURE__ */ makeEquivalence3([/* @__PURE__ */ strictEqual(), /* @__PURE__ */ asEquivalence()]));
2949
2950
  var empty4 = /* @__PURE__ */ make23([]);
2950
2951
  var setAll2 = /* @__PURE__ */ dual(2, (self, input) => {
@@ -2963,7 +2964,7 @@ var setAll2 = /* @__PURE__ */ dual(2, (self, input) => {
2963
2964
  var toString = (input) => new URLSearchParams(fromInput2(input).params.map(([key, value]) => [key, unwrap3(value)])).toString();
2964
2965
  var redact3 = /* @__PURE__ */ dual(2, (self, key) => {
2965
2966
  const patterns = Array.isArray(key) ? key : [key];
2966
- return self.params.map(([name, value]) => [name, typeof value === "string" && isRedactedName2(name, patterns) ? make(value) : value]);
2967
+ return self.params.map(([name, value]) => [name, typeof value === "string" && isRedactedName2(name, patterns) ? make16(value) : value]);
2967
2968
  });
2968
2969
  var isRedactedName2 = isRedactedName;
2969
2970
  var redactUrl = (url, redactedNames = currentRedactedNames()) => {
@@ -3039,7 +3040,7 @@ import * as readline from "readline";
3039
3040
  var make25 = /* @__PURE__ */ fnUntraced(function* (shouldQuit = defaultShouldQuit) {
3040
3041
  const stdin = process.stdin;
3041
3042
  const stdout = process.stdout;
3042
- const lines = yield* make9();
3043
+ const lines = yield* make8();
3043
3044
  let inputEnded = stdin.readableEnded;
3044
3045
  let readlineActive = false;
3045
3046
  const onStdinEnd = () => {
@@ -3050,7 +3051,7 @@ var make25 = /* @__PURE__ */ fnUntraced(function* (shouldQuit = defaultShouldQui
3050
3051
  };
3051
3052
  stdin.once("end", onStdinEnd);
3052
3053
  yield* addFinalizer2(() => sync2(() => stdin.off("end", onStdinEnd)));
3053
- const rlRef = yield* make10({
3054
+ const rlRef = yield* make9({
3054
3055
  acquire: acquireRelease(sync2(() => {
3055
3056
  const rl = readline.createInterface({
3056
3057
  input: stdin,
@@ -3089,7 +3090,7 @@ var make25 = /* @__PURE__ */ fnUntraced(function* (shouldQuit = defaultShouldQui
3089
3090
  if (stdin.isTTY)
3090
3091
  stdin.setRawMode(enabled);
3091
3092
  });
3092
- const rawModeRef = yield* make10({
3093
+ const rawModeRef = yield* make9({
3093
3094
  acquire: acquireRelease(setRawMode(true), () => setRawMode(false)),
3094
3095
  idleTimeToLive: "10 millis"
3095
3096
  });
@@ -3110,7 +3111,7 @@ var make25 = /* @__PURE__ */ fnUntraced(function* (shouldQuit = defaultShouldQui
3110
3111
  return queue;
3111
3112
  });
3112
3113
  const readInput = gen(function* () {
3113
- const queue = yield* make9();
3114
+ const queue = yield* make8();
3114
3115
  const handleKeypress = (s, k) => {
3115
3116
  const userInput = {
3116
3117
  input: fromUndefinedOr(s),
@@ -6932,7 +6933,9 @@ var RunnerProblemCodes = [
6932
6933
  "runner_removed",
6933
6934
  "sandbox_missing",
6934
6935
  "herdr_core_missing",
6935
- "update_failed"
6936
+ "update_failed",
6937
+ "processes_unreaped",
6938
+ "processes_uncontained"
6936
6939
  ];
6937
6940
  var RunnerProblemText = String4.check(isMinLength(1), isMaxLength(500));
6938
6941
  var RunnerProblemReport = Struct({
@@ -9314,6 +9317,85 @@ function sha256Hasher() {
9314
9317
  digest: (encoding) => hash.digest(encoding)
9315
9318
  };
9316
9319
  }
9320
+ // packages/core/src/schedule.ts
9321
+ var ScheduleFrequency = ["daily", "weekly"];
9322
+ var ScheduleMisfirePolicies = ["skip", "fire_once", "catch_up"];
9323
+ var ScheduleOverlapPolicies = ["allow", "skip", "coalesce"];
9324
+ var ScheduleVersionStatuses = ["draft", "published", "disabled", "archived"];
9325
+ var ScheduleCalendarRule = Struct({
9326
+ frequency: Literals(ScheduleFrequency),
9327
+ hour: Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(23)),
9328
+ minute: Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(59)),
9329
+ second: optionalKey(Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(59))),
9330
+ daysOfWeek: optionalKey(ArraySchema(Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(6))).check(isMinLength(1), isMaxLength(7)))
9331
+ });
9332
+ var ScheduleCronRule = Struct({
9333
+ cron: String4.check(isMinLength(9), isMaxLength(200), isPattern(new RegExp("^[0-9*,/-]+( [0-9*,/-]+){4}$", "u")))
9334
+ });
9335
+ var ScheduleRule = Union([ScheduleCalendarRule, ScheduleCronRule]);
9336
+ var cronBounds = [
9337
+ [0, 59],
9338
+ [0, 23],
9339
+ [1, 31],
9340
+ [1, 12],
9341
+ [0, 7]
9342
+ ];
9343
+ function cronField(field, [min, max]) {
9344
+ const values = new Set;
9345
+ for (const part of field.split(",")) {
9346
+ const match = /^(\*|(\d+)(?:-(\d+))?)(?:\/(\d+))?$/.exec(part);
9347
+ if (match === null)
9348
+ return;
9349
+ const from = match[1] === "*" ? min : Number(match[2]);
9350
+ const to = match[1] === "*" ? max : match[3] === undefined ? match[4] === undefined ? from : max : Number(match[3]);
9351
+ const step = match[4] === undefined ? 1 : Number(match[4]);
9352
+ if (from < min || to > max || from > to || step < 1)
9353
+ return;
9354
+ for (let value = from;value <= to; value += step)
9355
+ values.add(value);
9356
+ }
9357
+ return values;
9358
+ }
9359
+ function parseCron(cron) {
9360
+ const fields = cron.split(" ");
9361
+ const [minutes, hours, days, months, weekdays] = fields.map((field, index) => cronField(field, cronBounds[index] ?? [0, 0]));
9362
+ if (fields.length !== 5 || !minutes || !hours || !days || !months || !weekdays)
9363
+ return;
9364
+ return {
9365
+ minutes,
9366
+ hours,
9367
+ days,
9368
+ months,
9369
+ weekdays: new Set([...weekdays].map((value) => value % 7)),
9370
+ dayRestricted: !(fields[2] ?? "").startsWith("*"),
9371
+ weekdayRestricted: !(fields[4] ?? "").startsWith("*")
9372
+ };
9373
+ }
9374
+ function isScheduleRule(value) {
9375
+ return guard(ScheduleRule)(value) && (!("cron" in value) || parseCron(value.cron) !== undefined);
9376
+ }
9377
+ var ScheduleVersion = Struct({
9378
+ contractVersion: Literal("schedule.v1"),
9379
+ id: String4.check(isMinLength(1)),
9380
+ scheduleId: String4.check(isMinLength(1)),
9381
+ workspaceId: String4.check(isMinLength(1)),
9382
+ teamId: optionalKey(String4.check(isMinLength(1))),
9383
+ loopId: optionalKey(String4.check(isMinLength(1))),
9384
+ name: optionalKey(String4.check(isMinLength(1), isMaxLength(200))),
9385
+ version: Int.check(isGreaterThanOrEqualTo(1)),
9386
+ status: Literals(ScheduleVersionStatuses),
9387
+ timezone: String4.check(isMinLength(1), isMaxLength(80)),
9388
+ rule: ScheduleRule,
9389
+ misfirePolicy: Literals(ScheduleMisfirePolicies),
9390
+ overlapPolicy: Literals(ScheduleOverlapPolicies),
9391
+ maxCatchUp: Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(200)),
9392
+ misfireGraceSeconds: optionalKey(Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(604800))),
9393
+ inputSchemaRef: optionalKey(LoopDataSchemaRef),
9394
+ input: optionalKey(SafeJson),
9395
+ createdAt: String4.check(isMinLength(1))
9396
+ });
9397
+ var zones = new Map;
9398
+ var resolvedLocalDateTimes = new Map;
9317
9399
  // packages/core/src/transcript.ts
9318
9400
  var Text = String4.check(isMaxLength(200000));
9319
9401
  var AgentEvent = Union([
@@ -9702,14 +9784,14 @@ function makeWith(method, url, urlParams, hash, headers, body) {
9702
9784
  return self;
9703
9785
  }
9704
9786
  var empty6 = /* @__PURE__ */ makeWith("GET", "", empty4, /* @__PURE__ */ none(), empty, empty5);
9705
- var make5 = (method) => (url, options) => modify(empty6, {
9787
+ var make4 = (method) => (url, options) => modify(empty6, {
9706
9788
  method,
9707
9789
  url,
9708
9790
  ...options ?? undefined
9709
9791
  });
9710
- var get = /* @__PURE__ */ make5("GET");
9711
- var post = /* @__PURE__ */ make5("POST");
9712
- var put = /* @__PURE__ */ make5("PUT");
9792
+ var get = /* @__PURE__ */ make4("GET");
9793
+ var post = /* @__PURE__ */ make4("POST");
9794
+ var put = /* @__PURE__ */ make4("PUT");
9713
9795
  var modify = /* @__PURE__ */ dual(2, (self, options) => {
9714
9796
  let result = self;
9715
9797
  if (options.method) {
@@ -10010,7 +10092,7 @@ var Proto7 = {
10010
10092
  };
10011
10093
  },
10012
10094
  .../* @__PURE__ */ Object.fromEntries(/* @__PURE__ */ allShort.map(([fullMethod, method]) => [method, function(url, options) {
10013
- return this.execute(make5(fullMethod)(url, options));
10095
+ return this.execute(make4(fullMethod)(url, options));
10014
10096
  }]))
10015
10097
  };
10016
10098
  var make27 = (f) => makeWith2((effect) => flatMap3(effect, (request) => withFiber2((fiber) => {
@@ -11237,6 +11319,120 @@ var DeployBindingCreate = Struct({
11237
11319
  });
11238
11320
  var DeployBindingList = Struct({ items: ArraySchema(DeployBinding) });
11239
11321
  var defaultKitName = "@kitman-sh/software-engineering";
11322
+
11323
+ // packages/core/src/kit-declarations.ts
11324
+ var LoopCapabilities = [
11325
+ "agent_work",
11326
+ "ask",
11327
+ "call",
11328
+ "verify",
11329
+ "change_request",
11330
+ "write_back",
11331
+ "post_comment",
11332
+ "create_tasks",
11333
+ "merge_change_request",
11334
+ "approve_change_request",
11335
+ "publish_release",
11336
+ "read_transcripts",
11337
+ "read_change_request",
11338
+ "measure",
11339
+ "claim",
11340
+ "propose",
11341
+ "read_project",
11342
+ "draft_update"
11343
+ ];
11344
+ var JsonObject2 = Record(String4, Json);
11345
+ var SecretName2 = String4.check(isPattern(/^[A-Za-z_][A-Za-z0-9_]{0,127}$/));
11346
+ var EventFilterValue = Union([String4, Finite, Boolean2, Null]);
11347
+ var LoopManifest = Struct({
11348
+ id: String4,
11349
+ title: String4,
11350
+ version: optionalKey(LoopVersion),
11351
+ input: JsonObject2,
11352
+ output: JsonObject2,
11353
+ outcome: optionalKey(Literals(["feature", "bug", "refactor", "investigation", "docs", "migration", "performance"])),
11354
+ agents: Record(String4, String4),
11355
+ checkout: Literals(["none", "read", "write"]),
11356
+ when: ArraySchema(Struct({
11357
+ event: String4,
11358
+ filter: optionalKey(Record(String4, Union([EventFilterValue, ArraySchema(EventFilterValue)]))),
11359
+ input: Record(String4, String4),
11360
+ values: optionalKey(JsonObject2)
11361
+ })),
11362
+ offers: ArraySchema(Struct({
11363
+ id: String4,
11364
+ title: String4,
11365
+ loop: String4,
11366
+ from: optionalKey(String4)
11367
+ })),
11368
+ capabilities: ArraySchema(Literals(LoopCapabilities)),
11369
+ ownCapabilities: optionalKey(ArraySchema(Literals(LoopCapabilities))),
11370
+ secrets: optionalKey(ArraySchema(SecretName2)),
11371
+ network: optionalKey(AgentSandboxNetwork),
11372
+ schedule: optionalKey(Struct({ rule: ScheduleRule, timezone: String4 }))
11373
+ });
11374
+ var LoopDetail = Struct({
11375
+ id: String4,
11376
+ resolved: optionalKey(Struct({
11377
+ ...ProgramLoop.fields,
11378
+ agents: LoopManifest.fields.agents,
11379
+ when: LoopManifest.fields.when,
11380
+ schedule: optionalKey(Struct({
11381
+ rule: ScheduleRule,
11382
+ timezone: String4,
11383
+ on: Boolean2,
11384
+ nextRunAt: optionalKey(String4)
11385
+ }))
11386
+ }))
11387
+ });
11388
+ var AgentDeclaration = Struct({
11389
+ extends: optionalKey(String4),
11390
+ instructions: optionalKey(String4),
11391
+ harness: optionalKey(String4),
11392
+ model: optionalKey(String4),
11393
+ effort: optionalKey(Literals(AgentEfforts)),
11394
+ fallbacks: optionalKey(ArraySchema(AgentFallback)),
11395
+ tools: optionalKey(ArraySchema(Literals(AgentCapabilities))),
11396
+ skills: optionalKey(ArraySchema(String4.check(isMinLength(1)))),
11397
+ network: optionalKey(Union([Struct({ hosts: ArraySchema(String4) }), Literal("open")])),
11398
+ sandbox: optionalKey(Literal("docker"))
11399
+ });
11400
+ var scheduleFields = {
11401
+ name: String4.check(isMinLength(1)),
11402
+ loop: String4,
11403
+ team: optionalKey(String4),
11404
+ input: optionalKey(JsonObject2),
11405
+ timezone: String4,
11406
+ misfire: optionalKey(Literals(ScheduleMisfirePolicies)),
11407
+ overlap: optionalKey(Literals(ScheduleOverlapPolicies))
11408
+ };
11409
+ var ScheduleDeclaration = Union([
11410
+ Struct({
11411
+ ...scheduleFields,
11412
+ cron: String4.check(makeFilter((cron) => isScheduleRule({ cron }) || "five cron fields, each within its range"))
11413
+ }),
11414
+ Struct({
11415
+ ...scheduleFields,
11416
+ rule: declare((value) => isScheduleRule(value), {
11417
+ expected: "a Schedule rule: frequency daily or weekly, hour, minute, and optionally second and daysOfWeek"
11418
+ })
11419
+ })
11420
+ ]);
11421
+ var CarriedKit = Struct({
11422
+ name: KitName,
11423
+ version: String4.check(isMinLength(1)),
11424
+ setup: KitDigest,
11425
+ loops: ArraySchema(String4),
11426
+ agents: ArraySchema(String4)
11427
+ });
11428
+ var KitDeclarations = Struct({
11429
+ loops: ArraySchema(LoopManifest),
11430
+ agents: Record(String4, AgentDeclaration),
11431
+ schedules: optionalKey(Record(String4, ScheduleDeclaration)),
11432
+ carried: optionalKey(ArraySchema(CarriedKit))
11433
+ });
11434
+ var sameLoop = toEquivalence(LoopManifest);
11435
+ var sameAgent = toEquivalence(AgentDeclaration);
11240
11436
  // packages/core/src/kit-setup.ts
11241
11437
  var KitSetup = Struct({
11242
11438
  ...AgentEnvironmentFragment.fields,
@@ -13617,7 +13813,7 @@ var makeProto = (options) => {
13617
13813
  Rpc.key = `effect/rpc/Rpc/${options._tag}`;
13618
13814
  return Rpc;
13619
13815
  };
13620
- var make6 = (tag, options) => {
13816
+ var make5 = (tag, options) => {
13621
13817
  const successSchema = options?.success ?? Void;
13622
13818
  const errorSchema = options?.error ?? Never;
13623
13819
  const defectSchema = options?.defect ?? Defect();
@@ -13828,7 +14024,7 @@ var RpcGroupProto = {
13828
14024
  });
13829
14025
  },
13830
14026
  annotateRpcs(service, value) {
13831
- return this.annotateRpcsMerge(make15(service, value));
14027
+ return this.annotateRpcsMerge(make14(service, value));
13832
14028
  },
13833
14029
  annotateMerge(context) {
13834
14030
  return makeProto2({
@@ -13851,7 +14047,7 @@ var makeProto2 = (options) => Object.assign(function() {}, RpcGroupProto, {
13851
14047
  requests: options.requests,
13852
14048
  annotations: options.annotations
13853
14049
  });
13854
- var make7 = (...rpcs) => makeProto2({
14050
+ var make6 = (...rpcs) => makeProto2({
13855
14051
  requests: new Map(rpcs.map((rpc) => [rpc._tag, rpc])),
13856
14052
  annotations: empty3()
13857
14053
  });
@@ -13894,7 +14090,7 @@ class RunnerAuthentication extends Service()("RunnerAuthentication", {
13894
14090
  error: RunnerRpcError
13895
14091
  }) {
13896
14092
  }
13897
- var EventFilterValue = Union([String4, Finite, Boolean2, Null]);
14093
+ var EventFilterValue2 = Union([String4, Finite, Boolean2, Null]);
13898
14094
  var WorkAvailable = TaggedStruct("WorkAvailable", {});
13899
14095
  var LeaseRevoked = TaggedStruct("LeaseRevoked", { workUnitId: String4 });
13900
14096
  var Settled = TaggedStruct("Settled", { workUnitId: String4 });
@@ -13958,96 +14154,96 @@ var ProgramOutcome = Union([
13958
14154
  Struct({ status: Literal("failed"), failureSummary: String4 })
13959
14155
  ]);
13960
14156
 
13961
- class RunnerReplicaRpcs extends make7(make6("Claim", {
14157
+ class RunnerReplicaRpcs extends make6(make5("Claim", {
13962
14158
  payload: WorkUnitClaimInput,
13963
14159
  success: WorkUnitClaimResult,
13964
14160
  error: RunnerRpcError
13965
- }), make6("Heartbeat", {
14161
+ }), make5("Heartbeat", {
13966
14162
  payload: WorkUnitHeartbeatInput,
13967
14163
  success: WorkUnitHeartbeatResult,
13968
14164
  error: RunnerRpcError
13969
- }), make6("Complete", {
14165
+ }), make5("Complete", {
13970
14166
  payload: WorkUnitCompletion,
13971
14167
  error: RunnerRpcError
13972
- }), make6("Release", {
14168
+ }), make5("Release", {
13973
14169
  payload: WorkUnitReleaseInput,
13974
14170
  error: RunnerRpcError
13975
- }), make6("Signals", {
14171
+ }), make5("Signals", {
13976
14172
  payload: { runnerReplicaId: String4 },
13977
14173
  success: RunnerSignal,
13978
14174
  error: RunnerRpcError,
13979
14175
  stream: true
13980
- }), make6("ReportSteer", {
14176
+ }), make5("ReportSteer", {
13981
14177
  payload: { workUnitId: String4, messageId: String4, delivered: Boolean2 },
13982
14178
  success: Void,
13983
14179
  error: RunnerRpcError
13984
- }), make6("AppendTranscript", {
14180
+ }), make5("AppendTranscript", {
13985
14181
  payload: { workUnitId: String4, entries: ArraySchema(TranscriptAppendEntry).check(isMaxLength(100)) },
13986
14182
  success: Void,
13987
14183
  error: RunnerRpcError
13988
- }), make6("CreateCheckpointFile", {
14184
+ }), make5("CreateCheckpointFile", {
13989
14185
  payload: { lease: ProgramLease, byteSize: Int, sha256: String4 },
13990
14186
  success: Struct({ file: RunFileRecord, upload: optional(RunFileUpload) }),
13991
14187
  error: Union([RunnerRpcError, RunFileRefused])
13992
- }), make6("CheckpointFileParts", {
14188
+ }), make5("CheckpointFileParts", {
13993
14189
  payload: { lease: ProgramLease, fileId: String4, partNumbers: ArraySchema(Int) },
13994
14190
  success: Struct({ parts: ArraySchema(RunFilePartUrl) }),
13995
14191
  error: RunnerRpcError
13996
- }), make6("CompleteCheckpointFile", {
14192
+ }), make5("CompleteCheckpointFile", {
13997
14193
  payload: { lease: ProgramLease, fileId: String4, parts: optional(ArraySchema(UploadedRunFilePart)) },
13998
14194
  success: RunFileRecord,
13999
14195
  error: RunnerRpcError
14000
- }), make6("SaveCheckpoint", {
14196
+ }), make5("SaveCheckpoint", {
14001
14197
  payload: { lease: ProgramLease, checkpoint: StepCheckpoint },
14002
14198
  success: Void,
14003
14199
  error: RunnerRpcError
14004
- }), make6("ResumeCheckpoint", {
14200
+ }), make5("ResumeCheckpoint", {
14005
14201
  payload: { lease: ProgramLease },
14006
14202
  success: UndefinedOr(ResumedCheckpoint),
14007
14203
  error: RunnerRpcError
14008
- }), make6("SettledCheckpoints", {
14204
+ }), make5("SettledCheckpoints", {
14009
14205
  success: ArraySchema(Struct({
14010
14206
  stepAttemptId: String4,
14011
14207
  ref: optionalKey(String4),
14012
14208
  repoBinding: optionalKey(WorkUnitRepoBinding)
14013
14209
  })),
14014
14210
  error: RunnerRpcError
14015
- }), make6("ForgetCheckpoints", {
14211
+ }), make5("ForgetCheckpoints", {
14016
14212
  payload: { stepAttemptIds: ArraySchema(String4) },
14017
14213
  success: Void,
14018
14214
  error: RunnerRpcError
14019
- }), make6("GitCredential", {
14215
+ }), make5("GitCredential", {
14020
14216
  payload: { repoBindingId: String4 },
14021
14217
  success: UndefinedOr(Struct({ username: String4, password: String4 })),
14022
14218
  error: RunnerRpcError
14023
- }), make6("Bundle", {
14219
+ }), make5("Bundle", {
14024
14220
  payload: { digest: String4 },
14025
14221
  success: Struct({ bundle: String4 }),
14026
14222
  error: RunnerRpcError
14027
- }), make6("SettledRuns", {
14223
+ }), make5("SettledRuns", {
14028
14224
  payload: { runIds: ArraySchema(String4) },
14029
14225
  success: ArraySchema(String4),
14030
14226
  error: RunnerRpcError
14031
- }), make6("KnownEvidence", {
14227
+ }), make5("KnownEvidence", {
14032
14228
  payload: { lease: ProgramLease, trees: ArraySchema(String4) },
14033
14229
  success: ArraySchema(Struct({ tree: String4, name: String4, command: String4 })),
14034
14230
  error: RunnerRpcError
14035
14231
  })).middleware(RunnerAuthentication) {
14036
14232
  }
14037
14233
 
14038
- class RunnerJournalRpcs extends make7(make6("RecordActivity", {
14234
+ class RunnerJournalRpcs extends make6(make5("RecordActivity", {
14039
14235
  payload: { lease: ProgramLease, name: String4, attempt: Int, exit: Json },
14040
14236
  error: RunnerRpcError
14041
- }), make6("DeferredDone", {
14237
+ }), make5("DeferredDone", {
14042
14238
  payload: { lease: ProgramLease, name: String4, exit: Json },
14043
14239
  error: RunnerRpcError
14044
- }), make6("ScheduleClock", {
14240
+ }), make5("ScheduleClock", {
14045
14241
  payload: { lease: ProgramLease, name: String4, deferredName: String4, durationMillis: Int },
14046
14242
  error: RunnerRpcError
14047
- }), make6("Suspend", { payload: { lease: ProgramLease }, error: RunnerRpcError }), make6("FinishProgram", { payload: { lease: ProgramLease, outcome: ProgramOutcome }, error: RunnerRpcError })).middleware(RunnerAuthentication) {
14243
+ }), make5("Suspend", { payload: { lease: ProgramLease }, error: RunnerRpcError }), make5("FinishProgram", { payload: { lease: ProgramLease, outcome: ProgramOutcome }, error: RunnerRpcError })).middleware(RunnerAuthentication) {
14048
14244
  }
14049
14245
 
14050
- class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14246
+ class RunnerCapabilityRpcs extends make6(make5("PutQuestion", {
14051
14247
  payload: {
14052
14248
  lease: ProgramLease,
14053
14249
  step: String4,
@@ -14066,7 +14262,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14066
14262
  },
14067
14263
  success: Struct({ questionId: String4 }),
14068
14264
  error: RunnerRpcError
14069
- }), make6("StartAgentStep", {
14265
+ }), make5("StartAgentStep", {
14070
14266
  payload: {
14071
14267
  lease: ProgramLease,
14072
14268
  step: String4,
@@ -14082,7 +14278,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14082
14278
  },
14083
14279
  success: Struct({ stepAttemptId: String4 }),
14084
14280
  error: RunnerRpcError
14085
- }), make6("StartVerification", {
14281
+ }), make5("StartVerification", {
14086
14282
  payload: {
14087
14283
  lease: ProgramLease,
14088
14284
  step: String4,
@@ -14101,23 +14297,23 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14101
14297
  },
14102
14298
  success: Struct({ verificationId: String4 }),
14103
14299
  error: RunnerRpcError
14104
- }), make6("AwaitEvent", {
14300
+ }), make5("AwaitEvent", {
14105
14301
  payload: {
14106
14302
  lease: ProgramLease,
14107
14303
  step: String4,
14108
14304
  deferredName: String4,
14109
14305
  event: String4,
14110
- filter: optional(Record(String4, Union([EventFilterValue, ArraySchema(EventFilterValue)]))),
14306
+ filter: optional(Record(String4, Union([EventFilterValue2, ArraySchema(EventFilterValue2)]))),
14111
14307
  timeoutMillis: Int,
14112
14308
  since: optionalKey(String4),
14113
14309
  or: optionalKey(ArraySchema(Struct({
14114
14310
  event: String4,
14115
- filter: optionalKey(Record(String4, Union([EventFilterValue, ArraySchema(EventFilterValue)]))),
14311
+ filter: optionalKey(Record(String4, Union([EventFilterValue2, ArraySchema(EventFilterValue2)]))),
14116
14312
  since: optionalKey(String4)
14117
14313
  })))
14118
14314
  },
14119
14315
  error: RunnerRpcError
14120
- }), make6("ClaimResource", {
14316
+ }), make5("ClaimResource", {
14121
14317
  payload: {
14122
14318
  lease: ProgramLease,
14123
14319
  step: String4,
@@ -14126,7 +14322,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14126
14322
  action: Literals(["claim", "take_over", "let_go"])
14127
14323
  },
14128
14324
  error: RunnerRpcError
14129
- }), make6("AdmitChild", {
14325
+ }), make5("AdmitChild", {
14130
14326
  payload: {
14131
14327
  lease: ProgramLease,
14132
14328
  step: String4,
@@ -14137,7 +14333,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14137
14333
  },
14138
14334
  success: Struct({ runId: String4 }),
14139
14335
  error: RunnerRpcError
14140
- }), make6("StoreArtifact", {
14336
+ }), make5("StoreArtifact", {
14141
14337
  payload: {
14142
14338
  lease: ProgramLease,
14143
14339
  step: String4,
@@ -14149,7 +14345,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14149
14345
  },
14150
14346
  success: Struct({ artifactId: String4 }),
14151
14347
  error: RunnerRpcError
14152
- }), make6("RecordNote", {
14348
+ }), make5("RecordNote", {
14153
14349
  payload: {
14154
14350
  lease: ProgramLease,
14155
14351
  step: String4,
@@ -14158,7 +14354,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14158
14354
  kind: optional(Literals(["note", "blocker"]))
14159
14355
  },
14160
14356
  error: RunnerRpcError
14161
- }), make6("PerformHostEffect", {
14357
+ }), make5("PerformHostEffect", {
14162
14358
  payload: {
14163
14359
  lease: ProgramLease,
14164
14360
  step: String4,
@@ -14186,7 +14382,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14186
14382
  },
14187
14383
  success: UndefinedOr(Struct({ id: String4, number: String4, url: String4 })),
14188
14384
  error: RunnerRpcError
14189
- }), make6("AlertTask", {
14385
+ }), make5("AlertTask", {
14190
14386
  payload: {
14191
14387
  lease: ProgramLease,
14192
14388
  step: String4,
@@ -14203,7 +14399,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14203
14399
  joined: optionalKey(Struct({ kind: Literals(["run", "recent"]), runId: String4 }))
14204
14400
  }),
14205
14401
  error: RunnerRpcError
14206
- }), make6("ReadTranscripts", {
14402
+ }), make5("ReadTranscripts", {
14207
14403
  payload: { lease: ProgramLease, step: String4, days: Int, teamId: optionalKey(String4) },
14208
14404
  success: Struct({
14209
14405
  runs: ArraySchema(Struct({
@@ -14231,7 +14427,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14231
14427
  })))
14232
14428
  }),
14233
14429
  error: RunnerRpcError
14234
- }), make6("PipelineStatus", {
14430
+ }), make5("PipelineStatus", {
14235
14431
  payload: { lease: ProgramLease, step: String4, changeRequestId: String4 },
14236
14432
  success: Struct({
14237
14433
  head: String4,
@@ -14262,11 +14458,11 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14262
14458
  }))
14263
14459
  }),
14264
14460
  error: RunnerRpcError
14265
- }), make6("ReportPipeline", {
14461
+ }), make5("ReportPipeline", {
14266
14462
  payload: { lease: ProgramLease, step: String4, changeRequestId: String4, verification: String4 },
14267
14463
  success: Struct({ head: String4, status: Literals(["success", "failed"]) }),
14268
14464
  error: RunnerRpcError
14269
- }), make6("ReviewThreads", {
14465
+ }), make5("ReviewThreads", {
14270
14466
  payload: { lease: ProgramLease, step: String4, changeRequestId: String4 },
14271
14467
  success: Struct({
14272
14468
  threads: ArraySchema(Struct({
@@ -14278,7 +14474,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14278
14474
  }))
14279
14475
  }),
14280
14476
  error: RunnerRpcError
14281
- }), make6("OpenChangeRequests", {
14477
+ }), make5("OpenChangeRequests", {
14282
14478
  payload: { lease: ProgramLease, step: String4, authors: NonEmptyArray(String4) },
14283
14479
  success: Struct({
14284
14480
  changeRequests: ArraySchema(Struct({
@@ -14292,7 +14488,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14292
14488
  }))
14293
14489
  }),
14294
14490
  error: RunnerRpcError
14295
- }), make6("OwnChangeRequests", {
14491
+ }), make5("OwnChangeRequests", {
14296
14492
  payload: { lease: ProgramLease, step: String4 },
14297
14493
  success: Struct({
14298
14494
  changeRequests: ArraySchema(Struct({
@@ -14305,7 +14501,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14305
14501
  }))
14306
14502
  }),
14307
14503
  error: RunnerRpcError
14308
- }), make6("Propose", {
14504
+ }), make5("Propose", {
14309
14505
  payload: {
14310
14506
  lease: ProgramLease,
14311
14507
  step: String4,
@@ -14333,7 +14529,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14333
14529
  task: optionalKey(Struct({ id: String4, active: Boolean2 }))
14334
14530
  }),
14335
14531
  error: RunnerRpcError
14336
- }), make6("ReadProject", {
14532
+ }), make5("ReadProject", {
14337
14533
  payload: { lease: ProgramLease, step: String4, projectId: String4 },
14338
14534
  success: Struct({
14339
14535
  project: Struct({ id: String4, name: String4 }),
@@ -14356,7 +14552,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14356
14552
  taskChanges: ArraySchema(Struct({ taskKey: String4, title: String4, change: String4, at: String4 }))
14357
14553
  }),
14358
14554
  error: RunnerRpcError
14359
- }), make6("DraftUpdate", {
14555
+ }), make5("DraftUpdate", {
14360
14556
  payload: {
14361
14557
  lease: ProgramLease,
14362
14558
  step: String4,
@@ -14371,7 +14567,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14371
14567
  },
14372
14568
  success: Struct({ id: String4 }),
14373
14569
  error: RunnerRpcError
14374
- }), make6("CreatePlanTasks", {
14570
+ }), make5("CreatePlanTasks", {
14375
14571
  payload: {
14376
14572
  lease: ProgramLease,
14377
14573
  projectId: optionalKey(String4),
@@ -14386,11 +14582,11 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14386
14582
  },
14387
14583
  success: ArraySchema(Struct({ key: String4, taskId: String4 })),
14388
14584
  error: RunnerRpcError
14389
- }), make6("IntegrationBranch", {
14585
+ }), make5("IntegrationBranch", {
14390
14586
  payload: { lease: ProgramLease, repoBindingId: optionalKey(String4) },
14391
14587
  success: Struct({ repoBindingId: String4, branch: String4, revision: String4 }),
14392
14588
  error: RunnerRpcError
14393
- }), make6("MergeChangeRequest", {
14589
+ }), make5("MergeChangeRequest", {
14394
14590
  payload: {
14395
14591
  lease: ProgramLease,
14396
14592
  step: String4,
@@ -14403,7 +14599,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14403
14599
  Struct({ status: Literal("moved"), head: String4 })
14404
14600
  ]),
14405
14601
  error: RunnerRpcError
14406
- }), make6("ApproveChangeRequest", {
14602
+ }), make5("ApproveChangeRequest", {
14407
14603
  payload: {
14408
14604
  lease: ProgramLease,
14409
14605
  step: String4,
@@ -14418,7 +14614,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14418
14614
  Struct({ approved: Literal(false), reason: String4 })
14419
14615
  ]),
14420
14616
  error: RunnerRpcError
14421
- }), make6("CloseChangeRequest", {
14617
+ }), make5("CloseChangeRequest", {
14422
14618
  payload: {
14423
14619
  lease: ProgramLease,
14424
14620
  step: String4,
@@ -14428,7 +14624,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14428
14624
  },
14429
14625
  success: Struct({ closed: Boolean2, head: optionalKey(String4) }),
14430
14626
  error: RunnerRpcError
14431
- }), make6("RerunPipeline", {
14627
+ }), make5("RerunPipeline", {
14432
14628
  payload: {
14433
14629
  lease: ProgramLease,
14434
14630
  step: String4,
@@ -14438,7 +14634,7 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14438
14634
  },
14439
14635
  success: Struct({ head: String4, pipelines: Int }),
14440
14636
  error: RunnerRpcError
14441
- }), make6("PublishRelease", {
14637
+ }), make5("PublishRelease", {
14442
14638
  payload: {
14443
14639
  lease: ProgramLease,
14444
14640
  step: String4,
@@ -14449,14 +14645,14 @@ class RunnerCapabilityRpcs extends make7(make6("PutQuestion", {
14449
14645
  },
14450
14646
  success: Struct({ tag: String4, revision: String4, url: String4 }),
14451
14647
  error: RunnerRpcError
14452
- }), make6("ProgramSecrets", {
14648
+ }), make5("ProgramSecrets", {
14453
14649
  payload: { lease: ProgramLease },
14454
14650
  success: Record(String4, String4),
14455
14651
  error: RunnerRpcError
14456
14652
  })).middleware(RunnerAuthentication) {
14457
14653
  }
14458
14654
 
14459
- class RunnerRunFileRpcs extends make7(make6("CreateRunFile", {
14655
+ class RunnerRunFileRpcs extends make6(make5("CreateRunFile", {
14460
14656
  payload: {
14461
14657
  lease: ProgramLease,
14462
14658
  step: String4,
@@ -14468,11 +14664,11 @@ class RunnerRunFileRpcs extends make7(make6("CreateRunFile", {
14468
14664
  },
14469
14665
  success: Struct({ file: RunFileRecord, upload: optional(RunFileUpload) }),
14470
14666
  error: Union([RunnerRpcError, RunFileRefused])
14471
- }), make6("RunFileParts", {
14667
+ }), make5("RunFileParts", {
14472
14668
  payload: { lease: ProgramLease, fileId: String4, partNumbers: ArraySchema(Int) },
14473
14669
  success: Struct({ parts: ArraySchema(RunFilePartUrl) }),
14474
14670
  error: RunnerRpcError
14475
- }), make6("CompleteRunFile", {
14671
+ }), make5("CompleteRunFile", {
14476
14672
  payload: { lease: ProgramLease, fileId: String4, parts: optional(ArraySchema(UploadedRunFilePart)) },
14477
14673
  success: RunFileRecord,
14478
14674
  error: RunnerRpcError
@@ -14561,7 +14757,7 @@ function toStoredSession(token, existingRefreshToken) {
14561
14757
  }
14562
14758
  function startLoopbackServer(input) {
14563
14759
  return gen(function* () {
14564
- const code = yield* make16();
14760
+ const code = yield* make15();
14565
14761
  const context2 = yield* context();
14566
14762
  const runSyncExit = runSyncExitWith(context2);
14567
14763
  const server = yield* acquireRelease(sync2(() => Bun.serve({
@@ -15101,7 +15297,7 @@ var openConnection = (transport) => gen(function* () {
15101
15297
  let lastId = 0;
15102
15298
  let lost = false;
15103
15299
  const notifications = yield* unbounded2();
15104
- const ended = yield* make16();
15300
+ const ended = yield* make15();
15105
15301
  const settle = (line) => match(flatMap(decodeJsonStringOption(line), decodeUnknownOption(Response2)), {
15106
15302
  onNone: () => match(flatMap(decodeJsonStringOption(line), decodeUnknownOption(Notification)), {
15107
15303
  onNone: () => void_3,
@@ -15128,7 +15324,7 @@ var openConnection = (transport) => gen(function* () {
15128
15324
  if (lost)
15129
15325
  return yield* new HerdrCoreConnectionLost2({ method });
15130
15326
  const id = ++lastId;
15131
- const deferred = yield* make16();
15327
+ const deferred = yield* make15();
15132
15328
  pending.set(id, { method, deferred });
15133
15329
  yield* pipe.write(encodeJsonStringSync({ jsonrpc: "2.0", id, method, params }));
15134
15330
  return yield* _await(deferred);
@@ -15202,14 +15398,14 @@ var herdrCoreOver = (transport) => ({
15202
15398
  return { type: "event", terminal: event.value.terminal, kind: event.value.type, data: event.value.data };
15203
15399
  };
15204
15400
  const snapshot = { type: "snapshot", terminals: subscribed.terminals };
15205
- return concat(make11(snapshot), fromQueue(notifications).pipe(map2(toEvent), filter((event) => event !== undefined)));
15401
+ return concat(make10(snapshot), fromQueue(notifications).pipe(map2(toEvent), filter((event) => event !== undefined)));
15206
15402
  }))
15207
15403
  });
15208
15404
  var spawnedTransport = (env) => gen(function* () {
15209
15405
  const spawner = yield* ChildProcessSpawner;
15210
15406
  const input = yield* unbounded2();
15211
15407
  const encoder = new TextEncoder;
15212
- const handle = yield* spawner.spawn(make3("herdr-core", ["connect"], {
15408
+ const handle = yield* spawner.spawn(make2("herdr-core", ["connect"], {
15213
15409
  extendEnv: false,
15214
15410
  env,
15215
15411
  stdin: fromQueue(input),
@@ -15240,7 +15436,7 @@ var updateHerdrCore2 = (options) => gen(function* () {
15240
15436
  const spawner = yield* ChildProcessSpawner;
15241
15437
  const env = coreEnv(options);
15242
15438
  const run = (args) => gen(function* () {
15243
- const handle = yield* spawner.spawn(make3("herdr-core", args, { extendEnv: false, env, stdin: "ignore" }));
15439
+ const handle = yield* spawner.spawn(make2("herdr-core", args, { extendEnv: false, env, stdin: "ignore" }));
15244
15440
  const [stdout, stderr, exitCode] = yield* all3([
15245
15441
  mkString(decodeText(handle.stdout)),
15246
15442
  mkString(decodeText(handle.stderr)),
@@ -15266,7 +15462,7 @@ class CommandFailed2 extends TaggedError("CommandFailed") {
15266
15462
  }
15267
15463
  var runCommand2 = (command, args, options = {}) => gen(function* () {
15268
15464
  const spawner = yield* ChildProcessSpawner;
15269
- const handle = yield* spawner.spawn(make3(command, args, {
15465
+ const handle = yield* spawner.spawn(make2(command, args, {
15270
15466
  stdin: "ignore",
15271
15467
  ...options.cwd === undefined ? undefined : { cwd: options.cwd },
15272
15468
  ...options.env === undefined ? undefined : { extendEnv: true, env: options.env }
@@ -15292,8 +15488,8 @@ var shellOutputTailChars2 = 64 * 1024;
15292
15488
  var runProcess2 = (argv, options) => gen(function* () {
15293
15489
  const spawner = yield* ChildProcessSpawner;
15294
15490
  const [command, ...args] = argv;
15295
- const handle = yield* spawner.spawn(make3(command, args, {
15296
- stdin: options.stdin === undefined ? "ignore" : make11(new TextEncoder().encode(options.stdin)),
15491
+ const handle = yield* spawner.spawn(make2(command, args, {
15492
+ stdin: options.stdin === undefined ? "ignore" : make10(new TextEncoder().encode(options.stdin)),
15297
15493
  ...options.cwd === undefined ? undefined : { cwd: options.cwd },
15298
15494
  env: options.extendEnv === false ? { ...options.env } : { ...withoutPreloads2(), ...options.env }
15299
15495
  }));
@@ -15716,4 +15912,4 @@ function checkServices(declaration) {
15716
15912
  return isSome(decoded) ? [...new Set(decoded.value.services)] : undefined;
15717
15913
  }
15718
15914
 
15719
- export { Clock, currentTimeMillis, 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, RunWaitUntils, isTestReportName, checkTests, 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, post, put, setHeaders, acceptJson, bodyUint8Array, bodyJsonUnsafe, bodyUrlParams, 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 };
15915
+ export { Clock, currentTimeMillis, 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, AgentHarnessIds, AgentSkillRequirement, AgentMcpServerRequirement, AgentEnvironmentFragment, findForbiddenAgentEnvironmentSecretPath, RepoBindingProviders, RepoBindingCredentialProviderTypes, findForbiddenRepoBindingSecretPath, runnerAgentSandboxPolicy, agentNetworkAllowlist, verificationNetworkAllowlist, programNetworkHosts, ContextPackModes, DefaultContextPackMode, ProposalStatuses, ProposalTargetTypes, canonicalJson, canonicalSha256, RunDisplayStates, RunWaitUntils, isTestReportName, checkTests, 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, make4, get, post, put, setHeaders, acceptJson, bodyUint8Array, bodyJsonUnsafe, bodyUrlParams, schemaBodyJson, filterStatusOk, HttpClient, execute, get2, Fetch, layer4, Socket, SocketReadError, SocketError, WebSocketConstructor, layerWebSocketConstructorGlobal, layerWebSocket, runDisplayLabels, listedSummary, KitDigest, defaultKitName, LoopCapabilities, LoopManifest, AgentDeclaration, KitDeclarations, 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, make5, exitSchema, ParseOptions, RpcClientDefect, RpcClientError, make6, 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 };