looply-cli 0.5.51 → 0.5.52
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/.src-hash +1 -1
- package/dist/account-connect.d.ts +2 -1
- package/dist/account-connect.d.ts.map +1 -1
- package/dist/account-connect.js.map +1 -1
- package/dist/adaptive-budget.d.ts +6 -0
- package/dist/adaptive-budget.d.ts.map +1 -1
- package/dist/adaptive-budget.js +9 -0
- package/dist/adaptive-budget.js.map +1 -1
- package/dist/base-check-turns.d.ts +38 -0
- package/dist/base-check-turns.d.ts.map +1 -0
- package/dist/base-check-turns.js +118 -0
- package/dist/base-check-turns.js.map +1 -0
- package/dist/bin.d.ts.map +1 -1
- package/dist/bin.js +32 -2
- package/dist/bin.js.map +1 -1
- package/dist/bug-repro.d.ts +13 -0
- package/dist/bug-repro.d.ts.map +1 -1
- package/dist/bug-repro.js +43 -1
- package/dist/bug-repro.js.map +1 -1
- package/dist/checkout-carry.d.ts +31 -0
- package/dist/checkout-carry.d.ts.map +1 -1
- package/dist/checkout-carry.js +98 -3
- package/dist/checkout-carry.js.map +1 -1
- package/dist/checkout-deps.d.ts +2 -0
- package/dist/checkout-deps.d.ts.map +1 -1
- package/dist/checkout-deps.js +2 -0
- package/dist/checkout-deps.js.map +1 -1
- package/dist/daemon-cmd.d.ts +1 -1
- package/dist/daemon-cmd.d.ts.map +1 -1
- package/dist/daemon-cmd.js +8 -1
- package/dist/daemon-cmd.js.map +1 -1
- package/dist/fresh-gates.d.ts.map +1 -1
- package/dist/fresh-gates.js +13 -0
- package/dist/fresh-gates.js.map +1 -1
- package/dist/gate-health.d.ts +2 -0
- package/dist/gate-health.d.ts.map +1 -1
- package/dist/gate-health.js +41 -4
- package/dist/gate-health.js.map +1 -1
- package/dist/goal-adaptive.d.ts +9 -0
- package/dist/goal-adaptive.d.ts.map +1 -1
- package/dist/goal-adaptive.js +32 -11
- package/dist/goal-adaptive.js.map +1 -1
- package/dist/integration-deps.d.ts.map +1 -1
- package/dist/integration-deps.js +18 -0
- package/dist/integration-deps.js.map +1 -1
- package/dist/machine-settings.d.ts +9 -0
- package/dist/machine-settings.d.ts.map +1 -1
- package/dist/machine-settings.js +35 -2
- package/dist/machine-settings.js.map +1 -1
- package/dist/output-gist.d.ts +40 -0
- package/dist/output-gist.d.ts.map +1 -0
- package/dist/output-gist.js +107 -0
- package/dist/output-gist.js.map +1 -0
- package/dist/plan-recovery.d.ts +14 -3
- package/dist/plan-recovery.d.ts.map +1 -1
- package/dist/plan-recovery.js +24 -6
- package/dist/plan-recovery.js.map +1 -1
- package/dist/provider-accounts.d.ts +0 -6
- package/dist/provider-accounts.d.ts.map +1 -1
- package/dist/provider-accounts.js +0 -6
- package/dist/provider-accounts.js.map +1 -1
- package/dist/quarantine-report.d.ts +32 -0
- package/dist/quarantine-report.d.ts.map +1 -0
- package/dist/quarantine-report.js +75 -0
- package/dist/quarantine-report.js.map +1 -0
- package/dist/round-runner.d.ts +13 -2
- package/dist/round-runner.d.ts.map +1 -1
- package/dist/round-runner.js +5 -1
- package/dist/round-runner.js.map +1 -1
- package/dist/run-cmd.d.ts.map +1 -1
- package/dist/run-cmd.js +44 -10
- package/dist/run-cmd.js.map +1 -1
- package/dist/self-update.d.ts.map +1 -1
- package/dist/self-update.js +5 -15
- package/dist/self-update.js.map +1 -1
- package/dist/serve-cmd.d.ts +9 -0
- package/dist/serve-cmd.d.ts.map +1 -1
- package/dist/serve-cmd.js +45 -1
- package/dist/serve-cmd.js.map +1 -1
- package/dist/serve-log.d.ts +52 -0
- package/dist/serve-log.d.ts.map +1 -0
- package/dist/serve-log.js +146 -0
- package/dist/serve-log.js.map +1 -0
- package/dist/serve.d.ts +7 -7
- package/dist/serve.d.ts.map +1 -1
- package/dist/serve.js +11 -15
- package/dist/serve.js.map +1 -1
- package/dist/server-client.d.ts +14 -2
- package/dist/server-client.d.ts.map +1 -1
- package/dist/server-client.js +12 -2
- package/dist/server-client.js.map +1 -1
- package/dist/setup-check-wiring.d.ts.map +1 -1
- package/dist/setup-check-wiring.js +17 -13
- package/dist/setup-check-wiring.js.map +1 -1
- package/dist/setup-check.d.ts.map +1 -1
- package/dist/setup-check.js +18 -1
- package/dist/setup-check.js.map +1 -1
- package/dist/steady-log.d.ts +48 -0
- package/dist/steady-log.d.ts.map +1 -0
- package/dist/steady-log.js +100 -0
- package/dist/steady-log.js.map +1 -0
- package/dist/verify-cmd.d.ts +0 -2
- package/dist/verify-cmd.d.ts.map +1 -1
- package/dist/verify-cmd.js +0 -5
- package/dist/verify-cmd.js.map +1 -1
- package/dist/workspace-builds.d.ts +153 -0
- package/dist/workspace-builds.d.ts.map +1 -0
- package/dist/workspace-builds.js +347 -0
- package/dist/workspace-builds.js.map +1 -0
- package/dist/workspace-quarantine.d.ts +36 -2
- package/dist/workspace-quarantine.d.ts.map +1 -1
- package/dist/workspace-quarantine.js +53 -0
- package/dist/workspace-quarantine.js.map +1 -1
- package/dist/workspace.d.ts.map +1 -1
- package/dist/workspace.js +11 -3
- package/dist/workspace.js.map +1 -1
- package/package.json +2 -2
package/dist/run-cmd.js
CHANGED
|
@@ -29,6 +29,7 @@ const control_file_1 = require("./control-file");
|
|
|
29
29
|
const git_driver_1 = require("./git-driver");
|
|
30
30
|
const untrusted_gate_1 = require("./untrusted-gate");
|
|
31
31
|
const checkout_deps_1 = require("./checkout-deps");
|
|
32
|
+
const workspace_builds_1 = require("./workspace-builds");
|
|
32
33
|
const model_transport_1 = require("./model-transport");
|
|
33
34
|
const agent_envelope_1 = require("./agent-envelope");
|
|
34
35
|
const provider_limit_1 = require("./provider-limit");
|
|
@@ -794,6 +795,8 @@ async function runLoop(opts) {
|
|
|
794
795
|
...(withQuarantine ? { quarantineFor: (cmd) => gateQuarantine.get(cmd) ?? null } : {}),
|
|
795
796
|
substituteFor: (cmd) => gateSubstitute.get(cmd) ?? null,
|
|
796
797
|
});
|
|
798
|
+
/** What Looply built in this checkout, built again before a round's checks when the round changed it. */
|
|
799
|
+
const workspaceBuilds = (0, workspace_builds_1.workspaceRebuilds)(cwd, (0, checkout_deps_1.checkoutDepsFs)(cwd), log);
|
|
797
800
|
const ledger = new ledger_store_1.LedgerStore(stateDir, ledger_store_1.nodeLedgerFs);
|
|
798
801
|
const queue = new queue_store_1.QueueStore(stateDir, ledger_store_1.nodeLedgerFs);
|
|
799
802
|
const evidence = new evidence_cache_1.EvidenceCache(stateDir, ledger_store_1.nodeLedgerFs);
|
|
@@ -2656,7 +2659,7 @@ async function runLoop(opts) {
|
|
|
2656
2659
|
const boundGoal = opts.goalId === undefined ? undefined : goals.get(opts.goalId);
|
|
2657
2660
|
const accountScope = {
|
|
2658
2661
|
projectId: projectId === 'local' ? null : projectId,
|
|
2659
|
-
requesterRef:
|
|
2662
|
+
requesterRef: requesterRefOf(boundGoal),
|
|
2660
2663
|
};
|
|
2661
2664
|
const withFinalMessage = (invoke, role = 'implementer') => builtIn
|
|
2662
2665
|
? (0, agent_envelope_1.unwrapping)((0, provider_limit_1.waitingOutProviderLimits)(invoke, {
|
|
@@ -2881,7 +2884,7 @@ async function runLoop(opts) {
|
|
|
2881
2884
|
let compileTimedOut = false;
|
|
2882
2885
|
let checkTimedOut = false;
|
|
2883
2886
|
// RBB-B-218: the step check's own tier, and whether a pass this run checked nothing in time.
|
|
2884
|
-
const verifyKey = binding.kind === 'bound' ? (0,
|
|
2887
|
+
const verifyKey = binding.kind === 'bound' ? (0, adaptive_budget_1.verifyTimeoutKey)(binding.goal.id, binding.goal.version) : null;
|
|
2885
2888
|
const verifyTier = (0, verify_cmd_2.verifierTierFor)(verifyKey === null ? 0 : (0, planner_timeouts_1.plannerTimeoutsFor)(projectStateDirPath, verifyKey));
|
|
2886
2889
|
let verifyTimedOut = false;
|
|
2887
2890
|
/**
|
|
@@ -3619,7 +3622,10 @@ async function runLoop(opts) {
|
|
|
3619
3622
|
isAncestor: (a, of) => git.isAncestor(a, of),
|
|
3620
3623
|
changedPathsBetween: (from, to) => git.changedPathsBetween(from, to),
|
|
3621
3624
|
runGates: async (paths) => {
|
|
3622
|
-
const
|
|
3625
|
+
const rebuilt = workspaceBuilds.before();
|
|
3626
|
+
const gate = await (0, gate_1.runGate)({ steps: [...rebuilt, ...config.gates], changedPaths: paths, runner: gateRunnerHere(true) });
|
|
3627
|
+
if (rebuilt.length > 0)
|
|
3628
|
+
workspaceBuilds.after(gate.steps);
|
|
3623
3629
|
reproofVerdict = gate.verdict;
|
|
3624
3630
|
return gate.steps;
|
|
3625
3631
|
},
|
|
@@ -3687,6 +3693,10 @@ async function runLoop(opts) {
|
|
|
3687
3693
|
// M3-2: the adaptive plan's answer is checked and recorded the same way; a plan
|
|
3688
3694
|
// with every step refused is no decision, not an empty revision.
|
|
3689
3695
|
let adaptiveChecked = null;
|
|
3696
|
+
// What the goal check said is missing, in the run log — it was written nowhere (`gapLogLines`).
|
|
3697
|
+
if (adaptive.kind === 'planned' || adaptive.kind === 'budget-exhausted')
|
|
3698
|
+
for (const l of (0, goal_adaptive_1.gapLogLines)(adaptive.gaps))
|
|
3699
|
+
log(l);
|
|
3690
3700
|
if (adaptive.kind === 'planned') {
|
|
3691
3701
|
const adaptiveAt = await git.headTreeSha().catch(() => null);
|
|
3692
3702
|
adaptiveChecked = adaptive.steps.ok ? await (0, compile_check_1.checkCompiledPlan)(adaptive.steps.steps, compileReaders, adaptiveAt) : null;
|
|
@@ -4193,6 +4203,8 @@ async function runLoop(opts) {
|
|
|
4193
4203
|
// just wrote, so it runs inside the boundary with Looply's own runtime
|
|
4194
4204
|
// rather than as the daemon with the machine's.
|
|
4195
4205
|
gateRunner: gateRunnerHere(true),
|
|
4206
|
+
// The workspace packages Looply built here, built again when a round changed them (`workspace-builds.ts`).
|
|
4207
|
+
workspaceBuilds,
|
|
4196
4208
|
// ASKED EVERY ROUND, NEVER CACHED. ~0.6 s against a 45-minute agent
|
|
4197
4209
|
// ceiling, and asking each time is what makes the three-round bound mean
|
|
4198
4210
|
// anything — and what lets a machine that recovers mid-run carry on.
|
|
@@ -4534,14 +4546,27 @@ async function runLoop(opts) {
|
|
|
4534
4546
|
let depsInstalled = false;
|
|
4535
4547
|
const dependenciesBeforeFirstRound = async () => {
|
|
4536
4548
|
const plan = (0, checkout_deps_1.dependencyInstallPlan)(config.gates, (0, checkout_deps_1.checkoutDepsFs)(cwd));
|
|
4537
|
-
if (plan.length
|
|
4538
|
-
|
|
4539
|
-
|
|
4540
|
-
|
|
4541
|
-
|
|
4542
|
-
|
|
4549
|
+
if (plan.length > 0) {
|
|
4550
|
+
const out = await (0, checkout_deps_1.installDependencies)({ plan, runner: (0, untrusted_gate_1.makeUntrustedGateRunner)(cwd, { network: 'internet-client' }), log });
|
|
4551
|
+
if (out.kind === 'failed') {
|
|
4552
|
+
log(`deps : ${out.because}`);
|
|
4553
|
+
return { ok: false, because: out.because };
|
|
4554
|
+
}
|
|
4555
|
+
depsInstalled = out.kind === 'installed';
|
|
4556
|
+
}
|
|
4557
|
+
/**
|
|
4558
|
+
* THEN THE WORKSPACE'S OWN PACKAGES THE CHECKS IMPORT, built when their entry points are not here
|
|
4559
|
+
* (`workspace-builds.ts`): contained and offline, with the gates' own runner. A failed build is a
|
|
4560
|
+
* machine fault the goal waits on, in the build's own words; a base check said without the build
|
|
4561
|
+
* is not reused (`depsInstalled`), exactly as for an install.
|
|
4562
|
+
*/
|
|
4563
|
+
const built = await (0, workspace_builds_1.buildWorkspacePackages)({ plan: (0, workspace_builds_1.workspaceBuildPlan)((0, checkout_deps_1.checkoutDepsFs)(cwd), cwd), runner: (0, untrusted_gate_1.makeUntrustedGateRunner)(cwd), log, checkout: cwd });
|
|
4564
|
+
if (built.kind === 'failed') {
|
|
4565
|
+
log(`build : ${built.because}`);
|
|
4566
|
+
return { ok: false, because: built.because };
|
|
4543
4567
|
}
|
|
4544
|
-
|
|
4568
|
+
if (built.kind === 'built')
|
|
4569
|
+
depsInstalled = true;
|
|
4545
4570
|
return { ok: true };
|
|
4546
4571
|
};
|
|
4547
4572
|
const baseHealthBeforeFirstRound = async () => {
|
|
@@ -5170,4 +5195,13 @@ async function runLoop(opts) {
|
|
|
5170
5195
|
(0, workspace_1.clearCreationMarker)(stateDir);
|
|
5171
5196
|
}
|
|
5172
5197
|
}
|
|
5198
|
+
/**
|
|
5199
|
+
* Who asked for the work a run is bound to (`requestedBy.ref` on its goal), or null — the requester an
|
|
5200
|
+
* account's owners may allow (`provider-accounts.ts`). Read here, in the composition root, so the
|
|
5201
|
+
* account store itself stays goal-blind (`goal-wiring.spec.ts`).
|
|
5202
|
+
*/
|
|
5203
|
+
function requesterRefOf(goal) {
|
|
5204
|
+
const ref = goal?.requestedBy?.ref;
|
|
5205
|
+
return typeof ref === 'string' && ref !== '' ? ref : null;
|
|
5206
|
+
}
|
|
5173
5207
|
//# sourceMappingURL=run-cmd.js.map
|