@rulvar/cli 1.128.0 → 1.129.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.
package/dist/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { r as runCli, t as processIo } from "./io-CsvU0Iog.js";
2
+ import { r as runCli, t as processIo } from "./io-CT8sNWMl.js";
3
3
  import { sanitizeTerminalText } from "@rulvar/core";
4
4
  import { inspect } from "node:util";
5
5
  //#region src/cli.ts
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { _ as loadCliConfig, a as invoiceCommand, c as runCommand, d as reportOutcome, f as strictExitCode, g as assembleEngine, h as DEFAULT_STORE_DIR, i as inspectCommand, l as runsLsCommand, m as renderEventLine, n as HELP, o as preflightCommand, p as attachProgress, r as runCli, s as resumeCommand, t as processIo, u as driveRun, v as loadWorkflowModule, y as looksLikeFile } from "./io-CsvU0Iog.js";
1
+ import { _ as loadCliConfig, a as invoiceCommand, c as runCommand, d as reportOutcome, f as strictExitCode, g as assembleEngine, h as DEFAULT_STORE_DIR, i as inspectCommand, l as runsLsCommand, m as renderEventLine, n as HELP, o as preflightCommand, p as attachProgress, r as runCli, s as resumeCommand, t as processIo, u as driveRun, v as loadWorkflowModule, y as looksLikeFile } from "./io-CT8sNWMl.js";
2
2
  import { ConfigError, InvalidResolutionError, JournalCompatibilityError, LeaseHeldError, Replayer, RulvarError, buildDeriverRegistry, compileSecretMasker, costReportFromJournal, journalPricingSnapshot, maskSecrets, normalizeEntry, readRunMeta, scanJournalCompatibility, validateSchemaSpec } from "@rulvar/core";
3
3
  //#region src/server.ts
4
4
  /**
@@ -964,11 +964,11 @@ async function toOtel(run, tracer, options = {}) {
964
964
  openBySpanId.set(key, open);
965
965
  stack.push(open);
966
966
  };
967
- const endSpan = (spanId, ts, status, message) => {
967
+ const endSpan = (spanId, ts, status, message, unsettled = false) => {
968
968
  const open = openBySpanId.get(spanId);
969
969
  if (open === void 0) return;
970
970
  if (status !== void 0) open.span.setAttribute("rulvar.status", status);
971
- open.span.setStatus(status !== void 0 && status !== "ok" && status !== "skipped" ? {
971
+ open.span.setStatus(status !== void 0 && status !== "ok" && status !== "skipped" || unsettled ? {
972
972
  code: STATUS_ERROR,
973
973
  ...message === void 0 ? {} : { message }
974
974
  } : { code: STATUS_OK });
@@ -991,7 +991,8 @@ async function toOtel(run, tracer, options = {}) {
991
991
  if (runOpen !== void 0 && event.salvagedPartialChildren !== void 0) runOpen.span.setAttribute("rulvar.run.salvagedPartialChildren", JSON.stringify(event.salvagedPartialChildren));
992
992
  if (runOpen !== void 0 && event.salvagedTerminalOutputChildren !== void 0) runOpen.span.setAttribute("rulvar.run.salvagedTerminalOutputChildren", JSON.stringify(event.salvagedTerminalOutputChildren));
993
993
  if (runOpen !== void 0 && event.acceptanceChildren !== void 0) runOpen.span.setAttribute("rulvar.run.acceptanceChildren", JSON.stringify(event.acceptanceChildren));
994
- endSpan(event.spanId, event.ts, event.status);
994
+ if (runOpen !== void 0 && event.settled === false) runOpen.span.setAttribute("rulvar.run.settled", false);
995
+ endSpan(event.spanId, event.ts, event.status, event.settled === false ? "settlement failed: nothing durable records this terminal; resume re-settles" : void 0, event.settled === false);
995
996
  break;
996
997
  }
997
998
  case "agent:phase:start":
@@ -220,7 +220,7 @@ function rawEventLine(event) {
220
220
  return `determinism ${str(event.category)} (${str(event.provenance)}) ${where}`;
221
221
  }
222
222
  case "log": return event.level === "debug" ? void 0 : `${str(event.level)}: ${str(event.msg)}`;
223
- case "run:end": return `run ${str(event.runId)} ${str(event.status)}${event.usageApprox === true ? " (cost approx)" : ""}${event.completion === void 0 ? "" : ` completion=${str(event.completion)}`}`;
223
+ case "run:end": return `run ${str(event.runId)} ${str(event.status)}${event.usageApprox === true ? " (cost approx)" : ""}${event.completion === void 0 ? "" : ` completion=${str(event.completion)}`}${event.settled === false ? " settled=false (outcome withheld; resume re-settles)" : ""}`;
224
224
  default: return;
225
225
  }
226
226
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rulvar/cli",
3
- "version": "1.128.0",
3
+ "version": "1.129.0",
4
4
  "description": "Rulvar shell: run/resume/runs/inspect/plan/kb commands, TUI progress, createServer, createWorker, OTel exporter.",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
@@ -22,17 +22,17 @@
22
22
  "access": "public"
23
23
  },
24
24
  "dependencies": {
25
- "@rulvar/core": "1.128.0"
25
+ "@rulvar/core": "1.129.0"
26
26
  },
27
27
  "devDependencies": {
28
28
  "@types/node": "^22.20.1",
29
29
  "tsdown": "^0.22.14",
30
30
  "typescript": "~6.0.3",
31
- "@rulvar/testing": "1.128.0",
32
- "@rulvar/store-sqlite": "1.128.0",
33
- "@rulvar/planner": "1.128.0",
34
- "@rulvar/plan": "1.128.0",
35
- "@rulvar/evals": "1.128.0"
31
+ "@rulvar/testing": "1.129.0",
32
+ "@rulvar/store-sqlite": "1.129.0",
33
+ "@rulvar/planner": "1.129.0",
34
+ "@rulvar/plan": "1.129.0",
35
+ "@rulvar/evals": "1.129.0"
36
36
  },
37
37
  "bin": {
38
38
  "rulvar": "./dist/cli.js"