@outerlayer/cli 0.38.0-next.20261107184816 → 0.38.0-next.20261107193136

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/README.md +4 -1
  2. package/dist/build-info.json +1 -1
  3. package/dist/{check-U5LTHG3N.js → check-YPDK7KPQ.js} +7 -7
  4. package/dist/{chunk-MG5J36XT.js → chunk-6XV37GYV.js} +1 -1
  5. package/dist/{chunk-VB2GEEGY.js → chunk-GRDJ3PIY.js} +1 -1
  6. package/dist/{chunk-BWWLPFL6.js → chunk-GVDNSUP6.js} +6 -2
  7. package/dist/{chunk-QR47L734.js → chunk-LC6UAHZ5.js} +3 -3
  8. package/dist/{chunk-Y7HKHBYK.js → chunk-LOEZWI7V.js} +1 -1
  9. package/dist/{chunk-H5F3LTAS.js → chunk-M6OBO45P.js} +1 -1
  10. package/dist/{chunk-U7OYSE76.js → chunk-VU4VSS7R.js} +1 -1
  11. package/dist/{chunk-JDYNCC66.js → chunk-WINAPU5N.js} +7 -7
  12. package/dist/{cli-PS7XEHDC.js → cli-SOWJUTJL.js} +46 -22
  13. package/dist/{command-FJO564JN.js → command-QAYS7NQK.js} +2 -2
  14. package/dist/{container-start-NXNYBKGN.js → container-start-KWBBXTWK.js} +3 -3
  15. package/dist/{doctor-PEOXISDY.js → doctor-37TRXSNU.js} +3 -3
  16. package/dist/{host-checks-Y2V4GUP5.js → host-checks-PPFAN2OO.js} +1 -1
  17. package/dist/index.js +1 -1
  18. package/dist/{init-RK2HMBNN.js → init-GPGEXBDK.js} +1 -1
  19. package/dist/{init-M3F6ETSQ.js → init-LXVIFOLL.js} +1 -1
  20. package/dist/{init-agent-2HMRPOPQ.js → init-agent-W774Y5K7.js} +1 -1
  21. package/dist/{init-cmd-S7MPELV2.js → init-cmd-K6XA3YVH.js} +1 -1
  22. package/dist/{loop-CV5DU7D5.js → loop-3QPUE7VG.js} +7 -7
  23. package/dist/{machine-NAJDN5YF.js → machine-4M2HLTSH.js} +1 -1
  24. package/dist/{runner-key-N4CFKSI5.js → runner-key-TLJ5TEPF.js} +1 -1
  25. package/dist/{status-FWIMTBJM.js → status-Z67DMNTP.js} +1 -1
  26. package/dist/{update-steps-I7GMX4NB.js → update-steps-IE255NF7.js} +2 -2
  27. package/dist/work-needs-attention-cmd-LUEQZL5I.js +88 -0
  28. package/dist/{work-proofs-cmd-MUGKJWPZ.js → work-proofs-cmd-RTJQ7EJH.js} +1 -1
  29. package/dist/{work-proofs-record-547S7GH6.js → work-proofs-record-6OSVH4BS.js} +1 -1
  30. package/package.json +1 -1
  31. package/skill-pack/maintained/outerlayer-build/SKILL.md +12 -2
package/README.md CHANGED
@@ -95,7 +95,10 @@ content:
95
95
  `POST /v1/work-items/<n>/comments/read` with the build's item key.
96
96
  `outerlayer work no-change` records that the item needs no change. It
97
97
  sends `POST /v1/work-items/<n>/no-change` with the reason and the optional
98
- evidence, and only an item key may call it. `outerlayer work logs`
98
+ evidence, and only an item key may call it. `outerlayer work needs-attention`
99
+ records why a build ends without a pull request. It sends
100
+ `POST /v1/work-items/<n>/needs-attention` with the reason, and only an item
101
+ key may call it. `outerlayer work logs`
99
102
  reads the runner's log for a host attempt. `outerlayer work demo` reads an
100
103
  item's newest demo record with `GET /v1/work-items/<n>/demo`.
101
104
  `outerlayer work proofs` reads the item with `GET /v1/work-items/<n>` and
@@ -1 +1 @@
1
- {"id":"2026-11-07T18:55:00.762Z","root":"/home/runner/work/outerlayer/outerlayer","pkg":"outerlayer"}
1
+ {"id":"2026-11-07T19:38:34.380Z","root":"/home/runner/work/outerlayer/outerlayer","pkg":"outerlayer"}
@@ -1,18 +1,18 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { probeCredentials } from './chunk-JDYNCC66.js';
4
- import './chunk-Y7HKHBYK.js';
3
+ import { probeCredentials } from './chunk-WINAPU5N.js';
4
+ import './chunk-3JVYMD4G.js';
5
+ import './chunk-LOEZWI7V.js';
6
+ import './chunk-E7R2GIAW.js';
5
7
  import './chunk-T66LOXZB.js';
6
8
  import './chunk-OGG5VWEZ.js';
7
- import './chunk-H5F3LTAS.js';
9
+ import './chunk-M6OBO45P.js';
8
10
  import './chunk-TZUHKFC6.js';
9
- import './chunk-3JVYMD4G.js';
10
- import './chunk-E7R2GIAW.js';
11
11
  import './chunk-MLM4BYK2.js';
12
- import { fleetConfigProblem, managedProblems, managedFactsOf, askFleetMachine } from './chunk-U7OYSE76.js';
12
+ import { fleetConfigProblem, managedProblems, managedFactsOf, askFleetMachine } from './chunk-VU4VSS7R.js';
13
13
  import './chunk-7XKAPGFQ.js';
14
14
  import { findServiceUnit } from './chunk-JBEGQDZH.js';
15
- import { placeholderQueues, placeholderProblem, permissionModeProblems, permissionModeProblem, HELPER_ENV, helperSocketPath, probeHelper, needsAgentCredential, agentCredentialCheck, claimPermissionProblem, formerSkillQueues, modellessQueues, formerSkillProblem, modellessProblem } from './chunk-BWWLPFL6.js';
15
+ import { placeholderQueues, placeholderProblem, permissionModeProblems, permissionModeProblem, HELPER_ENV, helperSocketPath, probeHelper, needsAgentCredential, agentCredentialCheck, claimPermissionProblem, formerSkillQueues, modellessQueues, formerSkillProblem, modellessProblem } from './chunk-GVDNSUP6.js';
16
16
  import './chunk-M6LQSXFY.js';
17
17
  import './chunk-2PGI6RDE.js';
18
18
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { helperSocketPath } from './chunk-BWWLPFL6.js';
3
+ import { helperSocketPath } from './chunk-GVDNSUP6.js';
4
4
  import { UNIT_MARKER } from './chunk-EUMGKMIV.js';
5
5
  import { runnerDir } from './chunk-EWDSVOX3.js';
6
6
  import { createHash } from 'crypto';
@@ -1080,7 +1080,7 @@ async function gatherDoctorChecks(options = {}) {
1080
1080
  const { runnerVmCheck } = await import('./doctor-53F2PYY7.js');
1081
1081
  checks.push(runnerVmCheck(configPath, { lima: realLima(), home: homeFromEnv(), instance: runnerVm.instance }));
1082
1082
  } else if (hasRunnerBlock(configPath)) {
1083
- const { runnerHostChecks } = await import('./doctor-PEOXISDY.js');
1083
+ const { runnerHostChecks } = await import('./doctor-37TRXSNU.js');
1084
1084
  const gateway = (() => {
1085
1085
  try {
1086
1086
  const loaded = loadRunnerConfig(configPath);
@@ -1488,7 +1488,9 @@ async function readItemEvaluation(config, item, fetchImpl, claimId) {
1488
1488
  const hasPullRequest = Array.isArray(body.pullRequests) ? body.pullRequests.length > 0 : void 0;
1489
1489
  const noChangeClaim = fields(body.noChange).claimId;
1490
1490
  const noChangeRecorded = claimId !== void 0 && typeof noChangeClaim === "string" && noChangeClaim === claimId;
1491
- return { ok: true, evaluation: parseEvaluation(body.evaluation, body.checks), hasPullRequest, noChangeRecorded };
1491
+ const attention = fields(body.needsAttention);
1492
+ const attentionReason = claimId !== void 0 && attention.claimId === claimId && typeof attention.reason === "string" && attention.reason !== "" ? attention.reason : void 0;
1493
+ return { ok: true, evaluation: parseEvaluation(body.evaluation, body.checks), hasPullRequest, noChangeRecorded, attentionReason };
1492
1494
  } catch (err) {
1493
1495
  return { ok: false, reason: describeCallFailure(err) };
1494
1496
  }
@@ -1512,6 +1514,7 @@ function decideFromEvaluation(read) {
1512
1514
  if (!read.ok) return { outcome: "incomplete", reason: fit("the item's status could not be read: ", [read.reason]) };
1513
1515
  if (read.noChangeRecorded === true && read.hasPullRequest !== true) return { outcome: "ok" };
1514
1516
  if (read.hasPullRequest === false) {
1517
+ if (read.attentionReason !== void 0) return { outcome: "incomplete", reason: read.attentionReason, agentReason: true };
1515
1518
  return { outcome: "incomplete", reason: "the build opened no pull request for the item" };
1516
1519
  }
1517
1520
  const evaluation = read.evaluation;
@@ -9015,7 +9018,8 @@ async function finishJob(job, jobDirPath, outcome, config, deps, ending) {
9015
9018
  });
9016
9019
  if (decision.outcome === "incomplete") {
9017
9020
  const release2 = unfinishedRelease(
9018
- scrubReason(incompleteReason(decision.reason, job.judgeNotRun), config, void 0, jobDirPath),
9021
+ // The judge prefix would push the agent's sentence past the release's bound, and the judge has nothing to judge without a pull request.
9022
+ scrubReason(decision.agentReason === true ? decision.reason : incompleteReason(decision.reason, job.judgeNotRun), config, void 0, jobDirPath),
9019
9023
  deps.container?.credentials.get(jobDirPath)?.reason
9020
9024
  );
9021
9025
  outcome = release2.outcome;
@@ -129,14 +129,14 @@ function governingDir(cwd) {
129
129
  async function testProofMode(cwd) {
130
130
  const dir = governingDir(cwd);
131
131
  if (dir === void 0) return "any";
132
- const { testProofIn } = await import('./host-checks-Y2V4GUP5.js');
132
+ const { testProofIn } = await import('./host-checks-PPFAN2OO.js');
133
133
  return testProofIn(dir);
134
134
  }
135
135
  async function judgeCheckName(cwd) {
136
136
  const dir = governingDir(cwd);
137
137
  if (dir === void 0) return {};
138
138
  if (!existsSync(dir)) return { note: `the governed context at ${dir} is not readable` };
139
- const { checksIn, isJudgeCheck } = await import('./host-checks-Y2V4GUP5.js');
139
+ const { checksIn, isJudgeCheck } = await import('./host-checks-PPFAN2OO.js');
140
140
  const quiet = { line: () => void 0, error: () => void 0 };
141
141
  const check = checksIn(dir, quiet, "").checks.find((c) => isJudgeCheck(c) && c.judge.subjects === "criteria");
142
142
  return check === void 0 ? {} : { name: check.name };
@@ -372,7 +372,7 @@ async function runWorkProofs(opts) {
372
372
  async function runWorkProofsCommand(opts) {
373
373
  try {
374
374
  if (opts.record) {
375
- const { runWorkProofsRecord } = await import('./work-proofs-record-547S7GH6.js');
375
+ const { runWorkProofsRecord } = await import('./work-proofs-record-6OSVH4BS.js');
376
376
  const result2 = await runWorkProofsRecord(opts);
377
377
  process.exitCode = result2.exitCode;
378
378
  return;
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { scrubReason, stripTerminalControls } from './chunk-BWWLPFL6.js';
3
+ import { scrubReason, stripTerminalControls } from './chunk-GVDNSUP6.js';
4
4
  import { checkFit, RUNNER_RESERVE_BYTES } from './chunk-EUMGKMIV.js';
5
5
  import { RunnerAlreadyRunningError, readPidFile } from './chunk-3TRMPCCI.js';
6
6
  import { isSameProcess } from './chunk-JBJTC3UU.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { stripTerminalControls } from './chunk-BWWLPFL6.js';
3
+ import { stripTerminalControls } from './chunk-GVDNSUP6.js';
4
4
  import { tagToPull, imageTag, pullInstruction, readUpdateStatus, runnerImageVersion } from './chunk-PWVYGW2V.js';
5
5
  import { readFileSync } from 'fs';
6
6
 
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { placeholderQueues, placeholderProblem } from './chunk-BWWLPFL6.js';
3
+ import { placeholderQueues, placeholderProblem } from './chunk-GVDNSUP6.js';
4
4
  import { checkFit, RUNNER_RESERVE_BYTES } from './chunk-EUMGKMIV.js';
5
5
  import { getJson, WorkCommandError } from './chunk-7UEW7HXC.js';
6
6
  import { isBuiltinVm, builtinKind, EGRESS_SWITCHABLE_KEYS, imageBuildOf, keepsHostBuilder } from './chunk-AZDDIZDE.js';
@@ -1,16 +1,16 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { reportFailedStart, fitImageBuildMemory } from './chunk-Y7HKHBYK.js';
3
+ import { decideInstalledSwitch } from './chunk-3JVYMD4G.js';
4
+ import { reportFailedStart, fitImageBuildMemory } from './chunk-LOEZWI7V.js';
5
+ import { fetchVersionMeta, npmVersion, npmSupportsProvenance, fetchTarballDigest, fetchProvenance, installVersion, auditSignatures } from './chunk-E7R2GIAW.js';
4
6
  import { writeFleetState } from './chunk-T66LOXZB.js';
5
7
  import { writePendingUpdate } from './chunk-OGG5VWEZ.js';
6
- import { renderUpdateSteps } from './chunk-H5F3LTAS.js';
8
+ import { renderUpdateSteps } from './chunk-M6OBO45P.js';
7
9
  import { readHousekeepingRecord, writeHousekeepingRecord } from './chunk-TZUHKFC6.js';
8
- import { decideInstalledSwitch } from './chunk-3JVYMD4G.js';
9
- import { fetchVersionMeta, npmVersion, npmSupportsProvenance, fetchTarballDigest, fetchProvenance, installVersion, auditSignatures } from './chunk-E7R2GIAW.js';
10
10
  import { RUNNER_PROTOCOL } from './chunk-MLM4BYK2.js';
11
- import { fleetConfigProblem, realBlockedProbes, sliceMemoryOf, checkBlockedWithSlots, largeBuildMemoryBytes, LARGE_BUILD_DISK_BYTES, checkManagedRoom, askFleetMachine } from './chunk-U7OYSE76.js';
11
+ import { fleetConfigProblem, realBlockedProbes, sliceMemoryOf, checkBlockedWithSlots, largeBuildMemoryBytes, LARGE_BUILD_DISK_BYTES, checkManagedRoom, askFleetMachine } from './chunk-VU4VSS7R.js';
12
12
  import { writeMarker, readMarker, currentVersion, removeMarker, isInLayout, startedThroughCurrent, entryIn, versionDir, switchCurrent, cleanVersions, stagingDir } from './chunk-7XKAPGFQ.js';
13
- import { leaseTimeLeftMs, createContainerRuntime, withTunnelLog, releaseLease, LEASE_SECONDS, itemTag, isUnfinished, prepareResume, restoreSessionIntoMicroVm, restoreSessionIntoContainer, itemScope, attemptNote, fetchManagedClaudeKey, holdManagedClaudeKey, fetchManagedBuildSettings, holdManagedBuildSettings, setStage, jobEnv, runHook, describeHookEnd, needsBuildSkill, provisionContainer, leaseExpiresAtMs, deliverContainerHooks, provisionSandbox, deliverSandboxHooks, provisionMicroVm, deliverCommitHooks, provisionEnvironment, readProvisionOut, resolveHostBuild, workdirProblem, listenOnBroker, hostEnvironment, deliverExecMaven, runWithSpawn, hostCommandEnvironment, lifecycleSteps, execArgv, lifecycleFailureReason, decideHostBuildSkill, prepareBranch, keptCommitsLine, currentSkillCommand, formerSkillProblem, commandLogOffset, startSandboxCommand, MICROVM_COMMAND_DIR, startMicroVmCommand, microVmCommandLine, runCommand, containerCommandExec, execCommandLine, startSender, startHostServices, finishJob, sampleGuest, foldSample, isSandboxTracked, isContainerTracked, isMicroVmTracked, probeSandboxCommand, probeMicroVmCommand, probeCommand, appendCommandLog, judgeProbe, SandboxGoneError, EXIT_CODE_FILE, isTracked, isGroupAlive, outcomeFromExitCode, isIsolatedJob, isTimedOut, readCpuUsec, isIdle, HELPER_ENV, setUpRunnerCgroup, stopOrphanedMicroVms, unfinishedJobs, sweepImageBuilders, listUnreadableJobs, listAdoptableJobs, retryFailedReleases, recoverLostJobs, GUEST_USAGE_INTERVAL_MS, listItemDisks, usableCpus, hookLimitsFor, AttemptLogBook, microVmOomKills, needsRenew, renewLease, RENEW_INTERVAL_SECONDS, stoppedHelperReason, measureDisk, listTrackedJobs, sweepSandboxes, parseCpuList, ensureTunnel, keepGhConfigCurrent, filesAreCopied, restartSender, createHousekeepingDocker, housekeepingDockerIfReachable, runHousekeeping, jobRecordsClaim, freeItemDisksUntil, savedStatesDir, readRecords, removeOldestUntil, ensureNetworkReady, managedBuildSettingsFor, ADOPTED_FETCH_RETRY_WINDOW_MS, gitRemoteFor, startServicesFor, installTrust, createLeaseChannel, serveLease, vmAlive, writeGuestGhConfig, shellQuote, deliverJobFiles, inTeardown } from './chunk-BWWLPFL6.js';
13
+ import { leaseTimeLeftMs, createContainerRuntime, withTunnelLog, releaseLease, LEASE_SECONDS, itemTag, isUnfinished, prepareResume, restoreSessionIntoMicroVm, restoreSessionIntoContainer, itemScope, attemptNote, fetchManagedClaudeKey, holdManagedClaudeKey, fetchManagedBuildSettings, holdManagedBuildSettings, setStage, jobEnv, runHook, describeHookEnd, needsBuildSkill, provisionContainer, leaseExpiresAtMs, deliverContainerHooks, provisionSandbox, deliverSandboxHooks, provisionMicroVm, deliverCommitHooks, provisionEnvironment, readProvisionOut, resolveHostBuild, workdirProblem, listenOnBroker, hostEnvironment, deliverExecMaven, runWithSpawn, hostCommandEnvironment, lifecycleSteps, execArgv, lifecycleFailureReason, decideHostBuildSkill, prepareBranch, keptCommitsLine, currentSkillCommand, formerSkillProblem, commandLogOffset, startSandboxCommand, MICROVM_COMMAND_DIR, startMicroVmCommand, microVmCommandLine, runCommand, containerCommandExec, execCommandLine, startSender, startHostServices, finishJob, sampleGuest, foldSample, isSandboxTracked, isContainerTracked, isMicroVmTracked, probeSandboxCommand, probeMicroVmCommand, probeCommand, appendCommandLog, judgeProbe, SandboxGoneError, EXIT_CODE_FILE, isTracked, isGroupAlive, outcomeFromExitCode, isIsolatedJob, isTimedOut, readCpuUsec, isIdle, HELPER_ENV, setUpRunnerCgroup, stopOrphanedMicroVms, unfinishedJobs, sweepImageBuilders, listUnreadableJobs, listAdoptableJobs, retryFailedReleases, recoverLostJobs, GUEST_USAGE_INTERVAL_MS, listItemDisks, usableCpus, hookLimitsFor, AttemptLogBook, microVmOomKills, needsRenew, renewLease, RENEW_INTERVAL_SECONDS, stoppedHelperReason, measureDisk, listTrackedJobs, sweepSandboxes, parseCpuList, ensureTunnel, keepGhConfigCurrent, filesAreCopied, restartSender, createHousekeepingDocker, housekeepingDockerIfReachable, runHousekeeping, jobRecordsClaim, freeItemDisksUntil, savedStatesDir, readRecords, removeOldestUntil, ensureNetworkReady, managedBuildSettingsFor, ADOPTED_FETCH_RETRY_WINDOW_MS, gitRemoteFor, startServicesFor, installTrust, createLeaseChannel, serveLease, vmAlive, writeGuestGhConfig, shellQuote, deliverJobFiles, inTeardown } from './chunk-GVDNSUP6.js';
14
14
  import { RUNNER_RESERVE_BYTES } from './chunk-EUMGKMIV.js';
15
15
  import { RepoFilter } from './chunk-XAYMVIQY.js';
16
16
  import { JOB_STATE_FORMAT, readsJobState, jobStateFormatOf } from './chunk-ZVB57WI6.js';
@@ -3766,7 +3766,7 @@ async function startRunner(configPath, deps, startup) {
3766
3766
  check: update.check ? () => update.check(configPath) : async () => {
3767
3767
  const held = runnerAgents(deps.agents).flatMap((agent) => heldAgentCredential(agent.descriptor.id) ?? []);
3768
3768
  const env = { ...process.env, ...Object.fromEntries(held.map((credential) => [credential.variable, credential.value])) };
3769
- return (await import('./check-U5LTHG3N.js')).runRunnerCheck(configPath, { fetchImpl: deps.fetchImpl, env });
3769
+ return (await import('./check-YPDK7KPQ.js')).runRunnerCheck(configPath, { fetchImpl: deps.fetchImpl, env });
3770
3770
  },
3771
3771
  now: () => (deps.now ?? (() => /* @__PURE__ */ new Date()))().getTime(),
3772
3772
  log
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { gatherDoctorChecks, doctorExitCode, summarizeChecks, renderDoctorText, recordWrapped, recordUnwrapped, recordRemoval, readManifest, recordInstall, recordStatusline } from './chunk-VB2GEEGY.js';
3
+ import { gatherDoctorChecks, doctorExitCode, summarizeChecks, renderDoctorText, recordWrapped, recordUnwrapped, recordRemoval, readManifest, recordInstall, recordStatusline } from './chunk-GRDJ3PIY.js';
4
4
  import './chunk-PY3KCLWJ.js';
5
5
  import { verifiedTrackerNames, TRACKERS } from './chunk-7UEW7HXC.js';
6
6
  import './chunk-4VL4HT6D.js';
@@ -3944,13 +3944,13 @@ what CLIs older than ${FIRST_VERSION_READING_AGENTS_SKILLS} do. \`` + cliInvocat
3944
3944
  if (changed.length > 0 && !opts.json) process.stdout.write(`Removed the claude function from ${changed.join(", ")}.
3945
3945
  `);
3946
3946
  }
3947
- const shell = !opts.remove && opts.shellFunction !== void 0 ? (await import('./init-cmd-S7MPELV2.js')).applyShellFunctionFlag(opts.shellFunction, { home: homeFromEnv(), shellPath: process.env.SHELL }) : void 0;
3947
+ const shell = !opts.remove && opts.shellFunction !== void 0 ? (await import('./init-cmd-K6XA3YVH.js')).applyShellFunctionFlag(opts.shellFunction, { home: homeFromEnv(), shellPath: process.env.SHELL }) : void 0;
3948
3948
  if (opts.json) writeJson(shell === void 0 ? outcome.result : { ...outcome.result, shellFunction: { outcome: shell.outcome, reason: shell.reason } });
3949
3949
  else process.stdout.write(outcome.text + skillsLine + (shell?.text ?? ""));
3950
3950
  return;
3951
3951
  }
3952
3952
  await installMachineSkillsForSetup();
3953
- const { runInitCommand } = await import('./init-cmd-S7MPELV2.js');
3953
+ const { runInitCommand } = await import('./init-cmd-K6XA3YVH.js');
3954
3954
  const code = await runInitCommand(
3955
3955
  { json: opts.json, factory: opts.factory, shellFunction: opts.shellFunction },
3956
3956
  {
@@ -5057,7 +5057,7 @@ stops at once if a tracked file differs from HEAD.
5057
5057
  fail(trackerNumberError("--pr", opts.pr));
5058
5058
  return;
5059
5059
  }
5060
- const { runWorkProofsCommand } = await import('./work-proofs-cmd-MUGKJWPZ.js');
5060
+ const { runWorkProofsCommand } = await import('./work-proofs-cmd-RTJQ7EJH.js');
5061
5061
  await runWorkProofsCommand({ ...opts, ...pr === void 0 ? {} : { pr } });
5062
5062
  });
5063
5063
  workCmd.command("list").description("List live work items for this factory").option("--stage <spec|build|review>", "filter by stage").option("--section <attention|waiting|flowing>", "filter by Queue section").option("--repo <owner/name>", "repository (default: the current checkout's remote)").option("--unclaimed", "only items with no live lease").option("--claimed", "only items with a live lease, held by a host or a local session").option("--startable", "only items a host can start: a build request, no open PR, no live lease").option("--needs <amend>", "only items with a thread waiting on an agent").option("--json", "machine-readable JSON output").option("--url <url>", "cloud base URL (or OUTERLAYER_URL / config)").addOption(apiKeyOption()).option("--app-id <id>", "factory id the key is bound to (or OUTERLAYER_APP_ID / config)").action(async (opts) => {
@@ -5222,6 +5222,30 @@ holds an item key, can run it.
5222
5222
  throw err;
5223
5223
  }
5224
5224
  });
5225
+ workCmd.command("needs-attention").description("Record why this build ends without a pull request").option("--reason <text>", "why the build stopped and what a person can do; at most 200 characters").option("--json", "machine-readable JSON output").option("--url <url>", "cloud base URL (or OUTERLAYER_URL / config)").addOption(apiKeyOption()).option("--app-id <id>", "factory id the key is bound to (or OUTERLAYER_APP_ID / config)").addHelpText(
5226
+ "after",
5227
+ `
5228
+ ${cliInvocation()} work needs-attention --reason "The tests need STRIPE_KEY. Add it as a build variable."
5229
+
5230
+ Run it before a build ends without a pull request, and say what stopped
5231
+ the build and what a person can do. The Work page and the Activity tab show
5232
+ your sentence as the reason the item needs attention. Do not run it after you
5233
+ record that no change is needed. Only a host build, which holds an item key,
5234
+ can run it.
5235
+ `
5236
+ ).action(async (opts) => {
5237
+ const { runWorkNeedsAttention, WorkNeedsAttentionCommandError } = await import('./work-needs-attention-cmd-LUEQZL5I.js');
5238
+ const { WorkCommandError } = await import('./work-cmd-QLCNL3HL.js');
5239
+ try {
5240
+ await runWorkNeedsAttention(opts);
5241
+ } catch (err) {
5242
+ if (err instanceof WorkNeedsAttentionCommandError || err instanceof WorkCommandError) {
5243
+ fail(err.message);
5244
+ return;
5245
+ }
5246
+ throw err;
5247
+ }
5248
+ });
5225
5249
  }
5226
5250
  function runnerHelpWords() {
5227
5251
  const agent = credentialAgent();
@@ -5256,7 +5280,7 @@ function registerRunnerCommands(program2) {
5256
5280
  const configOption = "the cloud config file to run against (default: ~/.outerlayer/config.json)";
5257
5281
  runnerCmd.command("start").description("Run the loop: claim work, run it, report, clean up, repeat").option("--config <path>", configOption).action(async (opts) => {
5258
5282
  const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-K5477PLJ.js');
5259
- const { start, RunnerStartError } = await import('./loop-CV5DU7D5.js');
5283
+ const { start, RunnerStartError } = await import('./loop-3QPUE7VG.js');
5260
5284
  const { RunnerAlreadyRunningError } = await import('./pidfile-5L3BHW44.js');
5261
5285
  const configPath = opts.config ?? defaultRunnerConfigPath();
5262
5286
  try {
@@ -5280,8 +5304,8 @@ The image sets OUTERLAYER_RUNNER_IMAGE; outside the image, use \`runner start\`.
5280
5304
  `
5281
5305
  ).action(async () => {
5282
5306
  const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-K5477PLJ.js');
5283
- const { containerStart, containerStartExit } = await import('./container-start-NXNYBKGN.js');
5284
- const { start, RunnerStartError } = await import('./loop-CV5DU7D5.js');
5307
+ const { containerStart, containerStartExit } = await import('./container-start-KWBBXTWK.js');
5308
+ const { start, RunnerStartError } = await import('./loop-3QPUE7VG.js');
5285
5309
  const { RunnerAlreadyRunningError } = await import('./pidfile-5L3BHW44.js');
5286
5310
  try {
5287
5311
  const outcome = containerStartExit(await containerStart({
@@ -5305,14 +5329,14 @@ The image sets OUTERLAYER_RUNNER_IMAGE; outside the image, use \`runner start\`.
5305
5329
  ).action(async (opts) => {
5306
5330
  const { defaultRunnerConfigPath } = await import('./config-K5477PLJ.js');
5307
5331
  const { runnerDir } = await import('./paths-JK5BDRCA.js');
5308
- const { runUpdateSteps } = await import('./update-steps-I7GMX4NB.js');
5332
+ const { runUpdateSteps } = await import('./update-steps-IE255NF7.js');
5309
5333
  const text = await runUpdateSteps({ runnerDirPath: runnerDir(opts.config ?? defaultRunnerConfigPath()) });
5310
5334
  process.stdout.write(`${text}
5311
5335
  `);
5312
5336
  });
5313
5337
  runnerCmd.command("check").description("Validate the config, the hooks and the key, and print the effective settings").option("--config <path>", configOption).action(async (opts) => {
5314
5338
  const { defaultRunnerConfigPath } = await import('./config-K5477PLJ.js');
5315
- const { runRunnerCheck } = await import('./check-U5LTHG3N.js');
5339
+ const { runRunnerCheck } = await import('./check-YPDK7KPQ.js');
5316
5340
  const configPath = opts.config ?? defaultRunnerConfigPath();
5317
5341
  const result = await runRunnerCheck(configPath);
5318
5342
  if (!result.ok) {
@@ -5346,13 +5370,13 @@ The image sets OUTERLAYER_RUNNER_IMAGE; outside the image, use \`runner start\`.
5346
5370
  }
5347
5371
  }
5348
5372
  const buildCpusMax = opts.buildCpusMax === void 0 ? void 0 : Number(opts.buildCpusMax);
5349
- if (buildCpusMax !== void 0 && !(await import('./command-FJO564JN.js')).cpusAreValid(buildCpusMax)) {
5373
+ if (buildCpusMax !== void 0 && !(await import('./command-QAYS7NQK.js')).cpusAreValid(buildCpusMax)) {
5350
5374
  fail(`--build-cpus-max ${opts.buildCpusMax} is not a number of CPUs from 0.01 to 1024.`);
5351
5375
  return;
5352
5376
  }
5353
5377
  try {
5354
5378
  if (opts.service === true) {
5355
- const { installServiceCommand, serviceSuccessText } = await import('./command-FJO564JN.js');
5379
+ const { installServiceCommand, serviceSuccessText } = await import('./command-QAYS7NQK.js');
5356
5380
  const result2 = await installServiceCommand({
5357
5381
  configPath,
5358
5382
  print: opts.print,
@@ -5407,7 +5431,7 @@ To keep it running, run ${C.yellow}${cliInvocation()} runner install --service${
5407
5431
  return;
5408
5432
  }
5409
5433
  const { defaultRunnerConfigPath } = await import('./config-K5477PLJ.js');
5410
- const { uninstallServiceCommand } = await import('./command-FJO564JN.js');
5434
+ const { uninstallServiceCommand } = await import('./command-QAYS7NQK.js');
5411
5435
  const result = await uninstallServiceCommand({ configPath: opts.config ?? defaultRunnerConfigPath(), unitName: opts.unitName, home: homeFromEnv() });
5412
5436
  if (result.ok) for (const line of result.lines) process.stdout.write(`${C.green}\u2713${C.reset} ${line}
5413
5437
  `);
@@ -5438,10 +5462,10 @@ already in ${words().envFile} is used.
5438
5462
  `
5439
5463
  ).action(async (opts) => {
5440
5464
  const { defaultRunnerConfigPath, RunnerConfigError } = await import('./config-K5477PLJ.js');
5441
- const { prepareRunnerInit, runRunnerInit, RunnerInitError, writeRunnerInit } = await import('./init-M3F6ETSQ.js');
5442
- const { obtainRunnerKey, runnerKeyLogin } = await import('./runner-key-N4CFKSI5.js');
5443
- const { detectMachine } = await import('./machine-NAJDN5YF.js');
5444
- const { chooseVm, runVmInit, VmInitError } = await import('./init-RK2HMBNN.js');
5465
+ const { prepareRunnerInit, runRunnerInit, RunnerInitError, writeRunnerInit } = await import('./init-LXVIFOLL.js');
5466
+ const { obtainRunnerKey, runnerKeyLogin } = await import('./runner-key-TLJ5TEPF.js');
5467
+ const { detectMachine } = await import('./machine-4M2HLTSH.js');
5468
+ const { chooseVm, runVmInit, VmInitError } = await import('./init-GPGEXBDK.js');
5445
5469
  const { credentialFromStdin, isAgentName, restartForCredential, RunnerEnvError } = await import('./runner-env-ORVI32Q5.js');
5446
5470
  const { headlessNames: headlessNames2 } = await import('./runner-agents-MMDKTRAS.js');
5447
5471
  const configPath = opts.config ?? defaultRunnerConfigPath();
@@ -5455,7 +5479,7 @@ already in ${words().envFile} is used.
5455
5479
  return;
5456
5480
  }
5457
5481
  try {
5458
- const { agentCredentialText, credentialQuestion, initAgent, terminalQuestion } = await import('./init-agent-2HMRPOPQ.js');
5482
+ const { agentCredentialText, credentialQuestion, initAgent, terminalQuestion } = await import('./init-agent-W774Y5K7.js');
5459
5483
  agent = await initAgent({
5460
5484
  flag: agent,
5461
5485
  handOff: opts.configStdin === true,
@@ -5595,7 +5619,7 @@ ${C.yellow}The runner will not update itself: ${installErr.message}${C.reset}
5595
5619
  let serviceUp = false;
5596
5620
  let restart;
5597
5621
  if (installedLayout) {
5598
- const { installServiceCommand } = await import('./command-FJO564JN.js');
5622
+ const { installServiceCommand } = await import('./command-QAYS7NQK.js');
5599
5623
  const service = await installServiceCommand({
5600
5624
  configPath,
5601
5625
  entryPath: process.argv[1] ?? "",
@@ -5733,7 +5757,7 @@ A repository with no devcontainer file builds on the universal image the CLI pin
5733
5757
  });
5734
5758
  runnerCmd.command("stop").description("Take no more work; finish running jobs, then exit").option("--config <path>", "the cloud config file naming the runner to stop").option("--now", "end running jobs immediately, with outcome stopped").action(async (opts) => {
5735
5759
  const { defaultRunnerConfigPath } = await import('./config-K5477PLJ.js');
5736
- const { requestStop } = await import('./loop-CV5DU7D5.js');
5760
+ const { requestStop } = await import('./loop-3QPUE7VG.js');
5737
5761
  const configPath = opts.config ?? defaultRunnerConfigPath();
5738
5762
  const { runnerImageVersion } = await import('./image-tag-2WKQHVAX.js');
5739
5763
  await requestStop(configPath, Boolean(opts.now), void 0, { image: runnerImageVersion() !== void 0 });
@@ -5741,8 +5765,8 @@ A repository with no devcontainer file builds on the universal image the CLI pin
5741
5765
  runnerCmd.command("status").description("List running jobs; with --recent, finished ones too").option("--config <path>", "the cloud config file naming the runner to inspect").option("--recent", "also list finished jobs, newest first, capped at 20").option("--json", "machine-readable JSON output").action(async (opts) => {
5742
5766
  const { defaultRunnerConfigPath, loadRunnerConfig } = await import('./config-K5477PLJ.js');
5743
5767
  const { jobsDir, runnerDir } = await import('./paths-JK5BDRCA.js');
5744
- const { listJobFiles, runnerProcessState } = await import('./loop-CV5DU7D5.js');
5745
- const { renderStatus } = await import('./status-FWIMTBJM.js');
5768
+ const { listJobFiles, runnerProcessState } = await import('./loop-3QPUE7VG.js');
5769
+ const { renderStatus } = await import('./status-Z67DMNTP.js');
5746
5770
  const { readHousekeepingRecord } = await import('./record-4CSZUOA5.js');
5747
5771
  const path2 = await import('path');
5748
5772
  const configPath = opts.config ?? defaultRunnerConfigPath();
@@ -5808,7 +5832,7 @@ A repository with no devcontainer file builds on the universal image the CLI pin
5808
5832
  });
5809
5833
  runnerCmd.command("logs").argument("<item>", "the work item's number in the factory, or a build's claim id").description("Print the newest attempt's log for one item or claim id").option("--config <path>", "the cloud config file naming the runner to inspect").option("-f, --follow", "keep printing as the log grows").action(async (itemArg, opts) => {
5810
5834
  const { defaultRunnerConfigPath } = await import('./config-K5477PLJ.js');
5811
- const { listJobFiles } = await import('./loop-CV5DU7D5.js');
5835
+ const { listJobFiles } = await import('./loop-3QPUE7VG.js');
5812
5836
  const { describeAmbiguous, logPathFor, selectAttempt, tail, RunnerLogsError } = await import('./logs-HOMZHA2J.js');
5813
5837
  const configPath = opts.config ?? defaultRunnerConfigPath();
5814
5838
  const jobs = listJobFiles(configPath);
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
3
  import { realOwnership, accountNamed, handOver, runRunnerInstall, launcherSummary, restartNote, accountIdentity } from './chunk-DZPG7FOP.js';
4
- import { installHelper, helperUnitFor, helperSocketFor, uninstallHelper } from './chunk-MG5J36XT.js';
4
+ import { installHelper, helperUnitFor, helperSocketFor, uninstallHelper } from './chunk-6XV37GYV.js';
5
5
  import './chunk-HYUO2OKW.js';
6
6
  import { currentLink, execStartCommand } from './chunk-7XKAPGFQ.js';
7
- import { detectMachine, ensureFirecrackerAndJailer } from './chunk-BWWLPFL6.js';
7
+ import { detectMachine, ensureFirecrackerAndJailer } from './chunk-GVDNSUP6.js';
8
8
  import './chunk-M6LQSXFY.js';
9
9
  import './chunk-2PGI6RDE.js';
10
10
  import './chunk-I3LTIAOR.js';
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { reportFailedStart, BUILD_MEMORY_VARIABLE } from './chunk-Y7HKHBYK.js';
4
- import { readOwnContainer } from './chunk-H5F3LTAS.js';
5
- import { detectMachine, supportsContainerBuilds, MIN_ENGINE_MAJOR, describeMachineDocker, RunnerInitError, prepareRunnerInit, writeRunnerInit } from './chunk-BWWLPFL6.js';
3
+ import { reportFailedStart, BUILD_MEMORY_VARIABLE } from './chunk-LOEZWI7V.js';
4
+ import { readOwnContainer } from './chunk-M6OBO45P.js';
5
+ import { detectMachine, supportsContainerBuilds, MIN_ENGINE_MAJOR, describeMachineDocker, RunnerInitError, prepareRunnerInit, writeRunnerInit } from './chunk-GVDNSUP6.js';
6
6
  import './chunk-M6LQSXFY.js';
7
7
  import './chunk-2PGI6RDE.js';
8
8
  import './chunk-I3LTIAOR.js';
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { helperBinaryFor } from './chunk-MG5J36XT.js';
3
+ import { helperBinaryFor } from './chunk-6XV37GYV.js';
4
4
  import { launcherCheck } from './chunk-HYUO2OKW.js';
5
- import { managedProblems, fleetConfigProblem, askFleetMachine } from './chunk-U7OYSE76.js';
5
+ import { managedProblems, fleetConfigProblem, askFleetMachine } from './chunk-VU4VSS7R.js';
6
6
  import './chunk-7XKAPGFQ.js';
7
- import { needsAgentCredential, agentCredentialCheck, detectMachine, supportsContainerBuilds, describeMachineDocker, MIN_ENGINE_MAJOR, reachDockerStep, supportsMicroVmBuilds, microVmArchSupported, microVmAssetsPinned, helperFirecrackerNote, probeHelper, helperSocketPath, KIND_LABEL, missingPermissionOf, missingPermissionFix } from './chunk-BWWLPFL6.js';
7
+ import { needsAgentCredential, agentCredentialCheck, detectMachine, supportsContainerBuilds, describeMachineDocker, MIN_ENGINE_MAJOR, reachDockerStep, supportsMicroVmBuilds, microVmArchSupported, microVmAssetsPinned, helperFirecrackerNote, probeHelper, helperSocketPath, KIND_LABEL, missingPermissionOf, missingPermissionFix } from './chunk-GVDNSUP6.js';
8
8
  import './chunk-M6LQSXFY.js';
9
9
  import './chunk-2PGI6RDE.js';
10
10
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { CRITERIA_CHECK, MAX_CHECK_ITEMS_BYTES, checksIn, commandItems, isJudgeCheck, makeRecorder, readDefinitions, runHostChecks, testProofIn, timeoutAfter } from './chunk-BWWLPFL6.js';
3
+ export { CRITERIA_CHECK, MAX_CHECK_ITEMS_BYTES, checksIn, commandItems, isJudgeCheck, makeRecorder, readDefinitions, runHostChecks, testProofIn, timeoutAfter } from './chunk-GVDNSUP6.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-2PGI6RDE.js';
6
6
  import './chunk-I3LTIAOR.js';
package/dist/index.js CHANGED
@@ -25,5 +25,5 @@ var { runSubcommand } = await import('./agent-subcommand-YCRAD3QN.js');
25
25
  var launcherCode = await runSubcommand(argv);
26
26
  if (launcherCode !== void 0) process.exit(launcherCode);
27
27
  (await import('./hook-fast-B4SR6P4L.js')).recordLinkExitFailure(argv);
28
- var { runCli } = await import('./cli-PS7XEHDC.js');
28
+ var { runCli } = await import('./cli-SOWJUTJL.js');
29
29
  await runCli(process.argv);
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
3
  import { npmSupportsProvenance } from './chunk-E7R2GIAW.js';
4
- import { RunnerInitError, readConfigObject } from './chunk-BWWLPFL6.js';
4
+ import { RunnerInitError, readConfigObject } from './chunk-GVDNSUP6.js';
5
5
  import './chunk-M6LQSXFY.js';
6
6
  import './chunk-2PGI6RDE.js';
7
7
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { PLACEHOLDER_MARKER, RunnerInitError, isPlaceholderCommand, prepareRunnerInit, readConfigObject, runRunnerInit, writeRunnerInit } from './chunk-BWWLPFL6.js';
3
+ export { PLACEHOLDER_MARKER, RunnerInitError, isPlaceholderCommand, prepareRunnerInit, readConfigObject, runRunnerInit, writeRunnerInit } from './chunk-GVDNSUP6.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-2PGI6RDE.js';
6
6
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { RunnerInitError } from './chunk-BWWLPFL6.js';
3
+ import { RunnerInitError } from './chunk-GVDNSUP6.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-2PGI6RDE.js';
6
6
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { summarizeChecks, summaryText, renderDoctorText } from './chunk-VB2GEEGY.js';
3
+ import { summarizeChecks, summaryText, renderDoctorText } from './chunk-GRDJ3PIY.js';
4
4
  import { shellFunctionInstalled, removeShellFunction, installShellFunction, SHELL_FUNCTION_LINE } from './chunk-IRFN2ZHJ.js';
5
5
  import './chunk-PY3KCLWJ.js';
6
6
  import './chunk-7UEW7HXC.js';
@@ -1,17 +1,17 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { LAPSED_REASON, RunnerStartError, fleetKeepalive, leaseTimeLeftFor, listJobFiles, logUnusableHelper, prepareSession, probeBuild, probeCredentials, requestStop, runnerProcessState, runtimeOf, sampleUsage, start, tick, watchTick } from './chunk-JDYNCC66.js';
4
- import './chunk-Y7HKHBYK.js';
3
+ export { LAPSED_REASON, RunnerStartError, fleetKeepalive, leaseTimeLeftFor, listJobFiles, logUnusableHelper, prepareSession, probeBuild, probeCredentials, requestStop, runnerProcessState, runtimeOf, sampleUsage, start, tick, watchTick } from './chunk-WINAPU5N.js';
4
+ import './chunk-3JVYMD4G.js';
5
+ import './chunk-LOEZWI7V.js';
6
+ import './chunk-E7R2GIAW.js';
5
7
  import './chunk-T66LOXZB.js';
6
8
  import './chunk-OGG5VWEZ.js';
7
- import './chunk-H5F3LTAS.js';
9
+ import './chunk-M6OBO45P.js';
8
10
  import './chunk-TZUHKFC6.js';
9
- import './chunk-3JVYMD4G.js';
10
- import './chunk-E7R2GIAW.js';
11
11
  import './chunk-MLM4BYK2.js';
12
- import './chunk-U7OYSE76.js';
12
+ import './chunk-VU4VSS7R.js';
13
13
  import './chunk-7XKAPGFQ.js';
14
- import './chunk-BWWLPFL6.js';
14
+ import './chunk-GVDNSUP6.js';
15
15
  import './chunk-M6LQSXFY.js';
16
16
  import './chunk-2PGI6RDE.js';
17
17
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { describeMachineDocker, detectMachine, microVmArchSupported, microVmAssetsPinned, reachDockerStep, supportsContainerBuilds, supportsMicroVmBuilds } from './chunk-BWWLPFL6.js';
3
+ export { describeMachineDocker, detectMachine, microVmArchSupported, microVmAssetsPinned, reachDockerStep, supportsContainerBuilds, supportsMicroVmBuilds } from './chunk-GVDNSUP6.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-2PGI6RDE.js';
6
6
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { readConfigObject, RunnerInitError } from './chunk-BWWLPFL6.js';
3
+ import { readConfigObject, RunnerInitError } from './chunk-GVDNSUP6.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-2PGI6RDE.js';
6
6
  import './chunk-I3LTIAOR.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { isReadable, LEASE_SECONDS, ALREADY_RELEASED, RENEW_INTERVAL_SECONDS } from './chunk-BWWLPFL6.js';
3
+ import { isReadable, LEASE_SECONDS, ALREADY_RELEASED, RENEW_INTERVAL_SECONDS } from './chunk-GVDNSUP6.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-2PGI6RDE.js';
6
6
  import './chunk-I3LTIAOR.js';
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { readOwnContainer, renderUpdateSteps, runUpdateSteps } from './chunk-H5F3LTAS.js';
4
- import './chunk-BWWLPFL6.js';
3
+ export { readOwnContainer, renderUpdateSteps, runUpdateSteps } from './chunk-M6OBO45P.js';
4
+ import './chunk-GVDNSUP6.js';
5
5
  import './chunk-M6LQSXFY.js';
6
6
  import './chunk-2PGI6RDE.js';
7
7
  import './chunk-I3LTIAOR.js';
@@ -0,0 +1,88 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire } from 'node:module';
3
+ import { resolveCredentials } from './chunk-7UEW7HXC.js';
4
+ import './chunk-4VL4HT6D.js';
5
+ import './chunk-KCHOHMSX.js';
6
+ import './chunk-DU76SWD7.js';
7
+ import './chunk-OCQ5FQZR.js';
8
+ import './chunk-NQ2NJLAL.js';
9
+ import './chunk-2KL345FW.js';
10
+ import './chunk-A2LHHKTT.js';
11
+ import { C } from './chunk-2AM6Z5BP.js';
12
+ import { defaultFetch } from './chunk-XFJMPO74.js';
13
+ import './chunk-HWVMRETT.js';
14
+ import './chunk-HJ5MIJCQ.js';
15
+ import './chunk-EWDSVOX3.js';
16
+ import './chunk-5CEGWBDI.js';
17
+ import './chunk-V3X5VM6A.js';
18
+ import './chunk-BJ3KTMDH.js';
19
+ import './chunk-NFZMENCY.js';
20
+ import './chunk-WZBHBH3J.js';
21
+ import './chunk-FZKNTIOJ.js';
22
+ import './chunk-5JFDNAVV.js';
23
+ import './chunk-J67VPST6.js';
24
+ import './chunk-PLVHIQJN.js';
25
+ import './chunk-7PZDPISM.js';
26
+ import './chunk-CDDED64E.js';
27
+ import './chunk-RA3O54FC.js';
28
+ import { homeFromEnv } from './chunk-352DHUTP.js';
29
+ import './chunk-EWRQ37X7.js';
30
+ import './chunk-2VNT47DG.js';
31
+ import './chunk-Z5GEFMRW.js';
32
+
33
+ createRequire(import.meta.url);
34
+
35
+ // src/work-needs-attention-cmd.ts
36
+ var ITEM_KEY_PREFIX = "olitem_";
37
+ var REASON_MAX = 200;
38
+ var WorkNeedsAttentionCommandError = class extends Error {
39
+ };
40
+ async function runWorkNeedsAttention(opts) {
41
+ const env = opts.env ?? process.env;
42
+ const reason = (opts.reason ?? "").replace(/\s+/g, " ").trim();
43
+ if (reason === "") {
44
+ throw new WorkNeedsAttentionCommandError('a reason is required: pass --reason "<one sentence>"');
45
+ }
46
+ if (reason.length > REASON_MAX) {
47
+ throw new WorkNeedsAttentionCommandError(`the reason is ${reason.length} characters; the limit is ${REASON_MAX}`);
48
+ }
49
+ const creds = resolveCredentials({ url: opts.url, apiKey: opts.apiKey, appId: opts.appId, home: opts.home ?? homeFromEnv(env), env });
50
+ if (!creds.apiKey.startsWith(ITEM_KEY_PREFIX)) {
51
+ throw new WorkNeedsAttentionCommandError("only a build can record why it needs attention, and it needs the item key the build is handed");
52
+ }
53
+ const workItem = env.OUTERLAYER_WORK;
54
+ if (workItem === void 0 || workItem === "") {
55
+ throw new WorkNeedsAttentionCommandError("an item key names its work item through OUTERLAYER_WORK, which is not set");
56
+ }
57
+ const endpoint = new URL(`/v1/work-items/${encodeURIComponent(workItem)}/needs-attention`, creds.url).toString();
58
+ const fetchImpl = opts.fetchImpl ?? defaultFetch;
59
+ let response;
60
+ try {
61
+ response = await fetchImpl(endpoint, {
62
+ method: "POST",
63
+ headers: {
64
+ "content-type": "application/json",
65
+ authorization: `Bearer ${creds.apiKey}`,
66
+ "x-outerlayer-app-id": creds.appId
67
+ },
68
+ body: JSON.stringify({ reason })
69
+ });
70
+ } catch (err) {
71
+ throw new WorkNeedsAttentionCommandError(`network error reaching ${endpoint}: ${String(err)}`);
72
+ }
73
+ let json;
74
+ try {
75
+ json = await response.json();
76
+ } catch {
77
+ throw new WorkNeedsAttentionCommandError(`${endpoint} answered ${response.status} with a body that is not JSON`);
78
+ }
79
+ if (!response.ok || !json.data) {
80
+ throw new WorkNeedsAttentionCommandError(json.error?.message ?? `request failed (${response.status})`);
81
+ }
82
+ const data = json.data;
83
+ const output = opts.json ? JSON.stringify(data) : `${C.green}\u2713${C.reset} recorded: needs attention ${C.dim}\xB7${C.reset} ${data.reason}`;
84
+ if (!opts.quiet) process.stdout.write(output + "\n");
85
+ return { data, output };
86
+ }
87
+
88
+ export { WorkNeedsAttentionCommandError, runWorkNeedsAttention };
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { classifyProofs, classifyProofsAt, otherPullRequestHeads, resolveProofsItem, runWorkProofs, runWorkProofsCommand } from './chunk-QR47L734.js';
3
+ export { classifyProofs, classifyProofsAt, otherPullRequestHeads, resolveProofsItem, runWorkProofs, runWorkProofsCommand } from './chunk-LC6UAHZ5.js';
4
4
  import './chunk-M6LQSXFY.js';
5
5
  import './chunk-7UEW7HXC.js';
6
6
  import './chunk-4VL4HT6D.js';
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { resolveProofsItem, ownPullRequest, otherPullRequestHeads, testProofMode, classifyProofsAt, runWorkProofs, proofsCommentId, testFilesOf, freshXmlFiles, joinResults, testSelectors, kindProblem, proofsCommentBody } from './chunk-QR47L734.js';
3
+ import { resolveProofsItem, ownPullRequest, otherPullRequestHeads, testProofMode, classifyProofsAt, runWorkProofs, proofsCommentId, testFilesOf, freshXmlFiles, joinResults, testSelectors, kindProblem, proofsCommentBody } from './chunk-LC6UAHZ5.js';
4
4
  import { runEmitDemo } from './chunk-7NXDDSJI.js';
5
5
  import { readNewestDemo } from './chunk-ER6KQCVJ.js';
6
6
  import { runWorkComment } from './chunk-YZKIVSIQ.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@outerlayer/cli",
3
- "version": "0.38.0-next.20261107184816",
3
+ "version": "0.38.0-next.20261107193136",
4
4
  "description": "OuterLayer CLI — commands: init, claude, opencode, connect, doctor, login, logout, sync, daemon (alias: watch), emit, demo, findings, work, spec, runner, hooks, mcp, context. Capture and sync coding-agent sessions, and record proof of factory work.",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Magu Studios, Inc.",
@@ -426,8 +426,18 @@ Evidence phase, for a repository with no user interface.
426
426
 
427
427
  ## Ending the run
428
428
 
429
- Run this last, after the pull request is open and the evidence is emitted, and
430
- run no other tool call after it. Before it, run `outerlayer sync` and then
429
+ In a runner build that ends without a pull request, run this command before
430
+ the final report, unless you recorded that no change is needed:
431
+
432
+ outerlayer work needs-attention --reason "<one sentence>"
433
+
434
+ The sentence says what stopped the build and what a person can do. An example
435
+ is "The tests need STRIPE_KEY. Add it as a build variable." Keep it under 200
436
+ characters. The Work page and the Activity tab show your sentence as the reason
437
+ the item needs attention. Skip it when the build opens a pull request.
438
+
439
+ Run the release command below last, after the pull request is open and the
440
+ evidence is emitted, and run no other tool call after it. Before it, run `outerlayer sync` and then
431
441
  `outerlayer work proofs --item "$OUTERLAYER_WORK"`. End the run only when it
432
442
  exits 0, or when `build-reports/evidence.md` names each proof it still lists
433
443
  and the reason. In a runner build, the host records the proofs again at the