@autonoma-ai/planner 0.1.15 → 0.1.16

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/README.md CHANGED
@@ -6,7 +6,7 @@ Autonoma so onboarding can continue.
6
6
 
7
7
  ## Usage
8
8
 
9
- Run it in your project root:
9
+ Requires **Node.js >= 22.13**. Run it in your project root:
10
10
 
11
11
  ```bash
12
12
  npx @autonoma-ai/planner@latest
package/dist/index.js CHANGED
@@ -168,7 +168,10 @@ function track(event, properties = {}) {
168
168
  // Only build a person profile when we have a real identity from the app,
169
169
  // so the CLI joins the existing funnel person instead of creating a new one.
170
170
  $process_person_profile: identity != null,
171
- cli_version: CLI_VERSION
171
+ cli_version: CLI_VERSION,
172
+ // Runtime version - lets us confirm/monitor Node-version-specific
173
+ // failures (e.g. the @clack `util.styleText` crash on Node < 22.13).
174
+ node_version: process.versions.node
172
175
  }
173
176
  });
174
177
  const promise = fetch(`${resolveHost()}/capture/`, {
@@ -6860,6 +6863,34 @@ var init_test_generator = __esm({
6860
6863
 
6861
6864
  // src/index.ts
6862
6865
  init_esm_shims();
6866
+
6867
+ // src/core/ensure-node.ts
6868
+ init_esm_shims();
6869
+
6870
+ // src/core/node-version.ts
6871
+ init_esm_shims();
6872
+ var MIN_NODE = { major: 22, minor: 13 };
6873
+ function isSupportedNodeVersion(raw) {
6874
+ const parts = raw.split(".");
6875
+ const major = Number.parseInt(parts[0] ?? "", 10);
6876
+ const minor = Number.parseInt(parts[1] ?? "", 10);
6877
+ if (!Number.isFinite(major) || !Number.isFinite(minor)) return false;
6878
+ return major > MIN_NODE.major || major === MIN_NODE.major && minor >= MIN_NODE.minor;
6879
+ }
6880
+ function ensureSupportedNode() {
6881
+ const raw = process.versions.node;
6882
+ if (isSupportedNodeVersion(raw)) return;
6883
+ console.error(
6884
+ `\x1B[31mAutonoma Planner requires Node.js >= ${MIN_NODE.major}.${MIN_NODE.minor} - you're running v${raw}.\x1B[0m`
6885
+ );
6886
+ console.error("Please upgrade Node.js and re-run. See https://nodejs.org/en/download");
6887
+ process.exit(1);
6888
+ }
6889
+
6890
+ // src/core/ensure-node.ts
6891
+ ensureSupportedNode();
6892
+
6893
+ // src/index.ts
6863
6894
  import { readFile as readFile22, writeFile as writeFile13 } from "fs/promises";
6864
6895
  import { join as join30 } from "path";
6865
6896
  import * as p9 from "@clack/prompts";