@pulsemcp/air-cli 0.0.38 → 0.0.40

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,10 +1,14 @@
1
1
  /**
2
- * Warns if the user invoked any of the old plural artifact-selection flags
3
- * (renamed in v0.0.32). Both `air start` and `air prepare` use
4
- * `.allowUnknownOption(true)` so these would otherwise be silently dropped.
2
+ * Hard-errors if the user invoked any of the old plural artifact-selection
3
+ * flags (renamed in v0.0.32). Both `air start` and `air prepare` use
4
+ * `.allowUnknownOption(true)` so these would otherwise be silently dropped
5
+ * see https://github.com/pulsemcp/air/issues/95 for an incident where this
6
+ * caused a session to spin up missing its plugins.
5
7
  *
6
- * `start` forwards everything after `--` to the agent, so the scan stops there
7
- * to avoid warning on agent flags that happen to share a name.
8
+ * `start` forwards everything after `--` to the agent, so the scan stops
9
+ * there to avoid rejecting agent flags that happen to share a name.
10
+ *
11
+ * Exits the process with code 1 on the first deprecated flag encountered.
8
12
  */
9
- export declare function warnOnDeprecatedArtifactFlags(argv: readonly string[]): void;
13
+ export declare function rejectDeprecatedArtifactFlags(argv: readonly string[]): void;
10
14
  //# sourceMappingURL=deprecated-flags.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"deprecated-flags.d.ts","sourceRoot":"","sources":["../../src/commands/deprecated-flags.ts"],"names":[],"mappings":"AAWA;;;;;;;GAOG;AACH,wBAAgB,6BAA6B,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,IAAI,CAgB3E"}
1
+ {"version":3,"file":"deprecated-flags.d.ts","sourceRoot":"","sources":["../../src/commands/deprecated-flags.ts"],"names":[],"mappings":"AAWA;;;;;;;;;;;GAWG;AACH,wBAAgB,6BAA6B,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,IAAI,CAc3E"}
@@ -9,25 +9,27 @@ const RENAMED_FLAGS = {
9
9
  "--without-plugins": "--without-plugin",
10
10
  };
11
11
  /**
12
- * Warns if the user invoked any of the old plural artifact-selection flags
13
- * (renamed in v0.0.32). Both `air start` and `air prepare` use
14
- * `.allowUnknownOption(true)` so these would otherwise be silently dropped.
12
+ * Hard-errors if the user invoked any of the old plural artifact-selection
13
+ * flags (renamed in v0.0.32). Both `air start` and `air prepare` use
14
+ * `.allowUnknownOption(true)` so these would otherwise be silently dropped
15
+ * see https://github.com/pulsemcp/air/issues/95 for an incident where this
16
+ * caused a session to spin up missing its plugins.
15
17
  *
16
- * `start` forwards everything after `--` to the agent, so the scan stops there
17
- * to avoid warning on agent flags that happen to share a name.
18
+ * `start` forwards everything after `--` to the agent, so the scan stops
19
+ * there to avoid rejecting agent flags that happen to share a name.
20
+ *
21
+ * Exits the process with code 1 on the first deprecated flag encountered.
18
22
  */
19
- export function warnOnDeprecatedArtifactFlags(argv) {
23
+ export function rejectDeprecatedArtifactFlags(argv) {
20
24
  const dashDashIdx = argv.indexOf("--");
21
25
  const scan = dashDashIdx === -1 ? argv : argv.slice(0, dashDashIdx);
22
- const seen = new Set();
23
26
  for (const arg of scan) {
24
27
  const base = arg.includes("=") ? arg.slice(0, arg.indexOf("=")) : arg;
25
28
  const replacement = RENAMED_FLAGS[base];
26
- if (replacement && !seen.has(base)) {
27
- seen.add(base);
28
- console.error(`Warning: ${base} was renamed to ${replacement} in v0.0.32. ` +
29
- `Pass multiple IDs as \`${replacement} a b\` or by repeating the flag. ` +
30
- `The old flag is being ignored.`);
29
+ if (replacement) {
30
+ console.error(`Error: ${base} was renamed to ${replacement} in v0.0.32 and is no longer accepted.\n` +
31
+ ` Pass multiple IDs as \`${replacement} a b\` or by repeating the flag (\`${replacement} a ${replacement} b\`).`);
32
+ process.exit(1);
31
33
  }
32
34
  }
33
35
  }
@@ -1 +1 @@
1
- {"version":3,"file":"deprecated-flags.js","sourceRoot":"","sources":["../../src/commands/deprecated-flags.ts"],"names":[],"mappings":"AAAA,MAAM,aAAa,GAA2B;IAC5C,UAAU,EAAE,SAAS;IACrB,eAAe,EAAE,cA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B,SAAS,EAAE,QAAQ;IACnB,WAAW,EAAE,UAAU;IACvB,kBAAkB,EAAE,iBAAiB;IACrC,uBAAuB,EAAE,sBAAsB;IAC/C,iBAAiB,EAAE,gBAAgB;IACnC,mBAAmB,EAAE,kBAAkB;CACxC,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,6BAA6B,CAAC,IAAuB;IACnE,MAAM,WAAW,GAAG,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IACvC,MAAM,IAAI,GAAG,WAAW,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC;IACpE,KAAK,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC;QACvB,MAAM,IAAI,GAAG,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC;QACtE,MAAM,WAAW,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;QACxC,IAAI,WAAW,EAAE,CAAC;YAChB,OAAO,CAAC,KAAK,CACX,UAAU,IAAI,mBAAmB,WAAW,0CAA0C;gBACpF,iCAAiC,WAAW,sCAAsC,WAAW,MAAM,WAAW,QAAQ,CACzH,CAAC;YACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAClB,CAAC;IACH,CAAC;AACH,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { dirname, resolve } from "path";
2
2
  import { Command } from "commander";
3
3
  import { prepareSession, loadAirConfig, getAirJsonPath, loadExtensions, } from "@pulsemcp/air-sdk";
4
- import { warnOnDeprecatedArtifactFlags } from "./deprecated-flags.js";
4
+ import { rejectDeprecatedArtifactFlags } from "./deprecated-flags.js";
5
5
  import { parseGitProtocolFlag } from "./git-protocol.js";
6
6
  /**
7
7
  * Extract the flag name from a Commander flag string.
@@ -51,7 +51,7 @@ export function prepareCommand() {
51
51
  .option("--git-protocol <protocol>", "Protocol used by git-based catalog providers: \"ssh\" (default) or \"https\". Overrides the gitProtocol field in air.json.")
52
52
  .allowUnknownOption(true)
53
53
  .action(async (adapter, options) => {
54
- warnOnDeprecatedArtifactFlags(process.argv);
54
+ rejectDeprecatedArtifactFlags(process.argv);
55
55
  const gitProtocol = parseGitProtocolFlag(options.gitProtocol);
56
56
  try {
57
57
  // Load extensions once — pass to SDK to avoid double loading
@@ -2,7 +2,7 @@ import { spawn } from "child_process";
2
2
  import { Command } from "commander";
3
3
  import { startSession, prepareSession, detectRoot, computeMergedDefaults, resolveCategoryOverride, } from "@pulsemcp/air-sdk";
4
4
  import { runInteractiveSelector } from "../tui/interactive-selector.js";
5
- import { warnOnDeprecatedArtifactFlags } from "./deprecated-flags.js";
5
+ import { rejectDeprecatedArtifactFlags } from "./deprecated-flags.js";
6
6
  import { parseGitProtocolFlag } from "./git-protocol.js";
7
7
  export function startCommand() {
8
8
  const cmd = new Command("start")
@@ -26,7 +26,7 @@ export function startCommand() {
26
26
  .action(async (agent, options) => {
27
27
  const dashDashIdx = process.argv.indexOf("--");
28
28
  const passthroughArgs = dashDashIdx !== -1 ? process.argv.slice(dashDashIdx + 1) : [];
29
- warnOnDeprecatedArtifactFlags(process.argv);
29
+ rejectDeprecatedArtifactFlags(process.argv);
30
30
  const gitProtocol = parseGitProtocolFlag(options.gitProtocol);
31
31
  let result;
32
32
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pulsemcp/air-cli",
3
- "version": "0.0.38",
3
+ "version": "0.0.40",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -26,7 +26,7 @@
26
26
  "lint": "tsc --noEmit"
27
27
  },
28
28
  "dependencies": {
29
- "@pulsemcp/air-sdk": "0.0.38",
29
+ "@pulsemcp/air-sdk": "0.0.40",
30
30
  "commander": "^12.1.0",
31
31
  "chalk": "^5.3.0"
32
32
  },