humanish 0.83.0 → 0.83.1

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.
@@ -46,6 +46,7 @@ import { appendSandboxReceipt } from "./sandbox-receipts.js";
46
46
  import { assertScreenshotEvidence } from "./image-evidence.js";
47
47
  import { buildObserverData } from "./observer-data.js";
48
48
  import { corepackCommandFor, needsNodeRuntime, nodeBootstrapCommand } from "./subject-runtime.js";
49
+ import { TERMINAL_NODE_BOOTSTRAP_COMMAND } from "./terminal-node-bootstrap.js";
49
50
  import { chromeCdpProbeCommand, parseChromeCdpProbeOutput } from "./chrome-cdp-probe.js";
50
51
  import { personaToDirectives, renderPersonaPromptSection } from "./persona.js";
51
52
  import { labPersonaIds, resolveCommittedPersonas } from "./persona-resolve.js";
@@ -1266,23 +1267,22 @@ function shellSingleQuote(value) {
1266
1267
  return `'${value.replace(/'/g, "'\\''")}'`;
1267
1268
  }
1268
1269
  /**
1269
- * Put a CLI on the desktop before the participant arrives (#495).
1270
+ * Prepare a CLI study's runtime and, only when declared, its product (#495, #515).
1270
1271
  *
1271
1272
  * The install runs UNKEYED and before the session starts, for the same reason the clone route
1272
1273
  * provisions its subject first: what is being studied begins when the participant looks at the
1273
- * screen, and making them fight an install first would be a study of the install.
1274
+ * screen. Omitting install deliberately studies product installation; Node/npm remain a
1275
+ * harness prerequisite so the participant can follow the product's public npm instructions.
1274
1276
  */
1275
1277
  async function provisionDesktopCli(desktop, args) {
1276
1278
  const install = args.install;
1277
- if (install === undefined)
1278
- return;
1279
1279
  const now = () => Date.now();
1280
- if (needsNodeRuntime([install])) {
1280
+ if (install === undefined || needsNodeRuntime([install])) {
1281
1281
  const startedAt = now();
1282
- emitPhaseStarted(args.onPhase, now, "runtime", "providing the Node runtime the install needs");
1282
+ emitPhaseStarted(args.onPhase, now, "runtime", "providing Node/npm for the desktop CLI study");
1283
1283
  const bootstrap = await runDetachedStep(desktop, {
1284
1284
  name: "desktop-cli-runtime-node",
1285
- command: nodeBootstrapCommand(),
1285
+ command: TERMINAL_NODE_BOOTSTRAP_COMMAND,
1286
1286
  cwd: "/home/user",
1287
1287
  timeoutMs: INSTALL_TIMEOUT_MS,
1288
1288
  requestTimeoutMs: args.requestTimeoutMs
@@ -1294,6 +1294,8 @@ async function provisionDesktopCli(desktop, args) {
1294
1294
  throw new Error(`desktop-cli runtime bootstrap failed for "${args.product}"`);
1295
1295
  }
1296
1296
  }
1297
+ if (install === undefined)
1298
+ return;
1297
1299
  const startedAt = now();
1298
1300
  emitPhaseStarted(args.onPhase, now, "install", `installing ${args.product} on the desktop`);
1299
1301
  const result = await runDetachedStep(desktop, {
@@ -1831,9 +1833,8 @@ export async function runCuaLane(spec, deps) {
1831
1833
  };
1832
1834
  }
1833
1835
  if (desktopCliRoute) {
1834
- // Put the product on the desktop before the participant sees it. UNKEYED, like every other
1835
- // provisioning step: the participant's world is prepared by the harness, and what is being
1836
- // studied starts at the moment they look at the screen.
1836
+ // Prepare the runtime and any declared product install, UNKEYED. With install omitted,
1837
+ // the participant discovers and installs the product from its public surfaces.
1837
1838
  await provisionDesktopCli(desktop, {
1838
1839
  product: config.subject.product?.name ?? "",
1839
1840
  ...(config.subject.product?.install === undefined ? {} : { install: config.subject.product.install }),