@scalequality/cli 0.4.3 → 0.4.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.
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "sdkVersion": "0.3.281",
3
- "sha256": "937ecca7cbaa57b4fd879b2075581dcb73186b336b3fedfac6537b40305c6912",
4
- "sourceCommit": "91e17f6320627a49e1c5864c7d2618e9552b705d"
3
+ "sha256": "b57f71ab28de4214c669f8afde0190f89a117360c42329b47f66d2801739438c",
4
+ "sourceCommit": "d4755e6bee3c5df77d1da8eed7f5b4f577072e61"
5
5
  }
package/dist/connect.cjs CHANGED
@@ -10549,6 +10549,21 @@ ${latest.summary}
10549
10549
  blocks.push(runId ? await this.toolContext("get_measurement_findings", { ...args, runId, ...repoFullName ? { repoFullName } : {} }, "measurement_findings") : "<measurement_findings>No completed measurement was found for this scope.</measurement_findings>");
10550
10550
  }
10551
10551
  }
10552
+ for (const raw of (Array.isArray(payload.sessionContext) ? payload.sessionContext : []).slice(0, 8)) {
10553
+ const c = raw;
10554
+ const title = String(c.title ?? "Parallel task").replace(/"/g, "").slice(0, 120);
10555
+ const facts = [
10556
+ typeof c.answer === "string" && c.answer ? `What it reported:
10557
+ ${c.answer.slice(0, 4e3)}` : "It has not reported an answer yet.",
10558
+ c.change ? `Change: ${JSON.stringify(c.change)}` : null,
10559
+ c.tests ? `Last test run: ${JSON.stringify(c.tests)}` : null,
10560
+ c.measurement ? `ScaleQuality measurement: ${JSON.stringify(c.measurement)}` : null,
10561
+ Array.isArray(c.pullRequests) && c.pullRequests.length ? `Pull requests: ${c.pullRequests.join(", ")}` : null
10562
+ ].filter(Boolean).join("\n");
10563
+ blocks.push(`<parallel_task_result title="${title}">
10564
+ ${facts}
10565
+ </parallel_task_result>`);
10566
+ }
10552
10567
  return { images, blocks };
10553
10568
  }
10554
10569
  async toolContext(name, args, tag) {
@@ -10778,7 +10793,7 @@ ${text3}`;
10778
10793
  resumeAt: resume ? at : null,
10779
10794
  abortController: ac,
10780
10795
  reasoning: reasoning.options,
10781
- env: buildEngineEnv(boot, this.deps.configDir, model, { local: this.local, reasoning, output, extraEnv: this.projectEnv() }),
10796
+ env: buildEngineEnv(boot, this.deps.configDir, model, { local: this.local, reasoning, output, extraEnv: this.projectEnv(), plan: planMode }),
10782
10797
  mcpServer: this.mcpServer,
10783
10798
  systemAppend: await this.systemAppend(),
10784
10799
  policy: {
@@ -11425,6 +11440,13 @@ function safeEnv(env) {
11425
11440
  for (const [k, v] of Object.entries(env)) if (/^[A-Z_][A-Z0-9_]{0,63}$/.test(k) && !RESERVED_ENV.test(k) && typeof v === "string" && v.length <= 8192) out2[k] = v;
11426
11441
  return out2;
11427
11442
  }
11443
+ var scrubAvailable = null;
11444
+ function subprocessScrubAvailable() {
11445
+ if (scrubAvailable !== null) return scrubAvailable;
11446
+ if (process.platform !== "linux") return scrubAvailable = true;
11447
+ const r = (0, import_child_process3.spawnSync)("bwrap", ["--ro-bind", "/", "/", "--dev", "/dev", "--proc", "/proc", "true"], { timeout: 5e3, stdio: "ignore" });
11448
+ return scrubAvailable = !r.error && r.status === 0;
11449
+ }
11428
11450
  function buildEngineEnv(boot, configDir, model, opts = {}) {
11429
11451
  const base = sandboxTestEnv();
11430
11452
  delete base.NODE_ENV;
@@ -11457,8 +11479,11 @@ function buildEngineEnv(boot, configDir, model, opts = {}) {
11457
11479
  DISABLE_AUTOUPDATER: "1",
11458
11480
  DISABLE_GROWTHBOOK: "1",
11459
11481
  CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC: "1",
11460
- // Strips provider credentials from the engine's own subprocesses (Bash, hooks).
11461
- CLAUDE_CODE_SUBPROCESS_ENV_SCRUB: "1",
11482
+ // Strips provider credentials from the engine's own subprocesses (Bash, hooks) where it can: on Linux the
11483
+ // engine needs a working bubblewrap for it and refuses to start without one (the Fargate task has none), and
11484
+ // it also forces the permission mode back to default, so a plan-mode turn runs without it. Without it, the
11485
+ // environment is the allowlist above and the policy denies reading the credentials from a command.
11486
+ CLAUDE_CODE_SUBPROCESS_ENV_SCRUB: opts.plan || !subprocessScrubAvailable() ? "0" : "1",
11462
11487
  BASH_DEFAULT_TIMEOUT_MS: String(5 * 6e4),
11463
11488
  BASH_MAX_TIMEOUT_MS: String(10 * 6e4),
11464
11489
  GIT_TERMINAL_PROMPT: "0",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scalequality/cli",
3
- "version": "0.4.3",
3
+ "version": "0.4.4",
4
4
  "description": "ScaleQuality CLI. Connect your computer to the ScaleQuality AI Workspace (`scalequality login`), run its coding engine in any folder of your computer, and import your Claude Code and Codex conversations.",
5
5
  "type": "module",
6
6
  "bin": {