@kitman-sh/software-engineering 0.11.5 → 0.11.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/bundle.js CHANGED
@@ -2397,6 +2397,7 @@ var Equivalence = (self, that) => matchPair(self, that, {
2397
2397
  onInfinity: (self, that) => self.value._tag === that.value._tag
2398
2398
  });
2399
2399
  var min2 = /* @__PURE__ */ min(Order);
2400
+ var isLessThanOrEqualTo2 = /* @__PURE__ */ isLessThanOrEqualTo(Order);
2400
2401
  var equals2 = /* @__PURE__ */ dual(2, (self, that) => Equivalence(self, that));
2401
2402
  var parts = (self) => {
2402
2403
  if (self.value._tag === "Infinity") {
@@ -15211,10 +15212,42 @@ var makeExecute = /* @__PURE__ */ fnUntraced2(function* (activity) {
15211
15212
  }, (effect, activity) => withSpan2(effect, activity.name, {
15212
15213
  captureStackTrace: false
15213
15214
  }));
15215
+ // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/workflow/DurableClock.js
15216
+ var TypeId21 = "~effect/workflow/DurableClock";
15217
+ var make16 = (options) => ({
15218
+ [TypeId21]: TypeId21,
15219
+ name: options.name,
15220
+ duration: fromInputUnsafe2(options.duration),
15221
+ deferred: make14(`DurableClock/${options.name}`)
15222
+ });
15223
+ var EngineTag4 = /* @__PURE__ */ Service("effect/workflow/WorkflowEngine");
15224
+ var InstanceTag4 = /* @__PURE__ */ Service("effect/workflow/WorkflowEngine/WorkflowInstance");
15225
+ var sleep3 = /* @__PURE__ */ fnUntraced2(function* (options) {
15226
+ const duration = fromInputUnsafe2(options.duration);
15227
+ if (isZero(duration)) {
15228
+ return;
15229
+ }
15230
+ const inMemoryThreshold = options.inMemoryThreshold !== undefined ? fromInputUnsafe2(options.inMemoryThreshold) : defaultInMemoryThreshold;
15231
+ if (isLessThanOrEqualTo2(duration, inMemoryThreshold)) {
15232
+ return yield* make15({
15233
+ name: `DurableClock/${options.name}`,
15234
+ execute: sleep2(duration)
15235
+ });
15236
+ }
15237
+ const engine = yield* EngineTag4;
15238
+ const instance = yield* InstanceTag4;
15239
+ const clock = make16(options);
15240
+ yield* engine.scheduleClock(instance.workflow, {
15241
+ executionId: instance.executionId,
15242
+ clock
15243
+ });
15244
+ return yield* await_2(clock.deferred);
15245
+ });
15246
+ var defaultInMemoryThreshold = /* @__PURE__ */ seconds(60);
15214
15247
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/MutableRef.js
15215
- var TypeId21 = "~effect/MutableRef";
15248
+ var TypeId22 = "~effect/MutableRef";
15216
15249
  var MutableRefProto = {
15217
- [TypeId21]: TypeId21,
15250
+ [TypeId22]: TypeId22,
15218
15251
  ...PipeInspectableProto,
15219
15252
  toJSON() {
15220
15253
  return {
@@ -15223,7 +15256,7 @@ var MutableRefProto = {
15223
15256
  };
15224
15257
  }
15225
15258
  };
15226
- var make16 = (value) => {
15259
+ var make17 = (value) => {
15227
15260
  const ref = Object.create(MutableRefProto);
15228
15261
  ref.current = value;
15229
15262
  return ref;
@@ -15231,7 +15264,7 @@ var make16 = (value) => {
15231
15264
 
15232
15265
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/MutableList.js
15233
15266
  var Empty = /* @__PURE__ */ Symbol.for("effect/MutableList/Empty");
15234
- var make17 = () => ({
15267
+ var make18 = () => ({
15235
15268
  head: undefined,
15236
15269
  tail: undefined,
15237
15270
  length: 0
@@ -15341,7 +15374,7 @@ var take = (self) => {
15341
15374
  };
15342
15375
 
15343
15376
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Queue.js
15344
- var TypeId22 = "~effect/Queue";
15377
+ var TypeId23 = "~effect/Queue";
15345
15378
  var EnqueueTypeId = "~effect/Queue/Enqueue";
15346
15379
  var DequeueTypeId = "~effect/Queue/Dequeue";
15347
15380
  var variance = {
@@ -15349,7 +15382,7 @@ var variance = {
15349
15382
  _E: identity
15350
15383
  };
15351
15384
  var QueueProto = {
15352
- [TypeId22]: variance,
15385
+ [TypeId23]: variance,
15353
15386
  [EnqueueTypeId]: variance,
15354
15387
  [DequeueTypeId]: variance,
15355
15388
  ...PipeInspectableProto,
@@ -15361,12 +15394,12 @@ var QueueProto = {
15361
15394
  };
15362
15395
  }
15363
15396
  };
15364
- var make18 = (options) => withFiber((fiber) => {
15397
+ var make19 = (options) => withFiber((fiber) => {
15365
15398
  const self = Object.create(QueueProto);
15366
15399
  self.dispatcher = fiber.currentDispatcher;
15367
15400
  self.capacity = options?.capacity ?? Number.POSITIVE_INFINITY;
15368
15401
  self.strategy = options?.strategy ?? "suspend";
15369
- self.messages = make17();
15402
+ self.messages = make18();
15370
15403
  self.scheduleRunning = false;
15371
15404
  self.state = {
15372
15405
  _tag: "Open",
@@ -15376,10 +15409,10 @@ var make18 = (options) => withFiber((fiber) => {
15376
15409
  };
15377
15410
  return succeed3(self);
15378
15411
  });
15379
- var bounded = (capacity) => make18({
15412
+ var bounded = (capacity) => make19({
15380
15413
  capacity
15381
15414
  });
15382
- var sliding = (capacity) => make18({
15415
+ var sliding = (capacity) => make19({
15383
15416
  capacity,
15384
15417
  strategy: "sliding"
15385
15418
  });
@@ -15662,10 +15695,10 @@ var finalize = (self, exit) => {
15662
15695
  };
15663
15696
 
15664
15697
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Channel.js
15665
- var TypeId23 = "~effect/Channel";
15666
- var isChannel = (u) => hasProperty(u, TypeId23);
15698
+ var TypeId24 = "~effect/Channel";
15699
+ var isChannel = (u) => hasProperty(u, TypeId24);
15667
15700
  var ChannelProto = {
15668
- [TypeId23]: {
15701
+ [TypeId24]: {
15669
15702
  _Env: identity,
15670
15703
  _InErr: identity,
15671
15704
  _InElem: identity,
@@ -15690,7 +15723,7 @@ var fromTransformBracket = (f) => fromTransform(fnUntraced2(function* (upstream,
15690
15723
  return onError2(pull, onCause);
15691
15724
  }));
15692
15725
  var toTransform = (channel) => channel.transform;
15693
- var asyncQueue = (scope, f, options) => make18({
15726
+ var asyncQueue = (scope, f, options) => make19({
15694
15727
  capacity: options?.bufferSize,
15695
15728
  strategy: options?.strategy
15696
15729
  }).pipe(tap2((queue) => addFinalizer2(scope, shutdown(queue))), tap2((queue) => provide(f(queue), scope).pipe(catchCause2((cause) => failCause4(queue, cause)), forkIn2(scope, {
@@ -15710,7 +15743,7 @@ var fromReadableStream = (options) => fromTransform((_, scope) => readableStream
15710
15743
  }));
15711
15744
  var readableStreamToPullUnsafe = (options) => {
15712
15745
  const reader = options.readable.getReader();
15713
- const exit = options.exit ?? make16(undefined);
15746
+ const exit = options.exit ?? make17(undefined);
15714
15747
  const pull = suspend2(() => {
15715
15748
  if (exit.current)
15716
15749
  return exit.current;
@@ -15925,7 +15958,7 @@ var runFold = /* @__PURE__ */ dual(3, (self, initial, f) => suspend2(() => {
15925
15958
  var toPullScoped = (self, scope) => toTransform(self)(done2(), scope);
15926
15959
 
15927
15960
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/internal/stream.js
15928
- var TypeId24 = "~effect/Stream";
15961
+ var TypeId25 = "~effect/Stream";
15929
15962
  var streamVariance = {
15930
15963
  _R: identity,
15931
15964
  _E: identity,
@@ -15935,7 +15968,7 @@ var Stream = function(channel) {
15935
15968
  this.channel = channel;
15936
15969
  };
15937
15970
  Stream.prototype = {
15938
- [TypeId24]: streamVariance,
15971
+ [TypeId25]: streamVariance,
15939
15972
  pipe() {
15940
15973
  return pipeArguments(this, arguments);
15941
15974
  }
@@ -15943,7 +15976,7 @@ Stream.prototype = {
15943
15976
  var fromChannel = (channel) => new Stream(channel);
15944
15977
 
15945
15978
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/internal/rcRef.js
15946
- var TypeId25 = "~effect/RcRef";
15979
+ var TypeId26 = "~effect/RcRef";
15947
15980
  var stateEmpty = {
15948
15981
  _tag: "Empty"
15949
15982
  };
@@ -15956,7 +15989,7 @@ var variance2 = {
15956
15989
  };
15957
15990
 
15958
15991
  class RcRefImpl {
15959
- [TypeId25] = variance2;
15992
+ [TypeId26] = variance2;
15960
15993
  pipe() {
15961
15994
  return pipeArguments(this, arguments);
15962
15995
  }
@@ -15972,7 +16005,7 @@ class RcRefImpl {
15972
16005
  this.idleTimeToLive = idleTimeToLive;
15973
16006
  }
15974
16007
  }
15975
- var make19 = (options) => withFiber2((fiber) => {
16008
+ var make20 = (options) => withFiber2((fiber) => {
15976
16009
  const context = fiber.context;
15977
16010
  const scope = get(context, Scope);
15978
16011
  const ref = new RcRefImpl(options.acquire, context, scope, options.idleTimeToLive !== undefined ? fromInputUnsafe2(options.idleTimeToLive) : undefined);
@@ -16081,11 +16114,11 @@ var release = (self, state) => {
16081
16114
  };
16082
16115
 
16083
16116
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/RcRef.js
16084
- var make20 = make19;
16117
+ var make21 = make20;
16085
16118
  var get4 = get3;
16086
16119
 
16087
16120
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Sink.js
16088
- var TypeId26 = "~effect/Sink";
16121
+ var TypeId27 = "~effect/Sink";
16089
16122
  var endVoid = /* @__PURE__ */ succeed7([undefined]);
16090
16123
  var sinkVariance = {
16091
16124
  _A: identity,
@@ -16095,12 +16128,12 @@ var sinkVariance = {
16095
16128
  _R: identity
16096
16129
  };
16097
16130
  var SinkProto = {
16098
- [TypeId26]: sinkVariance,
16131
+ [TypeId27]: sinkVariance,
16099
16132
  pipe() {
16100
16133
  return pipeArguments(this, arguments);
16101
16134
  }
16102
16135
  };
16103
- var isSink = (u) => hasProperty(u, TypeId26);
16136
+ var isSink = (u) => hasProperty(u, TypeId27);
16104
16137
  var fromChannel2 = (channel) => fromTransform2((upstream, scope) => toTransform(channel)(upstream, scope).pipe(flatMap3(forever3({
16105
16138
  disableYield: true
16106
16139
  })), catchDone(succeed7)));
@@ -16122,8 +16155,8 @@ var forEachArray = (f) => fromTransform2((upstream) => upstream.pipe(flatMap3(f)
16122
16155
  var unwrap3 = (effect) => fromChannel2(unwrap2(map8(effect, toChannel)));
16123
16156
 
16124
16157
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Stream.js
16125
- var TypeId27 = "~effect/Stream";
16126
- var isStream = (u) => hasProperty(u, TypeId27);
16158
+ var TypeId28 = "~effect/Stream";
16159
+ var isStream = (u) => hasProperty(u, TypeId28);
16127
16160
  var fromChannel3 = fromChannel;
16128
16161
  var fromPull2 = (pull) => fromChannel3(fromPull(pull));
16129
16162
  var transformPull2 = (self, f) => fromChannel3(fromTransform((_, scope) => flatMap3(toPullScoped(self.channel, scope), (pull) => f(pull, scope))));
@@ -16240,10 +16273,10 @@ var toReadableStreamWith = /* @__PURE__ */ dual((args) => isStream(args[0]), (se
16240
16273
  });
16241
16274
  var toReadableStreamEffect = /* @__PURE__ */ dual((args) => isStream(args[0]), (self, options) => map8(context2(), (context) => toReadableStreamWith(self, context, options)));
16242
16275
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/FiberMap.js
16243
- var TypeId28 = "~effect/FiberMap";
16244
- var isFiberMap = (u) => hasProperty(u, TypeId28);
16276
+ var TypeId29 = "~effect/FiberMap";
16277
+ var isFiberMap = (u) => hasProperty(u, TypeId29);
16245
16278
  var Proto7 = {
16246
- [TypeId28]: TypeId28,
16279
+ [TypeId29]: TypeId29,
16247
16280
  [Symbol.iterator]() {
16248
16281
  if (this.state._tag === "Closed") {
16249
16282
  return empty();
@@ -16268,7 +16301,7 @@ var makeUnsafe5 = (backing, deferred) => {
16268
16301
  self.deferred = deferred;
16269
16302
  return self;
16270
16303
  };
16271
- var make21 = () => acquireRelease2(sync2(() => makeUnsafe5(empty4(), makeUnsafe2())), (map) => suspend2(() => {
16304
+ var make22 = () => acquireRelease2(sync2(() => makeUnsafe5(empty4(), makeUnsafe2())), (map) => suspend2(() => {
16272
16305
  const state = map.state;
16273
16306
  if (state._tag === "Closed")
16274
16307
  return void_3;
@@ -16561,7 +16594,7 @@ var layerMemory = /* @__PURE__ */ effect(WorkflowEngine)(/* @__PURE__ */ gen2(fu
16561
16594
  }), forkIn2(entry.scope));
16562
16595
  });
16563
16596
  const deferredResults = new Map;
16564
- const clocks = yield* make21();
16597
+ const clocks = yield* make22();
16565
16598
  const engine = makeUnsafe6({
16566
16599
  register: fnUntraced2(function* (workflow, execute) {
16567
16600
  workflows.set(workflow._tag, {
@@ -17238,7 +17271,7 @@ var isIgnorable = (error) => isMissing(error) || error.reason._tag === "Permissi
17238
17271
  var isNotLink = (error) => isIgnorable(error) || error.reason._tag === "Unknown";
17239
17272
  var DIRECTORY_CONCURRENCY = 16;
17240
17273
  var byName = /* @__PURE__ */ mapInput(String2, (entry) => entry.name);
17241
- var make22 = (fs) => (pattern, options) => walk(fs, compile2([pattern], options?.dot ?? false), options);
17274
+ var make23 = (fs) => (pattern, options) => walk(fs, compile2([pattern], options?.dot ?? false), options);
17242
17275
  var walk = /* @__PURE__ */ fnUntraced2(function* (fs, compiled, options) {
17243
17276
  if (compiled.initial.size === 0) {
17244
17277
  return [];
@@ -17379,7 +17412,7 @@ var walk = /* @__PURE__ */ fnUntraced2(function* (fs, compiled, options) {
17379
17412
  });
17380
17413
 
17381
17414
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/PlatformError.js
17382
- var TypeId29 = "~effect/PlatformError";
17415
+ var TypeId30 = "~effect/PlatformError";
17383
17416
 
17384
17417
  class BadArgument extends (/* @__PURE__ */ TaggedError2("BadArgument")) {
17385
17418
  get message() {
@@ -17406,22 +17439,22 @@ class PlatformError extends (/* @__PURE__ */ TaggedError2("PlatformError")) {
17406
17439
  });
17407
17440
  }
17408
17441
  }
17409
- [TypeId29] = TypeId29;
17442
+ [TypeId30] = TypeId30;
17410
17443
  get message() {
17411
17444
  return this.reason.message;
17412
17445
  }
17413
17446
  }
17414
- var isPlatformError = (u) => hasProperty(u, TypeId29);
17447
+ var isPlatformError = (u) => hasProperty(u, TypeId30);
17415
17448
  var systemError = (options) => new PlatformError(new SystemError(options));
17416
17449
  var badArgument = (options) => new PlatformError(new BadArgument(options));
17417
17450
 
17418
17451
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/FileSystem.js
17419
- var TypeId30 = "~effect/FileSystem";
17452
+ var TypeId31 = "~effect/FileSystem";
17420
17453
  var FileSystem = /* @__PURE__ */ Service("effect/FileSystem");
17421
- var make23 = (impl) => FileSystem.of({
17454
+ var make24 = (impl) => FileSystem.of({
17422
17455
  ...impl,
17423
- [TypeId30]: TypeId30,
17424
- glob: make22(impl),
17456
+ [TypeId31]: TypeId31,
17457
+ glob: make23(impl),
17425
17458
  exists: (path) => pipe(impl.access(path), as2(true), catchTag2("PlatformError", (e) => e.reason._tag === "NotFound" ? succeed7(false) : fail7(e))),
17426
17459
  readFileString: (path, encoding) => flatMap3(impl.readFile(path), (_) => try_3({
17427
17460
  try: () => new TextDecoder(encoding).decode(_),
@@ -17476,11 +17509,11 @@ class WatchBackend extends (/* @__PURE__ */ Service()("effect/FileSystem/WatchBa
17476
17509
  }
17477
17510
 
17478
17511
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/HttpBody.js
17479
- var TypeId31 = "~effect/http/HttpBody";
17512
+ var TypeId32 = "~effect/http/HttpBody";
17480
17513
  class Proto8 {
17481
- [TypeId31];
17514
+ [TypeId32];
17482
17515
  constructor() {
17483
- this[TypeId31] = TypeId31;
17516
+ this[TypeId32] = TypeId32;
17484
17517
  }
17485
17518
  [NodeInspectSymbol]() {
17486
17519
  return this.toJSON();
@@ -17535,7 +17568,7 @@ var buffer2 = globalThis.Buffer;
17535
17568
  var encodeText = buffer2 !== undefined ? (body) => buffer2.from(body, "utf8") : (body) => encoder4.encode(body);
17536
17569
 
17537
17570
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/HttpClientError.js
17538
- var TypeId32 = "~effect/http/HttpClientError";
17571
+ var TypeId33 = "~effect/http/HttpClientError";
17539
17572
  class HttpClientError extends (/* @__PURE__ */ TaggedError2("HttpClientError")) {
17540
17573
  constructor(props) {
17541
17574
  if ("cause" in props.reason) {
@@ -17547,7 +17580,7 @@ class HttpClientError extends (/* @__PURE__ */ TaggedError2("HttpClientError"))
17547
17580
  super(props);
17548
17581
  }
17549
17582
  }
17550
- [TypeId32] = TypeId32;
17583
+ [TypeId33] = TypeId33;
17551
17584
  get request() {
17552
17585
  return this.reason.request;
17553
17586
  }
@@ -17651,7 +17684,7 @@ class EmptyBodyError extends (/* @__PURE__ */ TaggedError2("EmptyBodyError")) {
17651
17684
  }
17652
17685
  }
17653
17686
 
17654
- class HttpClientErrorSchema extends (/* @__PURE__ */ Error4(TypeId32)({
17687
+ class HttpClientErrorSchema extends (/* @__PURE__ */ Error4(TypeId33)({
17655
17688
  _tag: /* @__PURE__ */ tag("HttpError"),
17656
17689
  kind: /* @__PURE__ */ Literals(["EncodeError", "DecodeError", "TransportError", "InvalidUrlError", "StatusCodeError", "EmptyBodyError"]),
17657
17690
  cause: /* @__PURE__ */ optional2(/* @__PURE__ */ Defect())
@@ -17681,7 +17714,7 @@ var updateContentLength = (headers, body) => {
17681
17714
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/Url.js
17682
17715
  class UrlError extends (/* @__PURE__ */ TaggedError2("UrlError")) {
17683
17716
  }
17684
- var make24 = (url, params, hash) => try_({
17717
+ var make25 = (url, params, hash) => try_({
17685
17718
  try: () => {
17686
17719
  const urlInstance = new URL(url, baseUrl());
17687
17720
  for (let i = 0;i < params.params.length; i++) {
@@ -17712,10 +17745,10 @@ var baseUrl = () => {
17712
17745
  };
17713
17746
 
17714
17747
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/HttpClientRequest.js
17715
- var TypeId33 = "~effect/http/HttpClientRequest";
17716
- var isHttpClientRequest = (u) => hasProperty(u, TypeId33);
17748
+ var TypeId34 = "~effect/http/HttpClientRequest";
17749
+ var isHttpClientRequest = (u) => hasProperty(u, TypeId34);
17717
17750
  var Proto9 = {
17718
- [TypeId33]: TypeId33,
17751
+ [TypeId34]: TypeId34,
17719
17752
  ...BaseProto,
17720
17753
  toJSON() {
17721
17754
  return {
@@ -17743,12 +17776,12 @@ function makeWith(method, url, urlParams, hash, headers, body) {
17743
17776
  return self;
17744
17777
  }
17745
17778
  var empty10 = /* @__PURE__ */ makeWith("GET", "", empty6, /* @__PURE__ */ none2(), empty5, empty9);
17746
- var make25 = (method) => (url, options) => modify(empty10, {
17779
+ var make26 = (method) => (url, options) => modify(empty10, {
17747
17780
  method,
17748
17781
  url,
17749
17782
  ...options ?? undefined
17750
17783
  });
17751
- var put = /* @__PURE__ */ make25("PUT");
17784
+ var put = /* @__PURE__ */ make26("PUT");
17752
17785
  var modify = /* @__PURE__ */ dual(2, (self, options) => {
17753
17786
  let result = self;
17754
17787
  if (options.method) {
@@ -17800,7 +17833,7 @@ var setBody = /* @__PURE__ */ dual(2, (self, body) => {
17800
17833
  });
17801
17834
  var bodyUint8Array = /* @__PURE__ */ dual((args) => isHttpClientRequest(args[0]), (self, body, contentType) => setBody(self, uint8Array(body, contentType)));
17802
17835
  function toUrl(self) {
17803
- const r = make24(self.url, self.urlParams, getOrUndefined(self.hash));
17836
+ const r = make25(self.url, self.urlParams, getOrUndefined(self.hash));
17804
17837
  if (isSuccess2(r)) {
17805
17838
  return some2(r.success);
17806
17839
  }
@@ -17808,7 +17841,7 @@ function toUrl(self) {
17808
17841
  }
17809
17842
 
17810
17843
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/HttpIncomingMessage.js
17811
- var TypeId34 = "~effect/http/HttpIncomingMessage";
17844
+ var TypeId35 = "~effect/http/HttpIncomingMessage";
17812
17845
  var inspect = (self, that) => {
17813
17846
  return {
17814
17847
  ...that,
@@ -17822,7 +17855,7 @@ var WebSourceSymbol = "~effect/http/HttpClientResponse/WebSource";
17822
17855
  var getWebSource = (self) => self[WebSourceSymbol]?.();
17823
17856
 
17824
17857
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/HttpClientResponse.js
17825
- var TypeId35 = "~effect/http/HttpClientResponse";
17858
+ var TypeId36 = "~effect/http/HttpClientResponse";
17826
17859
  var fromWeb = (request, source) => new WebHttpClientResponse(request, source);
17827
17860
  var filterStatusOk = (self) => self.status >= 200 && self.status < 300 ? succeed7(self) : fail7(new HttpClientError({
17828
17861
  reason: new StatusCodeError({
@@ -17833,16 +17866,16 @@ var filterStatusOk = (self) => self.status >= 200 && self.status < 300 ? succeed
17833
17866
  }));
17834
17867
 
17835
17868
  class WebHttpClientResponse extends Class2 {
17836
- [TypeId34];
17837
17869
  [TypeId35];
17870
+ [TypeId36];
17838
17871
  request;
17839
17872
  source;
17840
17873
  constructor(request, source) {
17841
17874
  super();
17842
17875
  this.request = request;
17843
17876
  this.source = source;
17844
- this[TypeId34] = TypeId34;
17845
17877
  this[TypeId35] = TypeId35;
17878
+ this[TypeId36] = TypeId36;
17846
17879
  }
17847
17880
  toJSON() {
17848
17881
  return inspect(this, {
@@ -17970,10 +18003,10 @@ class WebHttpClientResponse extends Class2 {
17970
18003
  }
17971
18004
 
17972
18005
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/socket/Socket.js
17973
- var TypeId36 = "~effect/socket/Socket";
18006
+ var TypeId37 = "~effect/socket/Socket";
17974
18007
  var Socket = /* @__PURE__ */ Service("effect/socket/Socket");
17975
- var make26 = (options) => Socket.of({
17976
- [TypeId36]: TypeId36,
18008
+ var make27 = (options) => Socket.of({
18009
+ [TypeId37]: TypeId37,
17977
18010
  reader: options.reader,
17978
18011
  writer: options.writer
17979
18012
  });
@@ -18296,7 +18329,7 @@ var fromWebSocket = (acquire, options) => withFiber2((fiber) => {
18296
18329
  write,
18297
18330
  writeAll
18298
18331
  });
18299
- return succeed7(make26({
18332
+ return succeed7(make27({
18300
18333
  reader,
18301
18334
  writer
18302
18335
  }));
@@ -18305,11 +18338,11 @@ var defaultHighWaterMark = 64 * 1024;
18305
18338
  var layerWebSocket = /* @__PURE__ */ flow(makeWebSocket, /* @__PURE__ */ effect(Socket));
18306
18339
 
18307
18340
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Path.js
18308
- var TypeId37 = "~effect/Path";
18341
+ var TypeId38 = "~effect/Path";
18309
18342
  var Path2 = /* @__PURE__ */ Service("effect/Path");
18310
- var make27 = (impl) => Path2.of({
18343
+ var make28 = (impl) => Path2.of({
18311
18344
  ...impl,
18312
- [TypeId37]: TypeId37,
18345
+ [TypeId38]: TypeId38,
18313
18346
  resolveWithin(root, input) {
18314
18347
  if (impl.parse(input).root !== "")
18315
18348
  return none2();
@@ -18365,7 +18398,7 @@ var addHeaderAttributes = (span, phase, headers, filter, redactedNames) => {
18365
18398
  };
18366
18399
 
18367
18400
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/http/HttpClient.js
18368
- var TypeId38 = "~effect/http/HttpClient";
18401
+ var TypeId39 = "~effect/http/HttpClient";
18369
18402
  var HttpClient = /* @__PURE__ */ Service("effect/HttpClient");
18370
18403
  var transformResponse = /* @__PURE__ */ dual(2, (self, f) => makeWith2((request) => f(self.postprocess(request)), self.preprocess));
18371
18404
  var makeWith2 = (postprocess, preprocess) => {
@@ -18378,7 +18411,7 @@ var makeWith2 = (postprocess, preprocess) => {
18378
18411
  return self;
18379
18412
  };
18380
18413
  var Proto10 = {
18381
- [TypeId38]: TypeId38,
18414
+ [TypeId39]: TypeId39,
18382
18415
  pipe() {
18383
18416
  return pipeArguments(this, arguments);
18384
18417
  },
@@ -18389,13 +18422,13 @@ var Proto10 = {
18389
18422
  };
18390
18423
  },
18391
18424
  .../* @__PURE__ */ Object.fromEntries(/* @__PURE__ */ allShort.map(([fullMethod, method]) => [method, function(url, options) {
18392
- return this.execute(make25(fullMethod)(url, options));
18425
+ return this.execute(make26(fullMethod)(url, options));
18393
18426
  }]))
18394
18427
  };
18395
- var make28 = (f) => makeWith2((effect) => flatMap3(effect, (request) => withFiber2((fiber) => {
18428
+ var make29 = (f) => makeWith2((effect) => flatMap3(effect, (request) => withFiber2((fiber) => {
18396
18429
  const scopedController = scopedRequests.get(request);
18397
18430
  const controller = scopedController ?? new AbortController;
18398
- const urlResult = make24(request.url, request.urlParams, getOrUndefined(request.hash));
18431
+ const urlResult = make25(request.url, request.urlParams, getOrUndefined(request.hash));
18399
18432
  if (isFailure2(urlResult)) {
18400
18433
  return fail7(new HttpClientError({
18401
18434
  reason: new InvalidUrlError({
@@ -18529,8 +18562,8 @@ class InterruptibleResponse {
18529
18562
  this.original = original;
18530
18563
  this.controller = controller;
18531
18564
  }
18565
+ [TypeId36] = TypeId36;
18532
18566
  [TypeId35] = TypeId35;
18533
- [TypeId34] = TypeId34;
18534
18567
  applyInterrupt(effect) {
18535
18568
  return suspend2(() => {
18536
18569
  responseRegistry.unregister(this.original);
@@ -18624,9 +18657,9 @@ function Stream2(success, error) {
18624
18657
  }
18625
18658
 
18626
18659
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/rpc/Rpc.js
18627
- var TypeId39 = "~effect/rpc/Rpc";
18660
+ var TypeId40 = "~effect/rpc/Rpc";
18628
18661
  var Proto11 = {
18629
- [TypeId39]: TypeId39,
18662
+ [TypeId40]: TypeId40,
18630
18663
  pipe() {
18631
18664
  return pipeArguments(this, arguments);
18632
18665
  },
@@ -18715,7 +18748,7 @@ var makeProto2 = (options) => {
18715
18748
  Rpc.key = `effect/rpc/Rpc/${options._tag}`;
18716
18749
  return Rpc;
18717
18750
  };
18718
- var make29 = (tag, options) => {
18751
+ var make30 = (tag, options) => {
18719
18752
  const successSchema = options?.success ?? Void2;
18720
18753
  const errorSchema = options?.error ?? Never2;
18721
18754
  const defectSchema = options?.defect ?? Defect();
@@ -18901,7 +18934,7 @@ var makeProto3 = (options) => Object.assign(function() {}, RpcGroupProto, {
18901
18934
  requests: options.requests,
18902
18935
  annotations: options.annotations
18903
18936
  });
18904
- var make30 = (...rpcs) => makeProto3({
18937
+ var make31 = (...rpcs) => makeProto3({
18905
18938
  requests: new Map(rpcs.map((rpc) => [rpc._tag, rpc])),
18906
18939
  annotations: empty3()
18907
18940
  });
@@ -19051,6 +19084,7 @@ class StepFailed extends TaggedError3()("StepFailed", {
19051
19084
  return `Step "${this.step}" failed: ${this.reason}`;
19052
19085
  }
19053
19086
  }
19087
+ var effectUnconfirmed = "effect_unconfirmed";
19054
19088
 
19055
19089
  class OutputInvalid extends TaggedError3()("OutputInvalid", {
19056
19090
  step: String5,
@@ -19746,12 +19780,12 @@ function makeProvider(load, mapInput) {
19746
19780
  function makeSource(get, transform) {
19747
19781
  return makeProvider((path) => get(transform(path)), (f) => makeSource(get, (path) => f(transform(path))));
19748
19782
  }
19749
- function make31(get) {
19783
+ function make32(get) {
19750
19784
  return makeSource(get, identityPath);
19751
19785
  }
19752
19786
  function fromUnknown(root, options) {
19753
19787
  const preserveEmptyStrings = options?.preserveEmptyStrings === true;
19754
- return make31((path) => succeed7(nodeAtJson(root, path, preserveEmptyStrings)));
19788
+ return make32((path) => succeed7(nodeAtJson(root, path, preserveEmptyStrings)));
19755
19789
  }
19756
19790
  function nodeAtJson(root, path, preserveEmptyStrings) {
19757
19791
  let cur = root;
@@ -19801,7 +19835,7 @@ function emptyStringAsMissing(value, preserveEmptyStrings) {
19801
19835
  function fromEnvRecord(env, options) {
19802
19836
  const preserveEmptyStrings = options?.preserveEmptyStrings === true;
19803
19837
  const trie = buildEnvTrie(env);
19804
- return make31((path) => succeed7(nodeAtEnv(trie, env, path, preserveEmptyStrings)));
19838
+ return make32((path) => succeed7(nodeAtEnv(trie, env, path, preserveEmptyStrings)));
19805
19839
  }
19806
19840
  function fromEnv(options) {
19807
19841
  const env = options?.env ?? {
@@ -20874,7 +20908,7 @@ var BaseSync = Union2([
20874
20908
  Struct({ ...merged, catchUp: optionalKey2(CatchUp), ...reported }),
20875
20909
  Struct({ ...Conflict.fields, ...reported })
20876
20910
  ]);
20877
- var afterMerge = "One thing comes before any answer of merged, a clean merge included, and stopping above means stopping after it: before you answer merged, do what the repository's agent instructions say to do once the target branch is merged in, such as regenerating this branch's database migrations on top of the target's. Leave what that changes in the workspace: Kitman commits it.";
20911
+ var afterMerge = "One thing comes before any answer of merged, a clean merge included, and stopping above means stopping after it: before you answer merged, run what the repository's agent instructions (`AGENTS.md` or `CLAUDE.md`, already in your context) name for after merging the target branch, and read the section that line links when it names no command. Regenerate this branch's database migrations on top of the target's when it adds one, and regenerate each generated file whose source the merge changed, such as API contracts, with the command those instructions name. Do not search the repository for these steps: when the instructions name none, there are none. Leave what that changes in the workspace: Kitman commits it.";
20878
20912
  var prompt = (target) => [
20879
20913
  `Kitman merged \`origin/${target}\` into this branch before you started, outside your sandbox, and says what came of it in a note after this brief. Do not fetch, as this workspace has no credential for the forge, and do not run git commands that write, such as \`git add\`, \`git commit\` or \`git merge --abort\`: Kitman finishes the merge itself from your answer.`,
20880
20914
  "If it was already up to date, change nothing and answer up_to_date. If it merged cleanly, answer merged with no settled files and stop: do not review or test anything else.",
@@ -26674,7 +26708,7 @@ var TranscriptSearchResult = Struct({
26674
26708
  });
26675
26709
 
26676
26710
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Config.js
26677
- var TypeId40 = "~effect/Config";
26711
+ var TypeId41 = "~effect/Config";
26678
26712
  class ConfigError {
26679
26713
  _tag = "ConfigError";
26680
26714
  name = "ConfigError";
@@ -26696,14 +26730,14 @@ var Proto13 = {
26696
26730
  return this.parse(fiber.getRef(ConfigProvider));
26697
26731
  }
26698
26732
  }),
26699
- [TypeId40]: TypeId40,
26733
+ [TypeId41]: TypeId41,
26700
26734
  toJSON() {
26701
26735
  return {
26702
26736
  _id: "Config"
26703
26737
  };
26704
26738
  }
26705
26739
  };
26706
- function make32(evaluator) {
26740
+ function make33(evaluator) {
26707
26741
  const self = Object.create(Proto13);
26708
26742
  self.evaluator = evaluator;
26709
26743
  self.parse = (provider) => flatMapEager2(evaluator(provider, []), fromResult2);
@@ -26711,10 +26745,10 @@ function make32(evaluator) {
26711
26745
  }
26712
26746
  var evaluateAt = (self, provider, pathPrefix) => self.evaluator(provider, pathPrefix);
26713
26747
  var map11 = /* @__PURE__ */ dual(2, (self, f) => {
26714
- return make32((provider, pathPrefix) => map8(evaluateAt(self, provider, pathPrefix), map2(f)));
26748
+ return make33((provider, pathPrefix) => map8(evaluateAt(self, provider, pathPrefix), map2(f)));
26715
26749
  });
26716
26750
  var withDefault3 = /* @__PURE__ */ dual(2, (self, defaultValue) => {
26717
- return make32((provider, pathPrefix) => mapEager2(evaluateAt(self, provider, pathPrefix), (resolution) => isFailure2(resolution) ? succeed2(defaultValue) : resolution));
26751
+ return make33((provider, pathPrefix) => mapEager2(evaluateAt(self, provider, pathPrefix), (resolution) => isFailure2(resolution) ? succeed2(defaultValue) : resolution));
26718
26752
  });
26719
26753
  var option3 = (self) => self.pipe(map11(some2), withDefault3(none2()));
26720
26754
  var isSourceError = (u) => isTagged(u, "SourceError");
@@ -26833,7 +26867,7 @@ function schema2(codec, path) {
26833
26867
  const encodedAst = toEncoded(codecStringTree.ast);
26834
26868
  const decodeCursor = decodeUnknownEffect(make12(toConfigCursorAST(codecStringTree.ast)));
26835
26869
  const localPath = typeof path === "string" ? [path] : path ?? [];
26836
- return make32((provider, pathPrefix) => {
26870
+ return make33((provider, pathPrefix) => {
26837
26871
  const fullPath = [...pathPrefix, ...localPath];
26838
26872
  return loadCursor(provider, fullPath).pipe(flatMapEager2((cursor) => decodeCursor(cursor).pipe(mapEager2(succeed2), catchEager2((issue) => {
26839
26873
  const error = new ConfigError(new SchemaError(fullPath.length > 0 ? new Pointer(fullPath, issue) : issue));
@@ -26879,7 +26913,7 @@ var detectStreamBodySupport = () => {
26879
26913
  return false;
26880
26914
  }
26881
26915
  };
26882
- var fetch = /* @__PURE__ */ make28((request, url, signal, fiber) => {
26916
+ var fetch = /* @__PURE__ */ make29((request, url, signal, fiber) => {
26883
26917
  if (request.headers.upgrade !== undefined) {
26884
26918
  return fail7(new HttpClientError({
26885
26919
  reason: new TransportError({
@@ -27057,7 +27091,7 @@ var spanAttributes = (tag, attributes) => ({
27057
27091
  });
27058
27092
 
27059
27093
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/rpc/RpcClientError.js
27060
- var TypeId41 = "~effect/rpc/RpcClientError";
27094
+ var TypeId42 = "~effect/rpc/RpcClientError";
27061
27095
 
27062
27096
  class RpcClientDefect extends (/* @__PURE__ */ Error4("effect/rpc/RpcClientError/RpcClientDefect")({
27063
27097
  _tag: /* @__PURE__ */ tag("RpcClientDefect"),
@@ -27066,11 +27100,11 @@ class RpcClientDefect extends (/* @__PURE__ */ Error4("effect/rpc/RpcClientError
27066
27100
  })) {
27067
27101
  }
27068
27102
 
27069
- class RpcClientError extends (/* @__PURE__ */ Error4(TypeId41)({
27103
+ class RpcClientError extends (/* @__PURE__ */ Error4(TypeId42)({
27070
27104
  _tag: /* @__PURE__ */ tag("RpcClientError"),
27071
27105
  reason: /* @__PURE__ */ Union2([WorkerErrorReason, SocketErrorReason, HttpClientErrorSchema, RpcClientDefect])
27072
27106
  })) {
27073
- [TypeId41] = TypeId41;
27107
+ [TypeId42] = TypeId42;
27074
27108
  get message() {
27075
27109
  return `${this.reason._tag}: ${this.reason.message}`;
27076
27110
  }
@@ -27402,7 +27436,7 @@ var makeNoSerialization = /* @__PURE__ */ fnUntraced2(function* (group, options)
27402
27436
  };
27403
27437
  });
27404
27438
  var clientIdCounter = 0;
27405
- var make33 = /* @__PURE__ */ fnUntraced2(function* (group, options) {
27439
+ var make34 = /* @__PURE__ */ fnUntraced2(function* (group, options) {
27406
27440
  const clientId = clientIdCounter++;
27407
27441
  const {
27408
27442
  codecFor,
@@ -27748,7 +27782,7 @@ var layerProtocolSocket = (options) => effect(Protocol)(makeProtocolSocket(optio
27748
27782
  class ConnectionHooks extends (/* @__PURE__ */ Service()("effect/rpc/RpcClient/ConnectionHooks")) {
27749
27783
  }
27750
27784
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/rpc/RpcMiddleware.js
27751
- var TypeId42 = "~effect/rpc/RpcMiddleware";
27785
+ var TypeId43 = "~effect/rpc/RpcMiddleware";
27752
27786
  var Service2 = () => (id, options) => {
27753
27787
  const limit = getStackTraceLimit();
27754
27788
  let creationError;
@@ -27766,16 +27800,16 @@ var Service2 = () => (id, options) => {
27766
27800
  return creationError?.stack;
27767
27801
  }
27768
27802
  });
27769
- ServiceClass_[TypeId42] = TypeId42;
27803
+ ServiceClass_[TypeId43] = TypeId43;
27770
27804
  ServiceClass_.error = options?.error ?? Never2;
27771
27805
  ServiceClass_.requiredForClient = options?.requiredForClient ?? false;
27772
27806
  return ServiceClass;
27773
27807
  };
27774
27808
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Stdio.js
27775
- var TypeId43 = "~effect/Stdio";
27776
- var Stdio = /* @__PURE__ */ Service(TypeId43);
27777
- var make34 = (options) => ({
27778
- [TypeId43]: TypeId43,
27809
+ var TypeId44 = "~effect/Stdio";
27810
+ var Stdio = /* @__PURE__ */ Service(TypeId44);
27811
+ var make35 = (options) => ({
27812
+ [TypeId44]: TypeId44,
27779
27813
  stdinIsTerminal: succeed7(false),
27780
27814
  stdoutIsTerminal: succeed7(false),
27781
27815
  stderrIsTerminal: succeed7(false),
@@ -27859,96 +27893,96 @@ var ProgramOutcome = Union2([
27859
27893
  Struct({ status: Literal2("failed"), failureSummary: String5 })
27860
27894
  ]);
27861
27895
 
27862
- class RunnerReplicaRpcs extends make30(make29("Claim", {
27896
+ class RunnerReplicaRpcs extends make31(make30("Claim", {
27863
27897
  payload: WorkUnitClaimInput,
27864
27898
  success: WorkUnitClaimResult,
27865
27899
  error: RunnerRpcError
27866
- }), make29("Heartbeat", {
27900
+ }), make30("Heartbeat", {
27867
27901
  payload: WorkUnitHeartbeatInput,
27868
27902
  success: WorkUnitHeartbeatResult,
27869
27903
  error: RunnerRpcError
27870
- }), make29("Complete", {
27904
+ }), make30("Complete", {
27871
27905
  payload: WorkUnitCompletion,
27872
27906
  error: RunnerRpcError
27873
- }), make29("Release", {
27907
+ }), make30("Release", {
27874
27908
  payload: WorkUnitReleaseInput,
27875
27909
  error: RunnerRpcError
27876
- }), make29("Signals", {
27910
+ }), make30("Signals", {
27877
27911
  payload: { runnerReplicaId: String5 },
27878
27912
  success: RunnerSignal,
27879
27913
  error: RunnerRpcError,
27880
27914
  stream: true
27881
- }), make29("ReportSteer", {
27915
+ }), make30("ReportSteer", {
27882
27916
  payload: { workUnitId: String5, messageId: String5, delivered: Boolean3 },
27883
27917
  success: Void2,
27884
27918
  error: RunnerRpcError
27885
- }), make29("AppendTranscript", {
27919
+ }), make30("AppendTranscript", {
27886
27920
  payload: { workUnitId: String5, entries: ArraySchema(TranscriptAppendEntry).check(isMaxLength(100)) },
27887
27921
  success: Void2,
27888
27922
  error: RunnerRpcError
27889
- }), make29("CreateCheckpointFile", {
27923
+ }), make30("CreateCheckpointFile", {
27890
27924
  payload: { lease: ProgramLease, byteSize: Int, sha256: String5 },
27891
27925
  success: Struct({ file: RunFileRecord, upload: optional2(RunFileUpload) }),
27892
27926
  error: Union2([RunnerRpcError, RunFileRefused])
27893
- }), make29("CheckpointFileParts", {
27927
+ }), make30("CheckpointFileParts", {
27894
27928
  payload: { lease: ProgramLease, fileId: String5, partNumbers: ArraySchema(Int) },
27895
27929
  success: Struct({ parts: ArraySchema(RunFilePartUrl) }),
27896
27930
  error: RunnerRpcError
27897
- }), make29("CompleteCheckpointFile", {
27931
+ }), make30("CompleteCheckpointFile", {
27898
27932
  payload: { lease: ProgramLease, fileId: String5, parts: optional2(ArraySchema(UploadedRunFilePart)) },
27899
27933
  success: RunFileRecord,
27900
27934
  error: RunnerRpcError
27901
- }), make29("SaveCheckpoint", {
27935
+ }), make30("SaveCheckpoint", {
27902
27936
  payload: { lease: ProgramLease, checkpoint: StepCheckpoint },
27903
27937
  success: Void2,
27904
27938
  error: RunnerRpcError
27905
- }), make29("ResumeCheckpoint", {
27939
+ }), make30("ResumeCheckpoint", {
27906
27940
  payload: { lease: ProgramLease },
27907
27941
  success: UndefinedOr(ResumedCheckpoint),
27908
27942
  error: RunnerRpcError
27909
- }), make29("SettledCheckpoints", {
27943
+ }), make30("SettledCheckpoints", {
27910
27944
  success: ArraySchema(Struct({
27911
27945
  stepAttemptId: String5,
27912
27946
  ref: optionalKey2(String5),
27913
27947
  repoBinding: optionalKey2(WorkUnitRepoBinding)
27914
27948
  })),
27915
27949
  error: RunnerRpcError
27916
- }), make29("ForgetCheckpoints", {
27950
+ }), make30("ForgetCheckpoints", {
27917
27951
  payload: { stepAttemptIds: ArraySchema(String5) },
27918
27952
  success: Void2,
27919
27953
  error: RunnerRpcError
27920
- }), make29("GitCredential", {
27954
+ }), make30("GitCredential", {
27921
27955
  payload: { repoBindingId: String5 },
27922
27956
  success: UndefinedOr(Struct({ username: String5, password: String5 })),
27923
27957
  error: RunnerRpcError
27924
- }), make29("Bundle", {
27958
+ }), make30("Bundle", {
27925
27959
  payload: { digest: String5 },
27926
27960
  success: Struct({ bundle: String5 }),
27927
27961
  error: RunnerRpcError
27928
- }), make29("SettledRuns", {
27962
+ }), make30("SettledRuns", {
27929
27963
  payload: { runIds: ArraySchema(String5) },
27930
27964
  success: ArraySchema(String5),
27931
27965
  error: RunnerRpcError
27932
- }), make29("KnownEvidence", {
27966
+ }), make30("KnownEvidence", {
27933
27967
  payload: { lease: ProgramLease, trees: ArraySchema(String5) },
27934
27968
  success: ArraySchema(Struct({ tree: String5, name: String5, command: String5 })),
27935
27969
  error: RunnerRpcError
27936
27970
  })).middleware(RunnerAuthentication) {
27937
27971
  }
27938
27972
 
27939
- class RunnerJournalRpcs extends make30(make29("RecordActivity", {
27973
+ class RunnerJournalRpcs extends make31(make30("RecordActivity", {
27940
27974
  payload: { lease: ProgramLease, name: String5, attempt: Int, exit: Json2 },
27941
27975
  error: RunnerRpcError
27942
- }), make29("DeferredDone", {
27976
+ }), make30("DeferredDone", {
27943
27977
  payload: { lease: ProgramLease, name: String5, exit: Json2 },
27944
27978
  error: RunnerRpcError
27945
- }), make29("ScheduleClock", {
27979
+ }), make30("ScheduleClock", {
27946
27980
  payload: { lease: ProgramLease, name: String5, deferredName: String5, durationMillis: Int },
27947
27981
  error: RunnerRpcError
27948
- }), make29("Suspend", { payload: { lease: ProgramLease }, error: RunnerRpcError }), make29("FinishProgram", { payload: { lease: ProgramLease, outcome: ProgramOutcome }, error: RunnerRpcError })).middleware(RunnerAuthentication) {
27982
+ }), make30("Suspend", { payload: { lease: ProgramLease }, error: RunnerRpcError }), make30("FinishProgram", { payload: { lease: ProgramLease, outcome: ProgramOutcome }, error: RunnerRpcError })).middleware(RunnerAuthentication) {
27949
27983
  }
27950
27984
 
27951
- class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
27985
+ class RunnerCapabilityRpcs extends make31(make30("PutQuestion", {
27952
27986
  payload: {
27953
27987
  lease: ProgramLease,
27954
27988
  step: String5,
@@ -27968,7 +28002,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
27968
28002
  },
27969
28003
  success: Struct({ questionId: String5 }),
27970
28004
  error: RunnerRpcError
27971
- }), make29("StartAgentStep", {
28005
+ }), make30("StartAgentStep", {
27972
28006
  payload: {
27973
28007
  lease: ProgramLease,
27974
28008
  step: String5,
@@ -27984,7 +28018,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
27984
28018
  },
27985
28019
  success: Struct({ stepAttemptId: String5 }),
27986
28020
  error: RunnerRpcError
27987
- }), make29("StartVerification", {
28021
+ }), make30("StartVerification", {
27988
28022
  payload: {
27989
28023
  lease: ProgramLease,
27990
28024
  step: String5,
@@ -28004,7 +28038,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28004
28038
  },
28005
28039
  success: Struct({ verificationId: String5 }),
28006
28040
  error: RunnerRpcError
28007
- }), make29("AwaitEvent", {
28041
+ }), make30("AwaitEvent", {
28008
28042
  payload: {
28009
28043
  lease: ProgramLease,
28010
28044
  step: String5,
@@ -28020,7 +28054,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28020
28054
  })))
28021
28055
  },
28022
28056
  error: RunnerRpcError
28023
- }), make29("ClaimResource", {
28057
+ }), make30("ClaimResource", {
28024
28058
  payload: {
28025
28059
  lease: ProgramLease,
28026
28060
  step: String5,
@@ -28029,7 +28063,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28029
28063
  action: Literals(["claim", "take_over", "let_go"])
28030
28064
  },
28031
28065
  error: RunnerRpcError
28032
- }), make29("AdmitChild", {
28066
+ }), make30("AdmitChild", {
28033
28067
  payload: {
28034
28068
  lease: ProgramLease,
28035
28069
  step: String5,
@@ -28040,7 +28074,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28040
28074
  },
28041
28075
  success: Struct({ runId: String5 }),
28042
28076
  error: RunnerRpcError
28043
- }), make29("StoreArtifact", {
28077
+ }), make30("StoreArtifact", {
28044
28078
  payload: {
28045
28079
  lease: ProgramLease,
28046
28080
  step: String5,
@@ -28052,7 +28086,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28052
28086
  },
28053
28087
  success: Struct({ artifactId: String5 }),
28054
28088
  error: RunnerRpcError
28055
- }), make29("RecordNote", {
28089
+ }), make30("RecordNote", {
28056
28090
  payload: {
28057
28091
  lease: ProgramLease,
28058
28092
  step: String5,
@@ -28061,10 +28095,11 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28061
28095
  kind: optional2(Literals(["note", "blocker"]))
28062
28096
  },
28063
28097
  error: RunnerRpcError
28064
- }), make29("PerformHostEffect", {
28098
+ }), make30("PerformHostEffect", {
28065
28099
  payload: {
28066
28100
  lease: ProgramLease,
28067
28101
  step: String5,
28102
+ waitsWhenUnconfirmed: optionalKey2(Boolean3),
28068
28103
  effect: Union2([
28069
28104
  Struct({
28070
28105
  kind: Literal2("post_comment"),
@@ -28089,7 +28124,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28089
28124
  },
28090
28125
  success: UndefinedOr(Struct({ id: String5, number: String5, url: String5 })),
28091
28126
  error: RunnerRpcError
28092
- }), make29("AlertTask", {
28127
+ }), make30("AlertTask", {
28093
28128
  payload: {
28094
28129
  lease: ProgramLease,
28095
28130
  step: String5,
@@ -28106,7 +28141,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28106
28141
  joined: optionalKey2(Struct({ kind: Literals(["run", "recent"]), runId: String5 }))
28107
28142
  }),
28108
28143
  error: RunnerRpcError
28109
- }), make29("ReadTranscripts", {
28144
+ }), make30("ReadTranscripts", {
28110
28145
  payload: {
28111
28146
  lease: ProgramLease,
28112
28147
  step: String5,
@@ -28141,7 +28176,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28141
28176
  })))
28142
28177
  }),
28143
28178
  error: RunnerRpcError
28144
- }), make29("PipelineStatus", {
28179
+ }), make30("PipelineStatus", {
28145
28180
  payload: { lease: ProgramLease, step: String5, changeRequestId: String5 },
28146
28181
  success: Struct({
28147
28182
  head: String5,
@@ -28174,11 +28209,11 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28174
28209
  }))
28175
28210
  }),
28176
28211
  error: RunnerRpcError
28177
- }), make29("ReportPipeline", {
28212
+ }), make30("ReportPipeline", {
28178
28213
  payload: { lease: ProgramLease, step: String5, changeRequestId: String5, verification: String5 },
28179
28214
  success: Struct({ head: String5, status: Literals(["success", "failed"]) }),
28180
28215
  error: RunnerRpcError
28181
- }), make29("ReviewThreads", {
28216
+ }), make30("ReviewThreads", {
28182
28217
  payload: { lease: ProgramLease, step: String5, changeRequestId: String5 },
28183
28218
  success: Struct({
28184
28219
  threads: ArraySchema(Struct({
@@ -28190,7 +28225,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28190
28225
  }))
28191
28226
  }),
28192
28227
  error: RunnerRpcError
28193
- }), make29("OpenChangeRequests", {
28228
+ }), make30("OpenChangeRequests", {
28194
28229
  payload: { lease: ProgramLease, step: String5, authors: NonEmptyArray(String5) },
28195
28230
  success: Struct({
28196
28231
  changeRequests: ArraySchema(Struct({
@@ -28204,7 +28239,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28204
28239
  }))
28205
28240
  }),
28206
28241
  error: RunnerRpcError
28207
- }), make29("OwnChangeRequests", {
28242
+ }), make30("OwnChangeRequests", {
28208
28243
  payload: { lease: ProgramLease, step: String5 },
28209
28244
  success: Struct({
28210
28245
  changeRequests: ArraySchema(Struct({
@@ -28217,7 +28252,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28217
28252
  }))
28218
28253
  }),
28219
28254
  error: RunnerRpcError
28220
- }), make29("Propose", {
28255
+ }), make30("Propose", {
28221
28256
  payload: {
28222
28257
  lease: ProgramLease,
28223
28258
  step: String5,
@@ -28246,7 +28281,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28246
28281
  task: optionalKey2(Struct({ id: String5, active: Boolean3 }))
28247
28282
  }),
28248
28283
  error: RunnerRpcError
28249
- }), make29("ReadProject", {
28284
+ }), make30("ReadProject", {
28250
28285
  payload: { lease: ProgramLease, step: String5, projectId: String5 },
28251
28286
  success: Struct({
28252
28287
  project: Struct({ id: String5, name: String5 }),
@@ -28269,7 +28304,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28269
28304
  taskChanges: ArraySchema(Struct({ taskKey: String5, title: String5, change: String5, at: String5 }))
28270
28305
  }),
28271
28306
  error: RunnerRpcError
28272
- }), make29("DraftUpdate", {
28307
+ }), make30("DraftUpdate", {
28273
28308
  payload: {
28274
28309
  lease: ProgramLease,
28275
28310
  step: String5,
@@ -28284,7 +28319,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28284
28319
  },
28285
28320
  success: Struct({ id: String5 }),
28286
28321
  error: RunnerRpcError
28287
- }), make29("CreatePlanTasks", {
28322
+ }), make30("CreatePlanTasks", {
28288
28323
  payload: {
28289
28324
  lease: ProgramLease,
28290
28325
  projectId: optionalKey2(String5),
@@ -28299,18 +28334,19 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28299
28334
  },
28300
28335
  success: ArraySchema(Struct({ key: String5, taskId: String5 })),
28301
28336
  error: RunnerRpcError
28302
- }), make29("IntegrationBranch", {
28337
+ }), make30("IntegrationBranch", {
28303
28338
  payload: { lease: ProgramLease, repoBindingId: optionalKey2(String5) },
28304
28339
  success: Struct({ repoBindingId: String5, branch: String5, revision: String5 }),
28305
28340
  error: RunnerRpcError
28306
- }), make29("DeliveryBase", {
28341
+ }), make30("DeliveryBase", {
28307
28342
  payload: { lease: ProgramLease },
28308
28343
  success: Struct({ repoBindingId: String5, branch: String5, revision: String5 }),
28309
28344
  error: RunnerRpcError
28310
- }), make29("MergeChangeRequest", {
28345
+ }), make30("MergeChangeRequest", {
28311
28346
  payload: {
28312
28347
  lease: ProgramLease,
28313
28348
  step: String5,
28349
+ waitsWhenUnconfirmed: optionalKey2(Boolean3),
28314
28350
  changeRequestId: String5,
28315
28351
  head: optionalKey2(String5),
28316
28352
  rebase: optionalKey2(Boolean3)
@@ -28324,7 +28360,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28324
28360
  Struct({ status: Literal2("moved"), head: String5 })
28325
28361
  ]),
28326
28362
  error: RunnerRpcError
28327
- }), make29("ApproveChangeRequest", {
28363
+ }), make30("ApproveChangeRequest", {
28328
28364
  payload: {
28329
28365
  lease: ProgramLease,
28330
28366
  step: String5,
@@ -28339,7 +28375,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28339
28375
  Struct({ approved: Literal2(false), reason: String5 })
28340
28376
  ]),
28341
28377
  error: RunnerRpcError
28342
- }), make29("CloseChangeRequest", {
28378
+ }), make30("CloseChangeRequest", {
28343
28379
  payload: {
28344
28380
  lease: ProgramLease,
28345
28381
  step: String5,
@@ -28349,7 +28385,7 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28349
28385
  },
28350
28386
  success: Struct({ closed: Boolean3, head: optionalKey2(String5) }),
28351
28387
  error: RunnerRpcError
28352
- }), make29("RerunPipeline", {
28388
+ }), make30("RerunPipeline", {
28353
28389
  payload: {
28354
28390
  lease: ProgramLease,
28355
28391
  step: String5,
@@ -28359,10 +28395,11 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28359
28395
  },
28360
28396
  success: Struct({ head: String5, pipelines: Int }),
28361
28397
  error: RunnerRpcError
28362
- }), make29("PublishRelease", {
28398
+ }), make30("PublishRelease", {
28363
28399
  payload: {
28364
28400
  lease: ProgramLease,
28365
28401
  step: String5,
28402
+ waitsWhenUnconfirmed: optionalKey2(Boolean3),
28366
28403
  tag: String5,
28367
28404
  revision: optionalKey2(String5),
28368
28405
  title: String5,
@@ -28370,14 +28407,14 @@ class RunnerCapabilityRpcs extends make30(make29("PutQuestion", {
28370
28407
  },
28371
28408
  success: Struct({ tag: String5, revision: String5, url: String5 }),
28372
28409
  error: RunnerRpcError
28373
- }), make29("ProgramSecrets", {
28410
+ }), make30("ProgramSecrets", {
28374
28411
  payload: { lease: ProgramLease },
28375
28412
  success: Record(String5, String5),
28376
28413
  error: RunnerRpcError
28377
28414
  })).middleware(RunnerAuthentication) {
28378
28415
  }
28379
28416
 
28380
- class RunnerRunFileRpcs extends make30(make29("CreateRunFile", {
28417
+ class RunnerRunFileRpcs extends make31(make30("CreateRunFile", {
28381
28418
  payload: {
28382
28419
  lease: ProgramLease,
28383
28420
  step: String5,
@@ -28389,11 +28426,11 @@ class RunnerRunFileRpcs extends make30(make29("CreateRunFile", {
28389
28426
  },
28390
28427
  success: Struct({ file: RunFileRecord, upload: optional2(RunFileUpload) }),
28391
28428
  error: Union2([RunnerRpcError, RunFileRefused])
28392
- }), make29("RunFileParts", {
28429
+ }), make30("RunFileParts", {
28393
28430
  payload: { lease: ProgramLease, fileId: String5, partNumbers: ArraySchema(Int) },
28394
28431
  success: Struct({ parts: ArraySchema(RunFilePartUrl) }),
28395
28432
  error: RunnerRpcError
28396
- }), make29("CompleteRunFile", {
28433
+ }), make30("CompleteRunFile", {
28397
28434
  payload: { lease: ProgramLease, fileId: String5, parts: optional2(ArraySchema(UploadedRunFilePart)) },
28398
28435
  success: RunFileRecord,
28399
28436
  error: RunnerRpcError
@@ -28502,6 +28539,7 @@ var isRunnerRpcError = is2(RunnerRpcError);
28502
28539
  var isRunFileRefused = is2(RunFileRefused);
28503
28540
  var issues = makeFormatterStandardSchemaV1();
28504
28541
  var refusedFields = (issue) => [...new Set(issues(issue).issues.map(({ path }) => (path ?? []).map(String).join(".")))].join(", ");
28542
+ var unconfirmedEffect = (cause) => ("code" in cause) && cause.code === effectUnconfirmed;
28505
28543
  var refusedStep = (cause) => {
28506
28544
  if (isRunFileRefused(cause))
28507
28545
  return true;
@@ -28509,14 +28547,47 @@ var refusedStep = (cause) => {
28509
28547
  return true;
28510
28548
  return isRunnerRpcError(cause) && cause.status >= 400 && cause.status < 500 && !replayStatuses.has(cause.status);
28511
28549
  };
28512
- var requested = (step, request) => request.pipe(catch_2((cause) => refusedStep(cause) ? fail7(new StepFailed({
28513
- step,
28514
- reason: cause.message,
28515
- ...isRunnerRpcError(cause) ? { code: cause.code } : undefined
28516
- })) : die4(new JournalWriteFailed({ cause }))), catchDefect2((defect) => defect instanceof Error && isIssue(defect.cause) ? fail7(new StepFailed({
28517
- step,
28518
- reason: `Kitman cannot take this Step's request: invalid ${refusedFields(defect.cause)}`
28519
- })) : die4(defect)));
28550
+ var unconfirmedWaits = [1, 2, 4, 8, 15, 30, 30, 30, 30, 30];
28551
+ var unconfirmedClocks = (step) => unconfirmedWaits.map((minutes, wait) => make16({ name: `${step}/unconfirmed/${wait + 1}`, duration: `${minutes} minutes` }));
28552
+ var unconfirmedWaiting = (step) => gen2(function* () {
28553
+ const engine = yield* serviceOption2(WorkflowEngine);
28554
+ const instance = yield* serviceOption2(WorkflowInstance);
28555
+ if (isNone2(engine) || isNone2(instance))
28556
+ return {
28557
+ over: 0,
28558
+ wait: () => die4(new Error(`Step "${step}" asked Kitman outside its Activity`))
28559
+ };
28560
+ const inWorkflow = (effect) => effect.pipe(provideService2(WorkflowEngine, engine.value), provideService2(WorkflowInstance, instance.value));
28561
+ const clocks = unconfirmedClocks(step);
28562
+ let over = 0;
28563
+ for (const clock of clocks) {
28564
+ if (isNone2(yield* inWorkflow(engine.value.deferredResult(clock.deferred))))
28565
+ break;
28566
+ over++;
28567
+ }
28568
+ return {
28569
+ over,
28570
+ wait: (wait) => {
28571
+ const clock = clocks[wait];
28572
+ return clock === undefined ? undefined : inWorkflow(sleep3({ name: clock.name, duration: clock.duration, inMemoryThreshold: 0 }));
28573
+ }
28574
+ };
28575
+ });
28576
+ var requested = (step, request) => {
28577
+ const ask = (waiting, wait) => request.pipe(catch_2((cause) => unconfirmedEffect(cause) ? askAfterWait(waiting, wait, cause) : refusedStep(cause) ? fail7(new StepFailed({
28578
+ step,
28579
+ reason: cause.message,
28580
+ ...isRunnerRpcError(cause) ? { code: cause.code } : undefined
28581
+ })) : die4(new JournalWriteFailed({ cause }))));
28582
+ const askAfterWait = (waiting, wait, cause) => {
28583
+ const waited = waiting.wait(wait);
28584
+ return waited === undefined ? fail7(new StepFailed({ step, reason: cause.message, code: effectUnconfirmed })) : andThen2(waited, suspend2(() => ask(waiting, wait + 1)));
28585
+ };
28586
+ return flatMap3(unconfirmedWaiting(step), (waiting) => ask(waiting, waiting.over)).pipe(catchDefect2((defect) => defect instanceof Error && isIssue(defect.cause) ? fail7(new StepFailed({
28587
+ step,
28588
+ reason: `Kitman cannot take this Step's request: invalid ${refusedFields(defect.cause)}`
28589
+ })) : die4(defect)));
28590
+ };
28520
28591
  var runnerHost = (capabilities) => ({
28521
28592
  putQuestion: (launch) => requested(launch.step, capabilities.putQuestion({
28522
28593
  step: launch.step,
@@ -28782,7 +28853,7 @@ var rpcProgramPorts = (rpc, work) => {
28782
28853
  storeArtifact: ({ fileIds, ...artifact }) => rpc.storeArtifact({ lease, ...artifact, ...fileIds === undefined ? undefined : { fileIds: [...fileIds] } }),
28783
28854
  ...rpcRunFiles(rpc, lease),
28784
28855
  recordNote: (note) => rpc.recordNote({ lease, ...note }),
28785
- performHostEffect: (request) => rpc.performHostEffect({ lease, ...request }),
28856
+ performHostEffect: (request) => rpc.performHostEffect({ lease, ...request, waitsWhenUnconfirmed: true }),
28786
28857
  createPlanTasks: (tickets, projectId) => rpc.createPlanTasks({
28787
28858
  lease,
28788
28859
  ...projectId === undefined ? undefined : { projectId },
@@ -28826,11 +28897,11 @@ var rpcProgramPorts = (rpc, work) => {
28826
28897
  ...writtenFrom.since === undefined ? undefined : { since: writtenFrom.since }
28827
28898
  }
28828
28899
  }),
28829
- mergeChangeRequest: (request) => rpc.mergeChangeRequest({ lease, ...request }),
28900
+ mergeChangeRequest: (request) => rpc.mergeChangeRequest({ lease, ...request, waitsWhenUnconfirmed: true }),
28830
28901
  closeChangeRequest: (request) => rpc.closeChangeRequest({ lease, ...request }),
28831
28902
  approveChangeRequest: (request) => rpc.approveChangeRequest({ lease, ...request }),
28832
28903
  rerunPipeline: (request) => rpc.rerunPipeline({ lease, ...request }),
28833
- publishRelease: (request) => rpc.publishRelease({ lease, ...request })
28904
+ publishRelease: (request) => rpc.publishRelease({ lease, ...request, waitsWhenUnconfirmed: true })
28834
28905
  };
28835
28906
  return { journal, capabilities };
28836
28907
  };
@@ -28853,7 +28924,7 @@ var authorizer = (options) => (call) => flatMap3(options.bearer, (token) => with
28853
28924
  var RunnerProcessRpcs = RunnerReplicaRpcs.merge(RunnerRunFileRpcs);
28854
28925
  var makeProgramRpcClient = (options) => gen2(function* () {
28855
28926
  const protocol = yield* build(options.protocol);
28856
- const client = yield* make33(ProgramRpcs).pipe(provideContext2(protocol));
28927
+ const client = yield* make34(ProgramRpcs).pipe(provideContext2(protocol));
28857
28928
  const authorized = authorizer(options);
28858
28929
  return {
28859
28930
  recordActivity: (input) => authorized(client.RecordActivity(input)),
@@ -28998,7 +29069,7 @@ var HandleProto = {
28998
29069
  var makeHandle = (params) => Object.setPrototypeOf({
28999
29070
  ...params
29000
29071
  }, HandleProto);
29001
- var make35 = (spawn) => {
29072
+ var make36 = (spawn) => {
29002
29073
  const streamString = (command, options) => spawn(command).pipe(map8((handle) => decodeText2(options?.includeStderr === true ? handle.all : drainFork(handle.stdout, handle.stderr))), unwrap4);
29003
29074
  const streamLines = (command, options) => splitLines2(streamString(command, options));
29004
29075
  return ChildProcessSpawner.of({
@@ -29209,7 +29280,7 @@ var parseTemplate = (texts, values) => {
29209
29280
  };
29210
29281
 
29211
29282
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/process/ChildProcess.js
29212
- var TypeId44 = "~effect/process/ChildProcess";
29283
+ var TypeId45 = "~effect/process/ChildProcess";
29213
29284
  var Proto14 = {
29214
29285
  .../* @__PURE__ */ Prototype2({
29215
29286
  label: "Command",
@@ -29217,7 +29288,7 @@ var Proto14 = {
29217
29288
  return getUnsafe(fiber.context, ChildProcessSpawner).spawn(this);
29218
29289
  }
29219
29290
  }),
29220
- [TypeId44]: TypeId44
29291
+ [TypeId45]: TypeId45
29221
29292
  };
29222
29293
  var makeStandardCommand = (command, args, options) => Object.assign(Object.create(Proto14), {
29223
29294
  _tag: "StandardCommand",
@@ -29225,7 +29296,7 @@ var makeStandardCommand = (command, args, options) => Object.assign(Object.creat
29225
29296
  args,
29226
29297
  options
29227
29298
  });
29228
- var make36 = function make(...args) {
29299
+ var make37 = function make(...args) {
29229
29300
  if (isTemplateString(args[0])) {
29230
29301
  const [templates, ...expressions] = args;
29231
29302
  const [command, cmdArgs] = parseTemplate2(templates, expressions);
@@ -29492,7 +29563,7 @@ var readableToPullUnsafe = (options) => {
29492
29563
  const readable = options.readable;
29493
29564
  const chunkSize = options.chunkSize ?? 4096;
29494
29565
  const closeOnDone = options.closeOnDone ?? true;
29495
- const exit = options.exit ?? make16(undefined);
29566
+ const exit = options.exit ?? make17(undefined);
29496
29567
  const latch = options.latch ?? makeUnsafe4(false);
29497
29568
  function onReadable() {
29498
29569
  latch.openUnsafe();
@@ -29596,7 +29667,7 @@ var taskkill = (childProcess, onExit = () => {}) => {
29596
29667
  windowsHide: true
29597
29668
  }, onExit);
29598
29669
  };
29599
- var make37 = /* @__PURE__ */ gen2(function* () {
29670
+ var make38 = /* @__PURE__ */ gen2(function* () {
29600
29671
  const fs = yield* FileSystem;
29601
29672
  const path = yield* Path2;
29602
29673
  const resolveWorkingDirectory = fnUntraced2(function* (options) {
@@ -30056,7 +30127,7 @@ var make37 = /* @__PURE__ */ gen2(function* () {
30056
30127
  const sourceStream = unwrap4(succeed7(getSourceStream(handles[handles.length - 1], options.from)));
30057
30128
  const toOption = options.to ?? "stdin";
30058
30129
  if (toOption === "stdin") {
30059
- handles.push(yield* spawnCommand(make36(command.command, command.args, {
30130
+ handles.push(yield* spawnCommand(make37(command.command, command.args, {
30060
30131
  ...command.options,
30061
30132
  stdin: {
30062
30133
  ...stdinConfig,
@@ -30076,7 +30147,7 @@ var make37 = /* @__PURE__ */ gen2(function* () {
30076
30147
  type: "input",
30077
30148
  stream: sourceStream
30078
30149
  };
30079
- handles.push(yield* spawnCommand(make36(command.command, command.args, {
30150
+ handles.push(yield* spawnCommand(make37(command.command, command.args, {
30080
30151
  ...command.options,
30081
30152
  additionalFds: {
30082
30153
  ...existingFds,
@@ -30084,7 +30155,7 @@ var make37 = /* @__PURE__ */ gen2(function* () {
30084
30155
  }
30085
30156
  })));
30086
30157
  } else {
30087
- handles.push(yield* spawnCommand(make36(command.command, command.args, {
30158
+ handles.push(yield* spawnCommand(make37(command.command, command.args, {
30088
30159
  ...command.options,
30089
30160
  stdin: {
30090
30161
  ...stdinConfig,
@@ -30123,9 +30194,9 @@ var make37 = /* @__PURE__ */ gen2(function* () {
30123
30194
  }
30124
30195
  }
30125
30196
  });
30126
- return make35(spawnCommand);
30197
+ return make36(spawnCommand);
30127
30198
  });
30128
- var layer2 = /* @__PURE__ */ effect(ChildProcessSpawner, make37);
30199
+ var layer2 = /* @__PURE__ */ effect(ChildProcessSpawner, make38);
30129
30200
  var flattenCommand = (command) => {
30130
30201
  const commands = [];
30131
30202
  const pipeOptions = [];
@@ -30609,7 +30680,7 @@ var writeFile2 = (path, data, options) => callback2((resume, signal) => {
30609
30680
  resume(fail7(handleBadArgument("writeFile")(err)));
30610
30681
  }
30611
30682
  });
30612
- var makeFileSystem = /* @__PURE__ */ map8(/* @__PURE__ */ serviceOption2(WatchBackend), (backend) => make23({
30683
+ var makeFileSystem = /* @__PURE__ */ map8(/* @__PURE__ */ serviceOption2(WatchBackend), (backend) => make24({
30613
30684
  access: access2,
30614
30685
  chmod: chmod2,
30615
30686
  chown: chown2,
@@ -30669,15 +30740,15 @@ var fileUrlOps = (windows) => ({
30669
30740
  })
30670
30741
  })
30671
30742
  });
30672
- var layerPosix = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make27({
30743
+ var layerPosix = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make28({
30673
30744
  ...NodePath.posix,
30674
30745
  .../* @__PURE__ */ fileUrlOps(false)
30675
30746
  }));
30676
- var layerWin32 = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make27({
30747
+ var layerWin32 = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make28({
30677
30748
  ...NodePath.win32,
30678
30749
  .../* @__PURE__ */ fileUrlOps(true)
30679
30750
  }));
30680
- var layer5 = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make27({
30751
+ var layer5 = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make28({
30681
30752
  ...NodePath,
30682
30753
  .../* @__PURE__ */ fileUrlOps(undefined)
30683
30754
  }));
@@ -30686,7 +30757,7 @@ var layer5 = /* @__PURE__ */ succeed6(Path2)(/* @__PURE__ */ make27({
30686
30757
  var layer6 = layer5;
30687
30758
 
30688
30759
  // ../../node_modules/.bun/@effect+platform-node-shared@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-node-shared/dist/NodeStdio.js
30689
- var layer7 = /* @__PURE__ */ succeed6(Stdio, /* @__PURE__ */ make34({
30760
+ var layer7 = /* @__PURE__ */ succeed6(Stdio, /* @__PURE__ */ make35({
30690
30761
  args: /* @__PURE__ */ sync2(() => process.argv.slice(2)),
30691
30762
  stdinIsTerminal: /* @__PURE__ */ sync2(() => process.stdin.isTTY === true),
30692
30763
  stdoutIsTerminal: /* @__PURE__ */ sync2(() => process.stdout.isTTY === true),
@@ -30727,7 +30798,7 @@ var layer7 = /* @__PURE__ */ succeed6(Stdio, /* @__PURE__ */ make34({
30727
30798
  var layer8 = layer7;
30728
30799
 
30729
30800
  // ../../node_modules/.bun/effect@4.1.2/node_modules/effect/dist/Terminal.js
30730
- var TypeId45 = "~effect/Terminal";
30801
+ var TypeId46 = "~effect/Terminal";
30731
30802
  var QuitErrorTypeId = "~effect/Terminal/QuitError";
30732
30803
 
30733
30804
  class QuitError extends (/* @__PURE__ */ Error4("QuitError")({
@@ -30736,17 +30807,17 @@ class QuitError extends (/* @__PURE__ */ Error4("QuitError")({
30736
30807
  [QuitErrorTypeId] = QuitErrorTypeId;
30737
30808
  }
30738
30809
  var Terminal = /* @__PURE__ */ Service("effect/Terminal");
30739
- var make38 = (impl) => Terminal.of({
30810
+ var make39 = (impl) => Terminal.of({
30740
30811
  ...impl,
30741
- [TypeId45]: TypeId45
30812
+ [TypeId46]: TypeId46
30742
30813
  });
30743
30814
 
30744
30815
  // ../../node_modules/.bun/@effect+platform-node-shared@4.1.2+edf248c88a527e3e/node_modules/@effect/platform-node-shared/dist/NodeTerminal.js
30745
30816
  import * as readline from "readline";
30746
- var make39 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQuit) {
30817
+ var make40 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQuit) {
30747
30818
  const stdin = process.stdin;
30748
30819
  const stdout = process.stdout;
30749
- const lines = yield* make18();
30820
+ const lines = yield* make19();
30750
30821
  let inputEnded = stdin.readableEnded;
30751
30822
  let readlineActive = false;
30752
30823
  const onStdinEnd = () => {
@@ -30757,7 +30828,7 @@ var make39 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQu
30757
30828
  };
30758
30829
  stdin.once("end", onStdinEnd);
30759
30830
  yield* addFinalizer3(() => sync2(() => stdin.off("end", onStdinEnd)));
30760
- const rlRef = yield* make20({
30831
+ const rlRef = yield* make21({
30761
30832
  acquire: acquireRelease2(sync2(() => {
30762
30833
  const rl = readline.createInterface({
30763
30834
  input: stdin,
@@ -30796,7 +30867,7 @@ var make39 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQu
30796
30867
  if (stdin.isTTY)
30797
30868
  stdin.setRawMode(enabled);
30798
30869
  });
30799
- const rawModeRef = yield* make20({
30870
+ const rawModeRef = yield* make21({
30800
30871
  acquire: acquireRelease2(setRawMode(true), () => setRawMode(false)),
30801
30872
  idleTimeToLive: "10 millis"
30802
30873
  });
@@ -30817,7 +30888,7 @@ var make39 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQu
30817
30888
  return queue;
30818
30889
  });
30819
30890
  const readInput = gen2(function* () {
30820
- const queue = yield* make18();
30891
+ const queue = yield* make19();
30821
30892
  const handleKeypress = (s, k) => {
30822
30893
  const userInput = {
30823
30894
  input: fromUndefinedOr(s),
@@ -30865,7 +30936,7 @@ var make39 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQu
30865
30936
  cause: err
30866
30937
  }))));
30867
30938
  }));
30868
- return make38({
30939
+ return make39({
30869
30940
  columns,
30870
30941
  rows,
30871
30942
  size,
@@ -30874,7 +30945,7 @@ var make39 = /* @__PURE__ */ fnUntraced2(function* (shouldQuit = defaultShouldQu
30874
30945
  display
30875
30946
  });
30876
30947
  });
30877
- var layer9 = /* @__PURE__ */ effect(Terminal, /* @__PURE__ */ make39(defaultShouldQuit));
30948
+ var layer9 = /* @__PURE__ */ effect(Terminal, /* @__PURE__ */ make40(defaultShouldQuit));
30878
30949
  function defaultShouldQuit(input) {
30879
30950
  const key = input.key;
30880
30951
  return key.name === "escape" || key.ctrl && (key.name === "c" || key.name === "d");
@@ -31067,4 +31138,4 @@ var runKit = (config, identity, packages) => {
31067
31138
  runMain2(program.pipe(flatMap3((code) => sync2(() => process.exit(code)))));
31068
31139
  };
31069
31140
  // .kitman-build-entry.ts
31070
- runKit(kitman_config_default, { name: "@kitman-sh/software-engineering", version: "0.11.5" }, []);
31141
+ runKit(kitman_config_default, { name: "@kitman-sh/software-engineering", version: "0.11.7" }, []);