@proagentstore/cli 0.4.128 → 0.4.129

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.
@@ -129,7 +129,7 @@ export function parseApplyEnvelope(raw) {
129
129
  workspace: o.workspace,
130
130
  sources,
131
131
  artifacts,
132
- policy: { mode: p.mode, allowDomains, ...(p.mode === "auto_submit" && gateId ? { submitGate: { gateId } } : {}) },
132
+ policy: { mode: p.mode, allowDomains, ...(p.mode === "auto_submit" && gateId ? { submitGate: { gateId } } : {}), ...(p.screenshots === false ? { screenshots: false } : {}) },
133
133
  limits,
134
134
  };
135
135
  }
@@ -310,7 +310,8 @@ export class LocalApplyRuntime {
310
310
  token: randomBytes(24).toString("hex"),
311
311
  state: "running",
312
312
  events: [],
313
- shots: new ShotRecorder(APPLY_SHOT_CAP, () => this.now()),
313
+ // Screenshots off (#1064): zero cap for `/shots`, and no recorder handed to the bridge below.
314
+ shots: new ShotRecorder(envelope.policy.screenshots === false ? 0 : APPLY_SHOT_CAP, () => this.now()),
314
315
  seq: 0,
315
316
  allow: new Set(envelope.policy.allowDomains),
316
317
  grounding: [],
@@ -396,7 +397,7 @@ export class LocalApplyRuntime {
396
397
  limits: e.limits,
397
398
  mode: e.policy.mode,
398
399
  gateId: e.policy.submitGate?.gateId,
399
- }, run.shots);
400
+ }, e.policy.screenshots === false ? undefined : run.shots);
400
401
  if (spec.mcpConfig)
401
402
  writeFileSync(spec.mcpConfig.path, spec.mcpConfig.json, { mode: 0o600 });
402
403
  const child = this.spawn(spec.command, spec.args, { cwd: join(run.dir, "scratch"), env: spec.env, stdio: ["ignore", "pipe", "pipe"] });
@@ -104,6 +104,7 @@ export function parseEnvelope(raw) {
104
104
  consentedDomains: strList(p.consentedDomains),
105
105
  profileConsented: p.profileConsented === true,
106
106
  consentIds: consentIdMap(p.consentIds),
107
+ ...(p.screenshots === false ? { screenshots: false } : {}),
107
108
  },
108
109
  limits,
109
110
  resultSchema: { id: typeof schema.id === "string" ? schema.id : "findings", version: typeof schema.version === "number" ? schema.version : 1 },
@@ -185,7 +186,9 @@ export class LocalBrowserRuntime {
185
186
  token: randomBytes(24).toString("hex"),
186
187
  state: "running",
187
188
  events: [],
188
- shots: new ShotRecorder(SCOUT_SHOT_CAP, () => this.now()),
189
+ // Screenshots off (#1064): a zero-cap recorder, so `/shots` answers with nothing — and the bridge
190
+ // below is given NO recorder at all, so no frame is ever attempted.
191
+ shots: new ShotRecorder(envelope.policy.screenshots === false ? 0 : SCOUT_SHOT_CAP, () => this.now()),
189
192
  seq: 0,
190
193
  consented: new Set(envelope.policy.consentedDomains),
191
194
  deny: new Set(envelope.policy.denyDomains),
@@ -230,7 +233,7 @@ export class LocalBrowserRuntime {
230
233
  allowListOnly: () => e.policy.allowDomains.length > 0,
231
234
  overTime: () => this.activeMs(run) >= e.limits.maxMinutes * 60_000,
232
235
  limits: e.limits,
233
- }, run.shots);
236
+ }, e.policy.screenshots === false ? undefined : run.shots);
234
237
  const bridgeScript = this.deps.bridgeScript ?? fileURLToPath(new URL("./bridge-stdio.js", import.meta.url));
235
238
  const spec = buildEngineSpec({
236
239
  engine: e.engine,
@@ -1109,7 +1109,7 @@ export class LocalRunner {
1109
1109
  url: active.url(),
1110
1110
  title: await active.title().catch(() => ""),
1111
1111
  challenge: await detectHumanChallenge(active),
1112
- screenshot: await this.shot(active),
1112
+ screenshot: action.screenshot === false ? undefined : await this.shot(active),
1113
1113
  commitGuard: { supported: true, mode: guard?.mode },
1114
1114
  };
1115
1115
  }
@@ -1143,7 +1143,7 @@ export class LocalRunner {
1143
1143
  title: await settled.title().catch(() => ""),
1144
1144
  challenge: await detectHumanChallenge(settled),
1145
1145
  feedback: dialogMsg ? `a native dialog was accepted: "${dialogMsg}"` : "a native dialog was accepted",
1146
- screenshot: await this.shot(settled),
1146
+ screenshot: action.screenshot === false ? undefined : await this.shot(settled),
1147
1147
  commitGuard: { supported: true, mode: guard?.mode },
1148
1148
  };
1149
1149
  }
@@ -1177,7 +1177,7 @@ export class LocalRunner {
1177
1177
  title: await active.title().catch(() => ""),
1178
1178
  challenge: await detectHumanChallenge(active),
1179
1179
  feedback: feedback || undefined,
1180
- screenshot: await this.shot(active),
1180
+ screenshot: action.screenshot === false ? undefined : await this.shot(active),
1181
1181
  commitGuard: { supported: true, mode: guard?.mode },
1182
1182
  };
1183
1183
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@proagentstore/cli",
3
- "version": "0.4.128",
3
+ "version": "0.4.129",
4
4
  "description": "CLI for creating, publishing, and running ProAgentStore agents",
5
5
  "license": "MIT",
6
6
  "type": "module",