@drisp/cli 0.7.3 → 0.7.5
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/{WorkflowInstallWizard-AJYDKFDL.js → WorkflowInstallWizard-4GRQGM42.js} +2 -2
- package/dist/{chunk-7R3HR7VJ.js → chunk-N4B7HLBN.js} +2 -2
- package/dist/{chunk-6HOVFCCB.js → chunk-TG5EGPD2.js} +45 -13
- package/dist/{chunk-TSIMXPJN.js → chunk-UQWOGG3L.js} +1 -2
- package/dist/cli.js +12 -7
- package/dist/dashboard-daemon.js +3 -3
- package/dist/runner.js +3 -3
- package/package.json +1 -1
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
installWorkflowPlugins,
|
|
9
9
|
resolveWorkflow,
|
|
10
10
|
writeGlobalConfig
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-UQWOGG3L.js";
|
|
12
12
|
import "./chunk-G3PMV62Z.js";
|
|
13
13
|
|
|
14
14
|
// src/setup/steps/WorkflowInstallWizard.tsx
|
|
@@ -93,4 +93,4 @@ function WorkflowInstallWizard({ source, onDone }) {
|
|
|
93
93
|
export {
|
|
94
94
|
WorkflowInstallWizard as default
|
|
95
95
|
};
|
|
96
|
-
//# sourceMappingURL=WorkflowInstallWizard-
|
|
96
|
+
//# sourceMappingURL=WorkflowInstallWizard-4GRQGM42.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runMachineRunners
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-TG5EGPD2.js";
|
|
4
4
|
|
|
5
5
|
// src/app/entry/runnerDaemon.ts
|
|
6
6
|
if (process.argv.includes("--help")) {
|
|
@@ -13,4 +13,4 @@ if (process.argv.includes("--help")) {
|
|
|
13
13
|
process.exitCode = 1;
|
|
14
14
|
});
|
|
15
15
|
}
|
|
16
|
-
//# sourceMappingURL=chunk-
|
|
16
|
+
//# sourceMappingURL=chunk-N4B7HLBN.js.map
|
|
@@ -19,7 +19,6 @@ import {
|
|
|
19
19
|
BUILD_STRINGS,
|
|
20
20
|
DEFAULT_PERMISSION_GRACE_MS,
|
|
21
21
|
LAYOUT_MARKERS,
|
|
22
|
-
ORCHESTRATOR_LIMITS,
|
|
23
22
|
ORCHESTRATOR_LOOP,
|
|
24
23
|
WAITING_ON_CHILDREN_STOP_REASON,
|
|
25
24
|
compileWorkflowPlan,
|
|
@@ -55,7 +54,7 @@ import {
|
|
|
55
54
|
verifyRendered,
|
|
56
55
|
wakesFreshAfterHandover,
|
|
57
56
|
workflowRegistryDir
|
|
58
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-UQWOGG3L.js";
|
|
59
58
|
import {
|
|
60
59
|
__commonJS,
|
|
61
60
|
__toESM
|
|
@@ -13066,6 +13065,26 @@ var AssignmentRejectedReasonSchema = external_exports.enum([
|
|
|
13066
13065
|
"workspace_invalid"
|
|
13067
13066
|
]);
|
|
13068
13067
|
|
|
13068
|
+
// ../../packages/protocol/src/budget.ts
|
|
13069
|
+
var SIZE_CLASS_CAPS = {
|
|
13070
|
+
S: 3e6,
|
|
13071
|
+
M: 6e6,
|
|
13072
|
+
L: 12e6
|
|
13073
|
+
};
|
|
13074
|
+
var SIZE_CLASS_FORECASTS = {
|
|
13075
|
+
S: 15e4,
|
|
13076
|
+
M: 4e5,
|
|
13077
|
+
L: 12e5
|
|
13078
|
+
};
|
|
13079
|
+
function classOfCap(declaredCap) {
|
|
13080
|
+
if (Number.isNaN(declaredCap) || declaredCap <= SIZE_CLASS_CAPS.S) return "S";
|
|
13081
|
+
if (declaredCap <= SIZE_CLASS_CAPS.M) return "M";
|
|
13082
|
+
return "L";
|
|
13083
|
+
}
|
|
13084
|
+
function forecastOfCap(declaredCap) {
|
|
13085
|
+
return SIZE_CLASS_FORECASTS[classOfCap(declaredCap)];
|
|
13086
|
+
}
|
|
13087
|
+
|
|
13069
13088
|
// ../../packages/protocol/src/v2.ts
|
|
13070
13089
|
var protocolVersion = { major: 2, minor: 2 };
|
|
13071
13090
|
var conversationContinuationCapability = "conversation_continuation";
|
|
@@ -14873,7 +14892,7 @@ async function restoreCheckpoint(store, input) {
|
|
|
14873
14892
|
|
|
14874
14893
|
// ../../modules/runtime/src/software-version.ts
|
|
14875
14894
|
import "fs";
|
|
14876
|
-
var runnerSoftwareVersion = true ? "0.7.
|
|
14895
|
+
var runnerSoftwareVersion = true ? "0.7.5" : JSON.parse(readFileSync2(new URL("../../../apps/cli/package.json", import.meta.url), "utf8")).version;
|
|
14877
14896
|
|
|
14878
14897
|
// ../../modules/runtime/src/connection.ts
|
|
14879
14898
|
var RunnerDisconnectedError = class extends Error {
|
|
@@ -20241,7 +20260,8 @@ var issueEntrySchema = external_exports.strictObject({
|
|
|
20241
20260
|
workflowName: external_exports.string().max(128)
|
|
20242
20261
|
});
|
|
20243
20262
|
var buildPlanSchema = external_exports.strictObject({
|
|
20244
|
-
|
|
20263
|
+
/** 3 carries the forecast; 2 (read, never written) carried the sum of the children's caps. */
|
|
20264
|
+
version: external_exports.union([external_exports.literal(2), external_exports.literal(3)]),
|
|
20245
20265
|
orchestratorRunId: external_exports.string().min(1),
|
|
20246
20266
|
planKey: external_exports.string().regex(/^plan:.+$/),
|
|
20247
20267
|
projectId: external_exports.string().min(1),
|
|
@@ -20250,11 +20270,18 @@ var buildPlanSchema = external_exports.strictObject({
|
|
|
20250
20270
|
templateVersion: external_exports.string().regex(/^[0-9a-f]{64}$/),
|
|
20251
20271
|
branch: external_exports.string().regex(/^drisp\/build-[a-z0-9]+$/),
|
|
20252
20272
|
commit: external_exports.string().regex(/^[0-9a-f]{40}$/),
|
|
20253
|
-
budget: external_exports.
|
|
20254
|
-
|
|
20255
|
-
|
|
20256
|
-
|
|
20257
|
-
|
|
20273
|
+
budget: external_exports.union([
|
|
20274
|
+
external_exports.strictObject({
|
|
20275
|
+
tokenBudget: count,
|
|
20276
|
+
orchestratorCap: count,
|
|
20277
|
+
forecast: count
|
|
20278
|
+
}),
|
|
20279
|
+
external_exports.strictObject({
|
|
20280
|
+
tokenBudget: count,
|
|
20281
|
+
orchestratorCap: count,
|
|
20282
|
+
childCapsSum: count
|
|
20283
|
+
})
|
|
20284
|
+
]),
|
|
20258
20285
|
groups: external_exports.array(
|
|
20259
20286
|
external_exports.strictObject({
|
|
20260
20287
|
index: external_exports.number().int().positive(),
|
|
@@ -20607,11 +20634,12 @@ function planBuild(context) {
|
|
|
20607
20634
|
});
|
|
20608
20635
|
}
|
|
20609
20636
|
const groups = layers.map((issues, index) => ({ index: index + 1, issues }));
|
|
20637
|
+
const forecast = groups.flatMap((group2) => group2.issues).reduce((sum, entry) => sum + SIZE_CLASS_FORECASTS[entry.sizeClass], 0);
|
|
20610
20638
|
return {
|
|
20611
20639
|
status: "planned",
|
|
20612
20640
|
workflows,
|
|
20613
20641
|
plan: {
|
|
20614
|
-
version:
|
|
20642
|
+
version: 3,
|
|
20615
20643
|
orchestratorRunId: context.orchestratorRunId,
|
|
20616
20644
|
planKey: `plan:${input.project.id}`,
|
|
20617
20645
|
projectId: input.project.id,
|
|
@@ -20620,9 +20648,9 @@ function planBuild(context) {
|
|
|
20620
20648
|
templateVersion: context.templateVersion,
|
|
20621
20649
|
branch: buildBranch(input.project.slugId),
|
|
20622
20650
|
budget: {
|
|
20623
|
-
tokenBudget:
|
|
20651
|
+
tokenBudget: defaultBudget(forecast),
|
|
20624
20652
|
orchestratorCap: ORCHESTRATOR_LOOP.maxRunTokens,
|
|
20625
|
-
|
|
20653
|
+
forecast
|
|
20626
20654
|
},
|
|
20627
20655
|
groups,
|
|
20628
20656
|
skipped,
|
|
@@ -20647,6 +20675,9 @@ function finalizePlan(draft, commit) {
|
|
|
20647
20675
|
...needsPerson ? { needsPerson } : {}
|
|
20648
20676
|
};
|
|
20649
20677
|
}
|
|
20678
|
+
function defaultBudget(forecast) {
|
|
20679
|
+
return Math.ceil(forecast * 1.5 / 1e5) * 1e5;
|
|
20680
|
+
}
|
|
20650
20681
|
|
|
20651
20682
|
// src/core/build/childWorktree.ts
|
|
20652
20683
|
import fs23 from "fs";
|
|
@@ -21879,6 +21910,7 @@ export {
|
|
|
21879
21910
|
RUN_EXIT_CODE,
|
|
21880
21911
|
localAnswerDecision,
|
|
21881
21912
|
runExec,
|
|
21913
|
+
forecastOfCap,
|
|
21882
21914
|
repositoryBindingSchema,
|
|
21883
21915
|
commandSchema,
|
|
21884
21916
|
historyRecordSchema,
|
|
@@ -21935,4 +21967,4 @@ export {
|
|
|
21935
21967
|
runMachineRunners,
|
|
21936
21968
|
writeIdentityOnce
|
|
21937
21969
|
};
|
|
21938
|
-
//# sourceMappingURL=chunk-
|
|
21970
|
+
//# sourceMappingURL=chunk-TG5EGPD2.js.map
|
|
@@ -21287,7 +21287,6 @@ var workflow_default = '# Orchestrator: plan and run a Build\n\nYou plan and run
|
|
|
21287
21287
|
var ORCHESTRATOR_WORKFLOW_NAME = "orchestrator";
|
|
21288
21288
|
var ORCHESTRATOR_LIMITS = {
|
|
21289
21289
|
maxChildren: 2,
|
|
21290
|
-
tokenBudget: 6e7,
|
|
21291
21290
|
tickAllowance: 300
|
|
21292
21291
|
};
|
|
21293
21292
|
var ORCHESTRATOR_LOOP = {
|
|
@@ -24251,4 +24250,4 @@ export {
|
|
|
24251
24250
|
compileWorkflowPlan,
|
|
24252
24251
|
collectMcpServersWithOptions
|
|
24253
24252
|
};
|
|
24254
|
-
//# sourceMappingURL=chunk-
|
|
24253
|
+
//# sourceMappingURL=chunk-UQWOGG3L.js.map
|
package/dist/cli.js
CHANGED
|
@@ -47,6 +47,7 @@ import {
|
|
|
47
47
|
finalizePlan,
|
|
48
48
|
fit,
|
|
49
49
|
fitAnsi,
|
|
50
|
+
forecastOfCap,
|
|
50
51
|
forgetRunner,
|
|
51
52
|
formatClock,
|
|
52
53
|
formatProbeCommand,
|
|
@@ -139,7 +140,7 @@ import {
|
|
|
139
140
|
visualPositionToOffset,
|
|
140
141
|
wrapText,
|
|
141
142
|
writeIdentityOnce
|
|
142
|
-
} from "./chunk-
|
|
143
|
+
} from "./chunk-TG5EGPD2.js";
|
|
143
144
|
import {
|
|
144
145
|
generateId as generateId2
|
|
145
146
|
} from "./chunk-PQIB66SG.js";
|
|
@@ -197,7 +198,7 @@ import {
|
|
|
197
198
|
workflowRegistryDir,
|
|
198
199
|
writeGlobalConfig,
|
|
199
200
|
writeProjectConfig
|
|
200
|
-
} from "./chunk-
|
|
201
|
+
} from "./chunk-UQWOGG3L.js";
|
|
201
202
|
import {
|
|
202
203
|
__toESM
|
|
203
204
|
} from "./chunk-G3PMV62Z.js";
|
|
@@ -14361,15 +14362,15 @@ function assessTick(facts) {
|
|
|
14361
14362
|
}).length;
|
|
14362
14363
|
const queue = [];
|
|
14363
14364
|
if (!parkReason) {
|
|
14364
|
-
let
|
|
14365
|
+
let committed = Object.values(state.attempts).flat().reduce((sum, attempt) => sum + forecastOfCap(attempt.tokenCap), 0);
|
|
14365
14366
|
for (const entry of entries) {
|
|
14366
14367
|
if (status.get(entry.id) !== "ready") continue;
|
|
14367
|
-
if (
|
|
14368
|
+
if (committed + forecastOfCap(entry.tokenCap) > facts.limits.tokenBudget) {
|
|
14368
14369
|
parkReason = "budget";
|
|
14369
14370
|
break;
|
|
14370
14371
|
}
|
|
14371
14372
|
queue.push(entry);
|
|
14372
|
-
|
|
14373
|
+
committed += forecastOfCap(entry.tokenCap);
|
|
14373
14374
|
}
|
|
14374
14375
|
}
|
|
14375
14376
|
return {
|
|
@@ -14528,7 +14529,11 @@ async function runBuildTick(deps) {
|
|
|
14528
14529
|
state: stored,
|
|
14529
14530
|
children: children.runs,
|
|
14530
14531
|
templateVersion,
|
|
14531
|
-
|
|
14532
|
+
// The approved plan's budget (the member's, once it is editable) narrowed by what the Hub enforces.
|
|
14533
|
+
limits: buildLimits(
|
|
14534
|
+
{ ...ORCHESTRATOR_LIMITS, tokenBudget: plan.budget.tokenBudget },
|
|
14535
|
+
parent.delegation
|
|
14536
|
+
),
|
|
14532
14537
|
pullRequests: (branch) => deps.pullRequests(deps.folder, branch),
|
|
14533
14538
|
locate: (entry) => locate(deps, entry, issues.get(entry.id)?.branchName),
|
|
14534
14539
|
rebaseFailed: deps.rebaseFailed ?? [],
|
|
@@ -15953,7 +15958,7 @@ Available commands: ${[...KNOWN_COMMANDS].join(", ")}`
|
|
|
15953
15958
|
await exitWith(1);
|
|
15954
15959
|
return;
|
|
15955
15960
|
}
|
|
15956
|
-
const { default: WorkflowInstallWizard } = await import("./WorkflowInstallWizard-
|
|
15961
|
+
const { default: WorkflowInstallWizard } = await import("./WorkflowInstallWizard-4GRQGM42.js");
|
|
15957
15962
|
const { waitUntilExit } = render(
|
|
15958
15963
|
/* @__PURE__ */ jsx24(
|
|
15959
15964
|
WorkflowInstallWizard,
|
package/dist/dashboard-daemon.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "./chunk-
|
|
2
|
-
import "./chunk-
|
|
1
|
+
import "./chunk-N4B7HLBN.js";
|
|
2
|
+
import "./chunk-TG5EGPD2.js";
|
|
3
3
|
import "./chunk-PQIB66SG.js";
|
|
4
|
-
import "./chunk-
|
|
4
|
+
import "./chunk-UQWOGG3L.js";
|
|
5
5
|
import "./chunk-G3PMV62Z.js";
|
|
6
6
|
//# sourceMappingURL=dashboard-daemon.js.map
|
package/dist/runner.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "./chunk-
|
|
2
|
-
import "./chunk-
|
|
1
|
+
import "./chunk-N4B7HLBN.js";
|
|
2
|
+
import "./chunk-TG5EGPD2.js";
|
|
3
3
|
import "./chunk-PQIB66SG.js";
|
|
4
|
-
import "./chunk-
|
|
4
|
+
import "./chunk-UQWOGG3L.js";
|
|
5
5
|
import "./chunk-G3PMV62Z.js";
|
|
6
6
|
//# sourceMappingURL=runner.js.map
|