primcli 1.41.0 → 1.43.0

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,2 +1,2 @@
1
- import { s as runBackgroundListenSupervisor } from "../listen-background-Bsofqq_6.js";
1
+ import { s as runBackgroundListenSupervisor } from "../listen-background-TTBqrO_R.js";
2
2
  export { runBackgroundListenSupervisor };
@@ -1,4 +1,4 @@
1
- import { n as jsonOutputRequested } from "../json-output-BVRgl6jf.js";
1
+ import { n as jsonOutputRequested } from "../json-output-CJXNOsUI.js";
2
2
  import { spawnSync } from "node:child_process";
3
3
  //#region src/oclif/proxy-auto-detect.ts
4
4
  const PROXY_ENV_VARS = [
@@ -1,7 +1,7 @@
1
- import { c as loadConnectedAgentProfile, i as agentProfileName, r as agentProfileDirectory, t as AGENT_PROFILE_ENV } from "../connected-agent-profile-8tpOMdq3.js";
2
- import { d as readMailJson } from "../shared-mail-files-CZqI1kj6.js";
3
- import { m as SESSION_UUID, n as detectAgentRuntime, o as notificationScope } from "../connect-skill-DuanRI34.js";
4
- import { a as claimBackgroundListenRestart, n as backgroundListenRestartable, r as backgroundListenStatus } from "../listen-background-Bsofqq_6.js";
1
+ import { N as agentProfileDirectory, P as agentProfileName, R as loadConnectedAgentProfile, j as AGENT_PROFILE_ENV } from "../cli-config-DGrZCUfw.js";
2
+ import { d as readMailJson } from "../shared-mail-files-SPPcis9g.js";
3
+ import { m as SESSION_UUID, n as detectAgentRuntime, o as notificationScope } from "../connect-skill-BJFxnbwI.js";
4
+ import { a as claimBackgroundListenRestart, n as backgroundListenRestartable, r as backgroundListenStatus } from "../listen-background-TTBqrO_R.js";
5
5
  import { join } from "node:path";
6
6
  import { spawn } from "node:child_process";
7
7
  import { homedir } from "node:os";
@@ -1,4 +1,4 @@
1
- import { S as normalizeApiBaseUrl, c as resolveConfigEnvironment, i as loadCliConfig } from "../cli-config-UOlrfcPz.js";
1
+ import { S as normalizeApiBaseUrl, c as resolveConfigEnvironment, i as loadCliConfig } from "../cli-config-DGrZCUfw.js";
2
2
  import { existsSync, readFileSync } from "node:fs";
3
3
  import { join } from "node:path";
4
4
  import { homedir } from "node:os";
@@ -9676,7 +9676,7 @@ function normalizeOptions(options) {
9676
9676
  };
9677
9677
  }
9678
9678
  //#endregion
9679
- //#region ../sdk-node/dist/repeats-CoK0tpCK.js
9679
+ //#region ../sdk-node/dist/repeats-D2xtLium.js
9680
9680
  const UUID$3 = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
9681
9681
  const ATOM = "[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+";
9682
9682
  const MAILBOX$1 = new RegExp(`^${ATOM}(?:\\.${ATOM})*@(?:[A-Za-z0-9](?:[A-Za-z0-9-]{0,61}[A-Za-z0-9])?)(?:\\.[A-Za-z0-9](?:[A-Za-z0-9-]{0,61}[A-Za-z0-9])?)*$`);
@@ -9869,9 +9869,28 @@ function utcExpiry(value) {
9869
9869
  ];
9870
9870
  return year >= 1970 && month >= 1 && month <= 12 && day >= 1 && day <= (days[month - 1] ?? 0) && Number(match[4]) < 24 && Number(match[5]) < 60 && Number(match[6]) < 60;
9871
9871
  }
9872
+ /** The fixed body of a repeat-stop notice; the stated reason is its only variable text. */
9873
+ function repeatStopNoticeText(reason) {
9874
+ return reason ? `Stopped this repeating message. Reason: ${reason}` : "Stopped this repeating message.";
9875
+ }
9876
+ /**
9877
+ * The notice body for a `repeat.stop/1` envelope sent back to a repeat's sender:
9878
+ * step `stop`, a previous step, no expiry, and a payload of `{}` or `{reason}`.
9879
+ * Unlike a status signal, the notice text is required.
9880
+ */
9881
+ function repeatStopFallback(e) {
9882
+ if (!exactKeys(e, ENVELOPE_KEYS$1) || e.protocol_version !== 1 || e.step !== "stop" || typeof e.prev_step_id !== "string" || e.expires_at !== null || !e.payload || typeof e.payload !== "object" || Array.isArray(e.payload)) return null;
9883
+ const p = e.payload;
9884
+ if (!exactKeys(p, [], ["reason"])) return null;
9885
+ if (!Object.hasOwn(p, "reason")) return repeatStopNoticeText(null);
9886
+ const reason = p.reason;
9887
+ if (typeof reason !== "string" || reason.length === 0 || reason.length > 280 || reason.includes("\0")) return null;
9888
+ return repeatStopNoticeText(reason);
9889
+ }
9872
9890
  function fallback(result) {
9873
9891
  if (result.status !== "valid") return null;
9874
9892
  const e = result.envelope;
9893
+ if (e.protocol === "repeat.stop") return repeatStopFallback(e);
9875
9894
  if (!exactKeys(e, ENVELOPE_KEYS$1) || e.protocol_version !== 1 || ![
9876
9895
  "ack",
9877
9896
  "read",
@@ -9948,7 +9967,7 @@ function classifySignalContent(input) {
9948
9967
  };
9949
9968
  const actual = (input.bodies.text ?? "").replace(/\r\n/g, "\n");
9950
9969
  const expected = text.replace(/\r\n/g, "\n");
9951
- const matches = actual === "" || actual === "\n" || actual === expected || actual === `${expected}\n`;
9970
+ const matches = !(interaction.status === "valid" && interaction.envelope.protocol === "repeat.stop") && (actual === "" || actual === "\n") || actual === expected || actual === `${expected}\n`;
9952
9971
  return {
9953
9972
  classification: matches ? "informational_only" : "mixed_or_unsupported",
9954
9973
  reason: matches ? "informational_signal" : "text_mismatch",