@kitman-sh/cli 0.10.105 → 0.11.0-rc.4
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/{chunk-cazap5by.js → chunk-0h5et1rg.js} +6 -6
- package/dist/{chunk-2cznmt28.js → chunk-2aj4ym2c.js} +7 -7
- package/dist/{chunk-5esfnamp.js → chunk-2sfgqfgq.js} +2 -2
- package/dist/{chunk-qcct8vjh.js → chunk-4ngdyd3k.js} +165 -49
- package/dist/{chunk-fe65rbvv.js → chunk-6zrq5xq2.js} +9 -9
- package/dist/{chunk-pme28eew.js → chunk-7d8prq0a.js} +4 -4
- package/dist/{chunk-kadsqvtm.js → chunk-9ew87kjc.js} +7 -212
- package/dist/{chunk-c7ym0ce7.js → chunk-anf9ddey.js} +2 -2
- package/dist/{chunk-xckn5gax.js → chunk-bj73db3f.js} +1 -1
- package/dist/{chunk-30mfra3r.js → chunk-bv9e34qz.js} +1 -1
- package/dist/{chunk-7z9m11z3.js → chunk-cbwmsy27.js} +487 -130
- package/dist/{chunk-tbrpndp2.js → chunk-cegdw7gw.js} +2 -2
- package/dist/{chunk-01fzz2j3.js → chunk-dc681k94.js} +4 -4
- package/dist/{chunk-044h6f3n.js → chunk-k2b10qys.js} +21 -19
- package/dist/{chunk-t80dhv1r.js → chunk-k6mfj25g.js} +3 -3
- package/dist/{chunk-s27r6x3a.js → chunk-kbhm8p3c.js} +5 -5
- package/dist/{chunk-0xjrc51m.js → chunk-nb36pw5d.js} +8 -8
- package/dist/{chunk-1hw35x4x.js → chunk-pqz98b85.js} +5 -5
- package/dist/{chunk-yjnrw9yb.js → chunk-rjdptgqf.js} +4 -4
- package/dist/{chunk-hv44tcjs.js → chunk-tx61h9d8.js} +6 -6
- package/dist/{chunk-che5w0y4.js → chunk-txyp31q5.js} +66 -60
- package/dist/{chunk-hxqxdy21.js → chunk-xmq9zpr1.js} +1 -1
- package/dist/{chunk-fzsbapgz.js → chunk-y0q2574w.js} +12 -12
- package/dist/{chunk-9nrr1dwr.js → chunk-znh6xbze.js} +28 -177
- package/dist/index.js +4 -4
- package/package.json +1 -1
|
@@ -6,10 +6,10 @@ import {
|
|
|
6
6
|
gen,
|
|
7
7
|
flatMap3,
|
|
8
8
|
provideContext2
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-txyp31q5.js";
|
|
10
10
|
import {
|
|
11
11
|
runForEach
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-znh6xbze.js";
|
|
13
13
|
import {
|
|
14
14
|
WebSocketConstructor,
|
|
15
15
|
layerWebSocketConstructorGlobal,
|
|
@@ -19,13 +19,13 @@ import {
|
|
|
19
19
|
RunnerReplicaRpcs,
|
|
20
20
|
RunnerRunFileRpcs,
|
|
21
21
|
ProgramRpcs
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-cbwmsy27.js";
|
|
23
23
|
import {
|
|
24
24
|
layerJson,
|
|
25
25
|
make4,
|
|
26
26
|
withHeaders,
|
|
27
27
|
layerProtocolSocket
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-0h5et1rg.js";
|
|
29
29
|
|
|
30
30
|
// packages/live/src/rpc/runner-client.ts
|
|
31
31
|
var proxiedWebSocket = (proxy) => succeed5(WebSocketConstructor)((target) => {
|
|
@@ -38,7 +38,6 @@ import {
|
|
|
38
38
|
fnUntraced,
|
|
39
39
|
makeFormatterStandardSchemaV1,
|
|
40
40
|
transform,
|
|
41
|
-
declare,
|
|
42
41
|
is,
|
|
43
42
|
encodeEffect,
|
|
44
43
|
isSchema,
|
|
@@ -46,7 +45,6 @@ import {
|
|
|
46
45
|
optional,
|
|
47
46
|
Literal,
|
|
48
47
|
Never,
|
|
49
|
-
Null,
|
|
50
48
|
String4,
|
|
51
49
|
Boolean2,
|
|
52
50
|
Void,
|
|
@@ -72,24 +70,15 @@ import {
|
|
|
72
70
|
Cause,
|
|
73
71
|
Class2,
|
|
74
72
|
TaggedError2,
|
|
75
|
-
toEquivalence,
|
|
76
73
|
toCodecJson,
|
|
77
74
|
Json
|
|
78
|
-
} from "./chunk-
|
|
75
|
+
} from "./chunk-txyp31q5.js";
|
|
79
76
|
import {
|
|
80
77
|
guard
|
|
81
|
-
} from "./chunk-
|
|
78
|
+
} from "./chunk-bv9e34qz.js";
|
|
82
79
|
import {
|
|
83
80
|
currentTimeMillis,
|
|
84
81
|
WebCrypto,
|
|
85
|
-
SafeJson,
|
|
86
|
-
AgentSandboxNetwork,
|
|
87
|
-
AgentEfforts,
|
|
88
|
-
AgentCapabilities,
|
|
89
|
-
LoopDataSchemaRef,
|
|
90
|
-
LoopVersion,
|
|
91
|
-
ProgramLoop,
|
|
92
|
-
AgentFallback,
|
|
93
82
|
ProgramWorkUnit,
|
|
94
83
|
MeasureEvidence,
|
|
95
84
|
CatchUp,
|
|
@@ -101,15 +90,15 @@ import {
|
|
|
101
90
|
bodyUint8Array,
|
|
102
91
|
filterStatusOk,
|
|
103
92
|
HttpClient,
|
|
104
|
-
|
|
105
|
-
|
|
93
|
+
LoopCapabilities,
|
|
94
|
+
LoopManifest,
|
|
106
95
|
KitSetup,
|
|
107
96
|
RunnerRpcError
|
|
108
|
-
} from "./chunk-
|
|
97
|
+
} from "./chunk-cbwmsy27.js";
|
|
109
98
|
import {
|
|
110
99
|
runForEach,
|
|
111
100
|
FileSystem
|
|
112
|
-
} from "./chunk-
|
|
101
|
+
} from "./chunk-znh6xbze.js";
|
|
113
102
|
|
|
114
103
|
// node_modules/.bun/effect@4.1.2/node_modules/effect/dist/crypto/internal/webCrypto.js
|
|
115
104
|
var subtleUnavailable = () => new Error("crypto.subtle is unavailable; browsers expose it only in secure contexts");
|
|
@@ -135,200 +124,6 @@ var sha256 = {
|
|
|
135
124
|
implementation: undefined
|
|
136
125
|
};
|
|
137
126
|
|
|
138
|
-
// packages/core/src/schedule.ts
|
|
139
|
-
var ScheduleFrequency = ["daily", "weekly"];
|
|
140
|
-
var ScheduleMisfirePolicies = ["skip", "fire_once", "catch_up"];
|
|
141
|
-
var ScheduleOverlapPolicies = ["allow", "skip", "coalesce"];
|
|
142
|
-
var ScheduleVersionStatuses = ["draft", "published", "disabled", "archived"];
|
|
143
|
-
var ScheduleCalendarRule = Struct({
|
|
144
|
-
frequency: Literals(ScheduleFrequency),
|
|
145
|
-
hour: Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(23)),
|
|
146
|
-
minute: Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(59)),
|
|
147
|
-
second: optionalKey(Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(59))),
|
|
148
|
-
daysOfWeek: optionalKey(ArraySchema(Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(6))).check(isMinLength(1), isMaxLength(7)))
|
|
149
|
-
});
|
|
150
|
-
var ScheduleCronRule = Struct({
|
|
151
|
-
cron: String4.check(isMinLength(9), isMaxLength(200), isPattern(new RegExp("^[0-9*,/-]+( [0-9*,/-]+){4}$", "u")))
|
|
152
|
-
});
|
|
153
|
-
var ScheduleRule = Union([ScheduleCalendarRule, ScheduleCronRule]);
|
|
154
|
-
var cronBounds = [
|
|
155
|
-
[0, 59],
|
|
156
|
-
[0, 23],
|
|
157
|
-
[1, 31],
|
|
158
|
-
[1, 12],
|
|
159
|
-
[0, 7]
|
|
160
|
-
];
|
|
161
|
-
function cronField(field, [min, max]) {
|
|
162
|
-
const values = new Set;
|
|
163
|
-
for (const part of field.split(",")) {
|
|
164
|
-
const match = /^(\*|(\d+)(?:-(\d+))?)(?:\/(\d+))?$/.exec(part);
|
|
165
|
-
if (match === null)
|
|
166
|
-
return;
|
|
167
|
-
const from = match[1] === "*" ? min : Number(match[2]);
|
|
168
|
-
const to = match[1] === "*" ? max : match[3] === undefined ? match[4] === undefined ? from : max : Number(match[3]);
|
|
169
|
-
const step = match[4] === undefined ? 1 : Number(match[4]);
|
|
170
|
-
if (from < min || to > max || from > to || step < 1)
|
|
171
|
-
return;
|
|
172
|
-
for (let value = from;value <= to; value += step)
|
|
173
|
-
values.add(value);
|
|
174
|
-
}
|
|
175
|
-
return values;
|
|
176
|
-
}
|
|
177
|
-
function parseCron(cron) {
|
|
178
|
-
const fields = cron.split(" ");
|
|
179
|
-
const [minutes, hours, days, months, weekdays] = fields.map((field, index) => cronField(field, cronBounds[index] ?? [0, 0]));
|
|
180
|
-
if (fields.length !== 5 || !minutes || !hours || !days || !months || !weekdays)
|
|
181
|
-
return;
|
|
182
|
-
return {
|
|
183
|
-
minutes,
|
|
184
|
-
hours,
|
|
185
|
-
days,
|
|
186
|
-
months,
|
|
187
|
-
weekdays: new Set([...weekdays].map((value) => value % 7)),
|
|
188
|
-
dayRestricted: !(fields[2] ?? "").startsWith("*"),
|
|
189
|
-
weekdayRestricted: !(fields[4] ?? "").startsWith("*")
|
|
190
|
-
};
|
|
191
|
-
}
|
|
192
|
-
function isScheduleRule(value) {
|
|
193
|
-
return guard(ScheduleRule)(value) && (!("cron" in value) || parseCron(value.cron) !== undefined);
|
|
194
|
-
}
|
|
195
|
-
var ScheduleVersion = Struct({
|
|
196
|
-
contractVersion: Literal("schedule.v1"),
|
|
197
|
-
id: String4.check(isMinLength(1)),
|
|
198
|
-
scheduleId: String4.check(isMinLength(1)),
|
|
199
|
-
workspaceId: String4.check(isMinLength(1)),
|
|
200
|
-
teamId: optionalKey(String4.check(isMinLength(1))),
|
|
201
|
-
loopId: optionalKey(String4.check(isMinLength(1))),
|
|
202
|
-
name: optionalKey(String4.check(isMinLength(1), isMaxLength(200))),
|
|
203
|
-
version: Int.check(isGreaterThanOrEqualTo(1)),
|
|
204
|
-
status: Literals(ScheduleVersionStatuses),
|
|
205
|
-
timezone: String4.check(isMinLength(1), isMaxLength(80)),
|
|
206
|
-
rule: ScheduleRule,
|
|
207
|
-
misfirePolicy: Literals(ScheduleMisfirePolicies),
|
|
208
|
-
overlapPolicy: Literals(ScheduleOverlapPolicies),
|
|
209
|
-
maxCatchUp: Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(200)),
|
|
210
|
-
misfireGraceSeconds: optionalKey(Int.check(isGreaterThanOrEqualTo(0), isLessThanOrEqualTo(604800))),
|
|
211
|
-
inputSchemaRef: optionalKey(LoopDataSchemaRef),
|
|
212
|
-
input: optionalKey(SafeJson),
|
|
213
|
-
createdAt: String4.check(isMinLength(1))
|
|
214
|
-
});
|
|
215
|
-
var zones = new Map;
|
|
216
|
-
var resolvedLocalDateTimes = new Map;
|
|
217
|
-
|
|
218
|
-
// packages/core/src/kit-declarations.ts
|
|
219
|
-
var LoopCapabilities = [
|
|
220
|
-
"agent_work",
|
|
221
|
-
"ask",
|
|
222
|
-
"call",
|
|
223
|
-
"verify",
|
|
224
|
-
"change_request",
|
|
225
|
-
"write_back",
|
|
226
|
-
"post_comment",
|
|
227
|
-
"create_tasks",
|
|
228
|
-
"merge_change_request",
|
|
229
|
-
"approve_change_request",
|
|
230
|
-
"publish_release",
|
|
231
|
-
"read_transcripts",
|
|
232
|
-
"read_change_request",
|
|
233
|
-
"measure",
|
|
234
|
-
"claim",
|
|
235
|
-
"propose",
|
|
236
|
-
"read_project",
|
|
237
|
-
"draft_update"
|
|
238
|
-
];
|
|
239
|
-
var JsonObject = Record(String4, Json);
|
|
240
|
-
var SecretName = String4.check(isPattern(/^[A-Za-z_][A-Za-z0-9_]{0,127}$/));
|
|
241
|
-
var EventFilterValue = Union([String4, Finite, Boolean2, Null]);
|
|
242
|
-
var LoopManifest = Struct({
|
|
243
|
-
id: String4,
|
|
244
|
-
title: String4,
|
|
245
|
-
version: optionalKey(LoopVersion),
|
|
246
|
-
input: JsonObject,
|
|
247
|
-
output: JsonObject,
|
|
248
|
-
outcome: optionalKey(Literals(["feature", "bug", "refactor", "investigation", "docs", "migration", "performance"])),
|
|
249
|
-
agents: Record(String4, String4),
|
|
250
|
-
checkout: Literals(["none", "read", "write"]),
|
|
251
|
-
when: ArraySchema(Struct({
|
|
252
|
-
event: String4,
|
|
253
|
-
filter: optionalKey(Record(String4, Union([EventFilterValue, ArraySchema(EventFilterValue)]))),
|
|
254
|
-
input: Record(String4, String4),
|
|
255
|
-
values: optionalKey(JsonObject)
|
|
256
|
-
})),
|
|
257
|
-
offers: ArraySchema(Struct({
|
|
258
|
-
id: String4,
|
|
259
|
-
title: String4,
|
|
260
|
-
loop: String4,
|
|
261
|
-
from: optionalKey(String4)
|
|
262
|
-
})),
|
|
263
|
-
capabilities: ArraySchema(Literals(LoopCapabilities)),
|
|
264
|
-
ownCapabilities: optionalKey(ArraySchema(Literals(LoopCapabilities))),
|
|
265
|
-
secrets: optionalKey(ArraySchema(SecretName)),
|
|
266
|
-
network: optionalKey(AgentSandboxNetwork),
|
|
267
|
-
schedule: optionalKey(Struct({ rule: ScheduleRule, timezone: String4 }))
|
|
268
|
-
});
|
|
269
|
-
var LoopDetail = Struct({
|
|
270
|
-
id: String4,
|
|
271
|
-
resolved: optionalKey(Struct({
|
|
272
|
-
...ProgramLoop.fields,
|
|
273
|
-
agents: LoopManifest.fields.agents,
|
|
274
|
-
when: LoopManifest.fields.when,
|
|
275
|
-
schedule: optionalKey(Struct({
|
|
276
|
-
rule: ScheduleRule,
|
|
277
|
-
timezone: String4,
|
|
278
|
-
on: Boolean2,
|
|
279
|
-
nextRunAt: optionalKey(String4)
|
|
280
|
-
}))
|
|
281
|
-
}))
|
|
282
|
-
});
|
|
283
|
-
var AgentDeclaration = Struct({
|
|
284
|
-
extends: optionalKey(String4),
|
|
285
|
-
instructions: optionalKey(String4),
|
|
286
|
-
harness: optionalKey(String4),
|
|
287
|
-
model: optionalKey(String4),
|
|
288
|
-
effort: optionalKey(Literals(AgentEfforts)),
|
|
289
|
-
fallbacks: optionalKey(ArraySchema(AgentFallback)),
|
|
290
|
-
tools: optionalKey(ArraySchema(Literals(AgentCapabilities))),
|
|
291
|
-
skills: optionalKey(ArraySchema(String4.check(isMinLength(1)))),
|
|
292
|
-
network: optionalKey(Union([Struct({ hosts: ArraySchema(String4) }), Literal("open")])),
|
|
293
|
-
sandbox: optionalKey(Literal("docker"))
|
|
294
|
-
});
|
|
295
|
-
var scheduleFields = {
|
|
296
|
-
name: String4.check(isMinLength(1)),
|
|
297
|
-
loop: String4,
|
|
298
|
-
team: optionalKey(String4),
|
|
299
|
-
input: optionalKey(JsonObject),
|
|
300
|
-
timezone: String4,
|
|
301
|
-
misfire: optionalKey(Literals(ScheduleMisfirePolicies)),
|
|
302
|
-
overlap: optionalKey(Literals(ScheduleOverlapPolicies))
|
|
303
|
-
};
|
|
304
|
-
var ScheduleDeclaration = Union([
|
|
305
|
-
Struct({
|
|
306
|
-
...scheduleFields,
|
|
307
|
-
cron: String4.check(makeFilter((cron) => isScheduleRule({ cron }) || "five cron fields, each within its range"))
|
|
308
|
-
}),
|
|
309
|
-
Struct({
|
|
310
|
-
...scheduleFields,
|
|
311
|
-
rule: declare((value) => isScheduleRule(value), {
|
|
312
|
-
expected: "a Schedule rule: frequency daily or weekly, hour, minute, and optionally second and daysOfWeek"
|
|
313
|
-
})
|
|
314
|
-
})
|
|
315
|
-
]);
|
|
316
|
-
var CarriedKit = Struct({
|
|
317
|
-
name: KitName,
|
|
318
|
-
version: String4.check(isMinLength(1)),
|
|
319
|
-
setup: KitDigest,
|
|
320
|
-
loops: ArraySchema(String4),
|
|
321
|
-
agents: ArraySchema(String4)
|
|
322
|
-
});
|
|
323
|
-
var KitDeclarations = Struct({
|
|
324
|
-
loops: ArraySchema(LoopManifest),
|
|
325
|
-
agents: Record(String4, AgentDeclaration),
|
|
326
|
-
schedules: optionalKey(Record(String4, ScheduleDeclaration)),
|
|
327
|
-
carried: optionalKey(ArraySchema(CarriedKit))
|
|
328
|
-
});
|
|
329
|
-
var sameLoop = toEquivalence(LoopManifest);
|
|
330
|
-
var sameAgent = toEquivalence(AgentDeclaration);
|
|
331
|
-
|
|
332
127
|
// packages/sdk/src/loop/define.ts
|
|
333
128
|
var LoopOutcome = Literals([
|
|
334
129
|
"feature",
|
|
@@ -1136,4 +931,4 @@ var redirectStatuses = new Set([301, 302, 303, 307, 308]);
|
|
|
1136
931
|
var readStdin = tryPromise(() => Bun.stdin.text());
|
|
1137
932
|
var isWorkUnit = guard(ProgramWorkUnit);
|
|
1138
933
|
|
|
1139
|
-
export {
|
|
934
|
+
export { uploadRunFile, programLease, rpcRunFiles, describeFlag, Described, programHostsEnv, undeclaredHostsEnv };
|
|
@@ -14,8 +14,8 @@ import {
|
|
|
14
14
|
writeSrtSettings2,
|
|
15
15
|
srtStepArgv2,
|
|
16
16
|
srtArgv2
|
|
17
|
-
} from "./chunk-
|
|
18
|
-
import"./chunk-
|
|
17
|
+
} from "./chunk-znh6xbze.js";
|
|
18
|
+
import"./chunk-txyp31q5.js";
|
|
19
19
|
export {
|
|
20
20
|
compiled2 as compiled,
|
|
21
21
|
harnessesUnsupportedInSrt2 as harnessesUnsupportedInSrt,
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
isMinLength,
|
|
19
19
|
isMaxLength,
|
|
20
20
|
FiniteFromString
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-txyp31q5.js";
|
|
22
22
|
|
|
23
23
|
// node_modules/.bun/effect@4.1.2/node_modules/effect/dist/JsonSchema.js
|
|
24
24
|
var PRE_2020_TO_2020_COLLISIONS = ["$anchor", "$defs", "$dynamicAnchor", "$dynamicRef", "$vocabulary", "contentSchema", "dependentRequired", "dependentSchemas", "maxContains", "minContains", "prefixItems", "unevaluatedItems", "unevaluatedProperties"];
|