@unbrained/pm-cli 2026.8.23 → 2026.8.25
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/.claude-plugin/marketplace.json +2 -2
- package/CHANGELOG.md +27 -1
- package/dist/cli/description-stdin.js +5 -4
- package/dist/cli/extension-command-help.d.ts +5 -0
- package/dist/cli/extension-command-help.js +6 -2
- package/dist/cli/help-content.d.ts +5 -0
- package/dist/cli/help-content.js +56 -3
- package/dist/cli/help-json-payload.d.ts +5 -2
- package/dist/cli/help-json-payload.js +57 -17
- package/dist/cli/main.d.ts +3 -0
- package/dist/cli/main.js +28 -3
- package/dist/cli/register-annotations.js +5 -5
- package/dist/cli/register-mutation.js +73 -27
- package/dist/cli-bundle/bundle-manifest.json +152 -152
- package/dist/cli-bundle/chunks/{chunk-HWZ6CELB.js → chunk-244MI4GS.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-QDVHNHAQ.js → chunk-2F3LUFMW.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-EG6CLDZT.js → chunk-5I5RWIJC.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-KPH73XXJ.js → chunk-65MHLHAA.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-6C7GIMIL.js +13 -0
- package/dist/cli-bundle/chunks/chunk-OWHNAR2B.js +2 -0
- package/dist/cli-bundle/chunks/chunk-QKGMHGEI.js +202 -0
- package/dist/cli-bundle/chunks/chunk-QLUORNIB.js +2092 -0
- package/dist/cli-bundle/chunks/{chunk-JB4KZWBF.js → chunk-T2ENPRXF.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-F3AI2JFL.js → chunk-TPQIBSL2.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-YQMYF3YD.js +35 -0
- package/dist/cli-bundle/chunks/{register-list-query-UJB5FMV2.js → register-list-query-XVN2ZLI7.js} +2 -2
- package/dist/cli-bundle/chunks/register-mutation-QCKAEGIJ.js +20 -0
- package/dist/cli-bundle/chunks/{register-operations-RXIJIYXC.js → register-operations-SDEAXE7E.js} +2 -2
- package/dist/cli-bundle/chunks/{register-setup-GFUZEKRE.js → register-setup-LXVBRCJ3.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-QGFNI65N.js → chunk-2UIWOP3O.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-42S3GGZ7.js +50 -0
- package/dist/cli-bundle/focused-chunks/{chunk-OGLQBL46.js → chunk-7I23XGWO.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-7YCDTCBC.js +2 -0
- package/dist/cli-bundle/focused-chunks/{chunk-OFVUGTLJ.js → chunk-A644DUFQ.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-AUFH5H35.js → chunk-GQR3WH3F.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-3UPTYG44.js → chunk-H5JZEIQV.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-IBZZZGK3.js +2 -0
- package/dist/cli-bundle/focused-chunks/chunk-LMKG3DFE.js +5 -0
- package/dist/cli-bundle/focused-chunks/{chunk-LYVSW5VM.js → chunk-N7W67YIG.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-37Z4OEAP.js → chunk-NOOZGIXP.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-FZS4H32O.js → chunk-OHIHZ7HS.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-ONYQCALA.js +19 -0
- package/dist/cli-bundle/focused-chunks/chunk-OVJL6NZE.js +4 -0
- package/dist/cli-bundle/focused-chunks/chunk-RAFKLNZX.js +16 -0
- package/dist/cli-bundle/focused-chunks/{chunk-IFLWKY2R.js → chunk-VXWATRFL.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-R27IDGHD.js → chunk-XUQPEKRN.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-JOWDB2MH.js → chunk-YO3ZF3FI.js} +2 -2
- package/dist/cli-bundle/main.js +18 -17
- package/dist/cli-bundle/sdk-authoring.js +1 -1
- package/dist/cli-bundle/sdk-contracts.js +2 -2
- package/dist/cli-bundle/sdk-core.js +32 -32
- package/dist/cli-bundle/sdk-governance.js +1 -1
- package/dist/cli-bundle/sdk-graph.js +1 -1
- package/dist/cli-bundle/sdk-merge.js +32 -33
- package/dist/cli-bundle/sdk-query.js +1 -1
- package/dist/cli-bundle/sdk-runtime.js +1 -1
- package/dist/cli-bundle/sdk-testing.js +1 -1
- package/dist/cli-bundle/sdk.js +6 -5
- package/dist/core/diagnostics/remediation.js +17 -2
- package/dist/core/extensions/command-metadata-contract.d.ts +10 -0
- package/dist/core/extensions/command-metadata-contract.js +23 -0
- package/dist/core/extensions/command-visibility-tier.js +12 -2
- package/dist/core/extensions/extension-types.d.ts +6 -0
- package/dist/core/extensions/extension-types.js +2 -2
- package/dist/core/extensions/loader.js +4 -3
- package/dist/core/io/body-file.js +7 -2
- package/dist/core/io/bulk-ids-input.d.ts +24 -0
- package/dist/core/io/bulk-ids-input.js +113 -0
- package/dist/core/item/parse.d.ts +22 -2
- package/dist/core/item/parse.js +97 -4
- package/dist/mcp/server.d.ts +3 -2
- package/dist/mcp/server.js +16 -9
- package/dist/sdk/agent/refusal-closure-census.d.ts +66 -0
- package/dist/sdk/agent/refusal-closure-census.js +144 -0
- package/dist/sdk/agent-capability-contracts.d.ts +34 -1
- package/dist/sdk/agent-capability-contracts.js +104 -6
- package/dist/sdk/annotations.d.ts +2 -0
- package/dist/sdk/annotations.js +25 -7
- package/dist/sdk/cli-contracts/runtime-contracts.d.ts +10 -0
- package/dist/sdk/cli-contracts/runtime-contracts.js +20 -3
- package/dist/sdk/cli-contracts/tool-parameter-tables.js +38 -2
- package/dist/sdk/cli-contracts/typed-action-inputs.d.ts +4 -1
- package/dist/sdk/cli-contracts/typed-action-inputs.js +2 -2
- package/dist/sdk/comments.js +15 -7
- package/dist/sdk/flag-invocation-contracts.d.ts +2 -0
- package/dist/sdk/flag-invocation-contracts.js +28 -3
- package/dist/sdk/generated/generated-error-code-catalog-part-1.js +109 -52
- package/dist/sdk/generated/generated-error-code-catalog-part-2.js +62 -2
- package/dist/sdk/governance/health.js +98 -11
- package/dist/sdk/governance/validate.js +15 -9
- package/dist/sdk/guide-topics.d.ts +0 -5
- package/dist/sdk/guide-topics.js +28 -2
- package/dist/sdk/history-compact.d.ts +2 -1
- package/dist/sdk/history-compact.js +24 -5
- package/dist/sdk/history-mcp.js +11 -10
- package/dist/sdk/history-repair.d.ts +24 -0
- package/dist/sdk/history-repair.js +145 -4
- package/dist/sdk/index.d.ts +1 -0
- package/dist/sdk/index.js +3 -2
- package/dist/sdk/item-transaction.js +19 -12
- package/dist/sdk/lifecycle/append.js +4 -4
- package/dist/sdk/lifecycle/close-many.js +16 -7
- package/dist/sdk/lifecycle/create.js +29 -21
- package/dist/sdk/lifecycle/plan.js +24 -6
- package/dist/sdk/lifecycle/update-many.js +15 -8
- package/dist/sdk/lifecycle/update.d.ts +2 -0
- package/dist/sdk/lifecycle/update.js +34 -24
- package/dist/sdk/merge/driver.js +25 -4
- package/dist/sdk/merge/receipt-file-boundary.d.ts +21 -0
- package/dist/sdk/merge/receipt-file-boundary.js +47 -0
- package/dist/sdk/merge/receipts.d.ts +24 -1
- package/dist/sdk/merge/receipts.js +342 -36
- package/dist/sdk/merge/reconcile.js +117 -47
- package/dist/sdk/read-output/continuation.d.ts +15 -2
- package/dist/sdk/read-output/continuation.js +86 -6
- package/dist/sdk/read-output-contracts.d.ts +4 -1
- package/dist/sdk/read-output-contracts.js +9 -6
- package/dist/sdk/runtime-extended-actions.js +5 -3
- package/dist/sdk/runtime-input.d.ts +4 -0
- package/dist/sdk/runtime-input.js +98 -23
- package/dist/sdk/runtime-primitives.d.ts +2 -1
- package/dist/sdk/runtime-primitives.js +4 -3
- package/dist/sdk/runtime.js +7 -20
- package/dist/sdk/scheduling-shortcuts.js +5 -3
- package/dist/sdk/structured-mutations.js +10 -3
- package/dist/sdk/workspace-contracts.d.ts +3 -0
- package/dist/sdk/workspace-contracts.js +3 -2
- package/docs/MERGE_SAFETY.md +34 -5
- package/docs/OUTPUT_PROJECTION_CONTRACTS.md +13 -1
- package/docs/README.md +2 -0
- package/docs/READ_OUTPUT_CONTRACTS.md +25 -2
- package/docs/RELEASING.md +40 -21
- package/docs/SCRIPTING.md +62 -3
- package/docs/SDK.md +8 -0
- package/docs/generated/AGENT_CAPABILITY_ROUTING.md +17 -0
- package/docs/generated/AGENT_COMMAND_SURFACE.md +1 -1
- package/docs/generated/REFUSAL_CLOSURE_CENSUS.md +359 -0
- package/marketplace.json +2 -2
- package/package.json +1 -1
- package/packages/pm-beads/package.json +1 -1
- package/packages/pm-calendar/package.json +1 -1
- package/packages/pm-command-kit/README.md +9 -11
- package/packages/pm-command-kit/extensions/command-kit/index.ts +3 -1
- package/packages/pm-command-kit/package.json +1 -1
- package/packages/pm-digital-twin/package.json +1 -1
- package/packages/pm-governance-audit/package.json +1 -1
- package/packages/pm-guide-shell/extensions/guide-shell/index.ts +10 -0
- package/packages/pm-guide-shell/package.json +1 -1
- package/packages/pm-kanban/package.json +1 -1
- package/packages/pm-lifecycle-hooks/package.json +1 -1
- package/packages/pm-linked-test-adapters/package.json +1 -1
- package/packages/pm-search-advanced/package.json +1 -1
- package/packages/pm-templates/package.json +1 -1
- package/packages/pm-todos/package.json +1 -1
- package/packages/pm-vcs/package.json +1 -1
- package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
- package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
- package/scripts/generate-agent-capability-surfaces.mjs +27 -1
- package/sdk/public-surface.json +351 -26
- package/dist/cli-bundle/chunks/chunk-3ENVHX6C.js +0 -36
- package/dist/cli-bundle/chunks/chunk-DW2CGEMU.js +0 -2
- package/dist/cli-bundle/chunks/chunk-HZBMLSZI.js +0 -201
- package/dist/cli-bundle/chunks/chunk-KXPMB2YL.js +0 -2092
- package/dist/cli-bundle/chunks/chunk-TFI5V5N2.js +0 -13
- package/dist/cli-bundle/chunks/register-mutation-NX5XE4VX.js +0 -20
- package/dist/cli-bundle/focused-chunks/chunk-5S7E72FY.js +0 -16
- package/dist/cli-bundle/focused-chunks/chunk-E7X25GC3.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-FQCSTBWE.js +0 -4
- package/dist/cli-bundle/focused-chunks/chunk-MRCNF3U6.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-OY7QAV4Y.js +0 -51
- package/dist/cli-bundle/focused-chunks/chunk-UYRFYCDQ.js +0 -5
- package/dist/cli-bundle/focused-chunks/chunk-ZHVA42R5.js +0 -18
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Defines SDK command-contract metadata for Tool Parameter Tables.
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
7
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="2d43e788-cb8d-59b8-a447-4d24033bb55b")}catch(e){}}();
|
|
8
8
|
import { PLAN_HARNESS_VALUES, PLAN_MODE_VALUES, PLAN_STEP_LINK_KIND_VALUES, PLAN_STEP_STATUS_VALUES, } from "../../types/index.js";
|
|
9
9
|
import { PM_READ_OUTPUT_SESSION_MAX_SEEN_ITEM_IDS } from "../read-output-session.js";
|
|
10
10
|
import { ASSURANCE_DEFINITION_SCHEMA } from "./schemas/assurance-definition.js";
|
|
@@ -687,6 +687,42 @@ export const PM_TOOL_ACTION_SCOPED_PARAMETER_PROPERTIES = {
|
|
|
687
687
|
anyOf: [{ type: "string" }, { type: "array", items: { type: "string" } }],
|
|
688
688
|
},
|
|
689
689
|
},
|
|
690
|
+
"update-many": {
|
|
691
|
+
ids: {
|
|
692
|
+
anyOf: [
|
|
693
|
+
{ type: "string" },
|
|
694
|
+
{ type: "number" },
|
|
695
|
+
{
|
|
696
|
+
type: "array",
|
|
697
|
+
items: { anyOf: [{ type: "string" }, { type: "number" }] },
|
|
698
|
+
},
|
|
699
|
+
],
|
|
700
|
+
},
|
|
701
|
+
},
|
|
702
|
+
"close-many": {
|
|
703
|
+
ids: {
|
|
704
|
+
anyOf: [
|
|
705
|
+
{ type: "string" },
|
|
706
|
+
{ type: "number" },
|
|
707
|
+
{
|
|
708
|
+
type: "array",
|
|
709
|
+
items: { anyOf: [{ type: "string" }, { type: "number" }] },
|
|
710
|
+
},
|
|
711
|
+
],
|
|
712
|
+
},
|
|
713
|
+
},
|
|
714
|
+
"history-compact": {
|
|
715
|
+
ids: {
|
|
716
|
+
anyOf: [
|
|
717
|
+
{ type: "string" },
|
|
718
|
+
{ type: "number" },
|
|
719
|
+
{
|
|
720
|
+
type: "array",
|
|
721
|
+
items: { anyOf: [{ type: "string" }, { type: "number" }] },
|
|
722
|
+
},
|
|
723
|
+
],
|
|
724
|
+
},
|
|
725
|
+
},
|
|
690
726
|
events: {
|
|
691
727
|
since: { type: "string", minLength: 1 },
|
|
692
728
|
type: {
|
|
@@ -2092,4 +2128,4 @@ export const PM_TOOL_ACTION_SCOPED_PARAMETER_METADATA = {
|
|
|
2092
2128
|
},
|
|
2093
2129
|
};
|
|
2094
2130
|
//# sourceMappingURL=tool-parameter-tables.js.map
|
|
2095
|
-
//# debugId=
|
|
2131
|
+
//# debugId=2d43e788-cb8d-59b8-a447-4d24033bb55b
|
|
@@ -52,7 +52,10 @@ export type PmCloseActionOptions = DeclaredProperties<CloseCommandOptions> & {
|
|
|
52
52
|
text?: string;
|
|
53
53
|
};
|
|
54
54
|
/** Typed bulk-mutation selection filters shared by the `update-many` and `close-many` actions, derived from the bulk-mutation filter contract table. */
|
|
55
|
-
export type PmBulkMutationFilterOptions = OptionsFromContracts<typeof TOOL_BULK_MUTATION_FILTER_OPTION_CONTRACT_SOURCE
|
|
55
|
+
export type PmBulkMutationFilterOptions = Omit<OptionsFromContracts<typeof TOOL_BULK_MUTATION_FILTER_OPTION_CONTRACT_SOURCE>, "ids"> & {
|
|
56
|
+
/** Explicit item allowlist supplied as CSV text, a finite numeric scalar, or transport-native string/number IDs. */
|
|
57
|
+
ids?: string | number | readonly (string | number)[];
|
|
58
|
+
};
|
|
56
59
|
/** Checkpoint/preview controls shared by the bulk mutation actions. Declared as an object type literal (not an interface) so the composed option bags keep their implicit index signature and stay assignable to the wide `Record`-based dispatch layer. */
|
|
57
60
|
export type PmBulkMutationControlOptions = {
|
|
58
61
|
/** Preview the bulk mutation without writing changes. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="52969f17-1b8d-535e-93b6-b99d4e5b9917")}catch(e){}}();
|
|
3
3
|
export {};
|
|
4
4
|
//# sourceMappingURL=typed-action-inputs.js.map
|
|
5
|
-
//# debugId=
|
|
5
|
+
//# debugId=52969f17-1b8d-535e-93b6-b99d4e5b9917
|
package/dist/sdk/comments.js
CHANGED
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
* Implements the pm comments command surface and its agent-facing runtime behavior.
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
7
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="5167b367-26cf-52d5-8040-bb001ce3592a")}catch(e){}}();
|
|
8
8
|
import { isFileAbsentError } from "../core/fs/fs-utils.js";
|
|
9
9
|
import { readFile } from "node:fs/promises";
|
|
10
|
-
import { EXIT_CODE, PmCliError, createStdinTokenResolver, } from "./runtime-primitives.js";
|
|
11
|
-
import { isErrnoError, parseAnnotationTextInput, runAnnotationCommand, } from "./annotations.js";
|
|
10
|
+
import { EXIT_CODE, PmCliError, createStdinTokenResolver, shouldResolveMutationStdinTokens, } from "./runtime-primitives.js";
|
|
11
|
+
import { assertAnnotationStdinTransportAvailable, isErrnoError, parseAnnotationTextInput, runAnnotationCommand, } from "./annotations.js";
|
|
12
12
|
async function resolveCommentTextSource(options, stdinResolver) {
|
|
13
13
|
const hasAdd = options.add !== undefined;
|
|
14
14
|
const hasStdin = options.stdin === true;
|
|
@@ -21,10 +21,11 @@ async function resolveCommentTextSource(options, stdinResolver) {
|
|
|
21
21
|
throw new PmCliError("Specify comment text using only one input source: --add, --stdin, or --file", EXIT_CODE.USAGE);
|
|
22
22
|
}
|
|
23
23
|
if (hasAdd) {
|
|
24
|
-
const addInput = await stdinResolver.resolveValue(options.add, "--add");
|
|
24
|
+
const addInput = await stdinResolver.resolveValue(options.add, "--add", shouldResolveMutationStdinTokens(options));
|
|
25
25
|
return { value: addInput ?? "", emptyFlag: "--add" };
|
|
26
26
|
}
|
|
27
27
|
if (hasStdin) {
|
|
28
|
+
assertAnnotationStdinTransportAvailable(options, "--stdin");
|
|
28
29
|
const stdinInput = await stdinResolver.resolveValue("-", "--stdin");
|
|
29
30
|
return { value: stdinInput ?? "", emptyFlag: "--stdin" };
|
|
30
31
|
}
|
|
@@ -32,16 +33,23 @@ async function resolveCommentTextSource(options, stdinResolver) {
|
|
|
32
33
|
if (!filePath) {
|
|
33
34
|
throw new PmCliError("--file path cannot be empty", EXIT_CODE.USAGE);
|
|
34
35
|
}
|
|
36
|
+
if (filePath === "-") {
|
|
37
|
+
assertAnnotationStdinTransportAvailable(options, "--file -");
|
|
38
|
+
return {
|
|
39
|
+
value: (await stdinResolver.resolveValue("-", "--file")) ?? "",
|
|
40
|
+
emptyFlag: "--file",
|
|
41
|
+
};
|
|
42
|
+
}
|
|
35
43
|
try {
|
|
36
44
|
const fileInput = await readFile(filePath, "utf8");
|
|
37
45
|
return { value: fileInput, emptyFlag: "--file" };
|
|
38
46
|
}
|
|
39
47
|
catch (error) {
|
|
40
48
|
if (isErrnoError(error) && isFileAbsentError(error)) {
|
|
41
|
-
throw new PmCliError(`--file path not found: ${filePath}
|
|
49
|
+
throw new PmCliError(`--file path not found: ${filePath}. Use --file - to read stdin.`, EXIT_CODE.USAGE);
|
|
42
50
|
}
|
|
43
51
|
const detail = error instanceof Error ? error.message : String(error);
|
|
44
|
-
throw new PmCliError(`Failed to read --file path "${filePath}": ${detail}
|
|
52
|
+
throw new PmCliError(`Failed to read --file path "${filePath}": ${detail}. Use --file - to read stdin.`, EXIT_CODE.USAGE);
|
|
45
53
|
}
|
|
46
54
|
}
|
|
47
55
|
async function resolveCommentInput(options, stdinResolver) {
|
|
@@ -123,4 +131,4 @@ export async function runComments(id, options, global) {
|
|
|
123
131
|
});
|
|
124
132
|
}
|
|
125
133
|
//# sourceMappingURL=comments.js.map
|
|
126
|
-
//# debugId=
|
|
134
|
+
//# debugId=5167b367-26cf-52d5-8040-bb001ce3592a
|
|
@@ -24,6 +24,8 @@ export interface CliFlagInvocationContract extends CliFlagContract {
|
|
|
24
24
|
input_sources: CliFlagInputSource[];
|
|
25
25
|
/** Sentinel that redirects the argv value to stdin. */
|
|
26
26
|
stdin_token?: "-";
|
|
27
|
+
/** Prefix that redirects the argv value to a file path. */
|
|
28
|
+
file_token_prefix?: "@";
|
|
27
29
|
}
|
|
28
30
|
/** Executable option arity observed from the registered Commander program. */
|
|
29
31
|
export interface CliFlagArityObservation {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="7ef5cc14-ad6b-5cce-a1a1-e5cfac85fbc2")}catch(e){}}();
|
|
3
3
|
const FLAG_DESCRIPTIONS = Object.freeze({
|
|
4
4
|
"--body": "Set the item body.",
|
|
5
|
-
"--body-file": "Read the item body from a file
|
|
5
|
+
"--body-file": "Read the item body from a file, or from stdin when set to -.",
|
|
6
6
|
"--description": "Set the item description.",
|
|
7
7
|
"--stdin": "Read the value from stdin.",
|
|
8
8
|
"--stdin-json": "Read a complete JSON document from stdin.",
|
|
@@ -12,13 +12,16 @@ const STDIN_TOKEN_FLAGS = new Set([
|
|
|
12
12
|
"--body",
|
|
13
13
|
"--comment",
|
|
14
14
|
"--dep",
|
|
15
|
+
"--dep-remove",
|
|
15
16
|
"--description",
|
|
16
17
|
"--doc",
|
|
18
|
+
"--event",
|
|
17
19
|
"--field",
|
|
18
20
|
"--file",
|
|
19
21
|
"--learning",
|
|
20
22
|
"--note",
|
|
21
23
|
"--remove",
|
|
24
|
+
"--reminder",
|
|
22
25
|
"--test",
|
|
23
26
|
"--type-option",
|
|
24
27
|
]);
|
|
@@ -32,6 +35,22 @@ const STDIN_VALUE_COMMANDS = new Set([
|
|
|
32
35
|
"notes",
|
|
33
36
|
"test",
|
|
34
37
|
"update",
|
|
38
|
+
"update-many",
|
|
39
|
+
]);
|
|
40
|
+
const FILE_OR_STDIN_COMMAND_FLAGS = new Set([
|
|
41
|
+
"close-many:--ids",
|
|
42
|
+
"comments:--file",
|
|
43
|
+
"create:--body-file",
|
|
44
|
+
"history-compact:--ids",
|
|
45
|
+
"learnings:--file",
|
|
46
|
+
"notes:--file",
|
|
47
|
+
"update:--body-file",
|
|
48
|
+
"update-many:--ids",
|
|
49
|
+
]);
|
|
50
|
+
const AT_PATH_FILE_COMMAND_FLAGS = new Set([
|
|
51
|
+
"close-many:--ids",
|
|
52
|
+
"history-compact:--ids",
|
|
53
|
+
"update-many:--ids",
|
|
35
54
|
]);
|
|
36
55
|
const BOOLEAN_FLAG_PREFIXES = [
|
|
37
56
|
"--allow-",
|
|
@@ -193,6 +212,9 @@ const OPTIONAL_VALUE_FLAGS = new Set(["--regression"]);
|
|
|
193
212
|
function resolveFlagInputSources(command, flag) {
|
|
194
213
|
if (flag === "--stdin" || flag === "--stdin-json")
|
|
195
214
|
return ["stdin"];
|
|
215
|
+
if (FILE_OR_STDIN_COMMAND_FLAGS.has(`${command}:${flag}`)) {
|
|
216
|
+
return ["argv", "file", "stdin"];
|
|
217
|
+
}
|
|
196
218
|
if (flag.endsWith("-file"))
|
|
197
219
|
return ["argv", "file"];
|
|
198
220
|
if (STDIN_TOKEN_FLAGS.has(flag) && STDIN_VALUE_COMMANDS.has(command)) {
|
|
@@ -243,6 +265,9 @@ export function enrichCliFlagInvocationContract(command, contract) {
|
|
|
243
265
|
contract.flag !== "--stdin-json"
|
|
244
266
|
? { stdin_token: "-" }
|
|
245
267
|
: {}),
|
|
268
|
+
...(AT_PATH_FILE_COMMAND_FLAGS.has(`${command}:${contract.flag}`)
|
|
269
|
+
? { file_token_prefix: "@" }
|
|
270
|
+
: {}),
|
|
246
271
|
};
|
|
247
272
|
}
|
|
248
273
|
/** Enrich a complete command flag table without mutating package-owned rows. */
|
|
@@ -317,4 +342,4 @@ export function verifyCliFlagInvocationParity(command, declarations, observation
|
|
|
317
342
|
};
|
|
318
343
|
}
|
|
319
344
|
//# sourceMappingURL=flag-invocation-contracts.js.map
|
|
320
|
-
//# debugId=
|
|
345
|
+
//# debugId=7ef5cc14-ad6b-5cce-a1a1-e5cfac85fbc2
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** Generated partition 1 of the exhaustive error-code catalog. */
|
|
2
2
|
|
|
3
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
3
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="d68e7da2-7390-5632-a3d1-375f622d5c87")}catch(e){}}();
|
|
4
4
|
export const PM_ERROR_CODE_CATALOG_PART_1 = [
|
|
5
5
|
{
|
|
6
6
|
code: "acceptance_criteria_mutation_conflict",
|
|
@@ -218,6 +218,51 @@ export const PM_ERROR_CODE_CATALOG_PART_1 = [
|
|
|
218
218
|
canonical_code: "budget_exceeded",
|
|
219
219
|
aliases: [],
|
|
220
220
|
},
|
|
221
|
+
{
|
|
222
|
+
code: "bulk_ids_input_empty",
|
|
223
|
+
meaning: "Bulk ids input empty condition.",
|
|
224
|
+
stability: "provisional",
|
|
225
|
+
exit_code: 2,
|
|
226
|
+
class: "usage",
|
|
227
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
228
|
+
sources: ["core/io/bulk-ids-input.ts", "sdk/history-compact.ts", "sdk/history-mcp.ts"],
|
|
229
|
+
emitting_commands: ["*"],
|
|
230
|
+
canonical_code: "bulk_ids_input_empty",
|
|
231
|
+
aliases: [],
|
|
232
|
+
owned_states: [
|
|
233
|
+
{ state: "bulk_ids_stdin_contains_no_nonempty_ids", probe_id: "bulk-ids-stdin-empty", entrypoints: ["update-many"], expected_exit_class: "usage" },
|
|
234
|
+
],
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
code: "bulk_ids_input_missing_path",
|
|
238
|
+
meaning: "Bulk ids input missing path condition.",
|
|
239
|
+
stability: "provisional",
|
|
240
|
+
exit_code: 2,
|
|
241
|
+
class: "usage",
|
|
242
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
243
|
+
sources: ["core/io/bulk-ids-input.ts"],
|
|
244
|
+
emitting_commands: ["*"],
|
|
245
|
+
canonical_code: "bulk_ids_input_missing_path",
|
|
246
|
+
aliases: [],
|
|
247
|
+
owned_states: [
|
|
248
|
+
{ state: "bulk_ids_file_token_omits_its_path", probe_id: "bulk-ids-file-path-missing", entrypoints: ["update-many"], expected_exit_class: "usage" },
|
|
249
|
+
],
|
|
250
|
+
},
|
|
251
|
+
{
|
|
252
|
+
code: "bulk_ids_input_unreadable",
|
|
253
|
+
meaning: "Bulk ids input unreadable condition.",
|
|
254
|
+
stability: "provisional",
|
|
255
|
+
exit_code: 3,
|
|
256
|
+
class: "not_found",
|
|
257
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
258
|
+
sources: ["core/io/bulk-ids-input.ts"],
|
|
259
|
+
emitting_commands: ["*"],
|
|
260
|
+
canonical_code: "bulk_ids_input_unreadable",
|
|
261
|
+
aliases: [],
|
|
262
|
+
owned_states: [
|
|
263
|
+
{ state: "bulk_ids_file_path_cannot_be_read", probe_id: "bulk-ids-file-unreadable", entrypoints: ["update-many"], expected_exit_class: "not_found" },
|
|
264
|
+
],
|
|
265
|
+
},
|
|
221
266
|
{
|
|
222
267
|
code: "bundle_integrity_torn_install",
|
|
223
268
|
meaning: "Bundle integrity torn install condition.",
|
|
@@ -1118,6 +1163,18 @@ export const PM_ERROR_CODE_CATALOG_PART_1 = [
|
|
|
1118
1163
|
canonical_code: "history_drift_hash_mismatch",
|
|
1119
1164
|
aliases: ["validate_history_drift_hash_mismatches"],
|
|
1120
1165
|
},
|
|
1166
|
+
{
|
|
1167
|
+
code: "history_drift_merge_receipt",
|
|
1168
|
+
meaning: "History drift merge receipt condition.",
|
|
1169
|
+
stability: "provisional",
|
|
1170
|
+
exit_code: 1,
|
|
1171
|
+
class: "generic_failure",
|
|
1172
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1173
|
+
sources: ["core/diagnostics/remediation.ts"],
|
|
1174
|
+
emitting_commands: ["*"],
|
|
1175
|
+
canonical_code: "history_drift_merge_receipt",
|
|
1176
|
+
aliases: [],
|
|
1177
|
+
},
|
|
1121
1178
|
{
|
|
1122
1179
|
code: "history_drift_missing_stream",
|
|
1123
1180
|
meaning: "History drift missing stream condition.",
|
|
@@ -1896,6 +1953,30 @@ export const PM_ERROR_CODE_CATALOG_PART_1 = [
|
|
|
1896
1953
|
canonical_code: "manifest_unknown_key",
|
|
1897
1954
|
aliases: [],
|
|
1898
1955
|
},
|
|
1956
|
+
{
|
|
1957
|
+
code: "mcp_annotation_file_unavailable",
|
|
1958
|
+
meaning: "Mcp annotation file unavailable condition.",
|
|
1959
|
+
stability: "provisional",
|
|
1960
|
+
exit_code: 2,
|
|
1961
|
+
class: "usage",
|
|
1962
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1963
|
+
sources: ["sdk/runtime-input.ts"],
|
|
1964
|
+
emitting_commands: ["*"],
|
|
1965
|
+
canonical_code: "mcp_annotation_file_unavailable",
|
|
1966
|
+
aliases: [],
|
|
1967
|
+
},
|
|
1968
|
+
{
|
|
1969
|
+
code: "mcp_stdin_unavailable",
|
|
1970
|
+
meaning: "Mcp stdin unavailable condition.",
|
|
1971
|
+
stability: "provisional",
|
|
1972
|
+
exit_code: 2,
|
|
1973
|
+
class: "usage",
|
|
1974
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1975
|
+
sources: ["sdk/annotations.ts"],
|
|
1976
|
+
emitting_commands: ["*"],
|
|
1977
|
+
canonical_code: "mcp_stdin_unavailable",
|
|
1978
|
+
aliases: [],
|
|
1979
|
+
},
|
|
1899
1980
|
{
|
|
1900
1981
|
code: "merge_conflict_markers_detected",
|
|
1901
1982
|
meaning: "Merge conflict markers detected condition.",
|
|
@@ -1933,89 +2014,65 @@ export const PM_ERROR_CODE_CATALOG_PART_1 = [
|
|
|
1933
2014
|
aliases: [],
|
|
1934
2015
|
},
|
|
1935
2016
|
{
|
|
1936
|
-
code: "
|
|
1937
|
-
meaning: "Merge
|
|
2017
|
+
code: "merge_receipt_evidence_invalid",
|
|
2018
|
+
meaning: "Merge receipt evidence invalid condition.",
|
|
1938
2019
|
stability: "provisional",
|
|
1939
2020
|
exit_code: 4,
|
|
1940
2021
|
class: "conflict",
|
|
1941
2022
|
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1942
|
-
sources: ["sdk/merge/reconcile.ts"],
|
|
1943
|
-
emitting_commands: ["*"],
|
|
1944
|
-
canonical_code: "merge_reconcile_discards_require_acceptance",
|
|
1945
|
-
aliases: [],
|
|
1946
|
-
},
|
|
1947
|
-
{
|
|
1948
|
-
code: "merge_root_not_found",
|
|
1949
|
-
meaning: "Merge root not found condition.",
|
|
1950
|
-
stability: "stable",
|
|
1951
|
-
exit_code: 3,
|
|
1952
|
-
class: "not_found",
|
|
1953
|
-
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1954
|
-
sources: ["sdk/merge/install.ts"],
|
|
2023
|
+
sources: ["core/diagnostics/remediation.ts", "sdk/merge/reconcile.ts"],
|
|
1955
2024
|
emitting_commands: ["*"],
|
|
1956
|
-
canonical_code: "
|
|
2025
|
+
canonical_code: "merge_receipt_evidence_invalid",
|
|
1957
2026
|
aliases: [],
|
|
1958
2027
|
},
|
|
1959
2028
|
{
|
|
1960
|
-
code: "
|
|
1961
|
-
meaning: "
|
|
2029
|
+
code: "merge_receipts_pending",
|
|
2030
|
+
meaning: "Merge receipts pending condition.",
|
|
1962
2031
|
stability: "provisional",
|
|
1963
2032
|
exit_code: 1,
|
|
1964
2033
|
class: "generic_failure",
|
|
1965
2034
|
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1966
|
-
sources: ["
|
|
1967
|
-
emitting_commands: ["*"],
|
|
1968
|
-
canonical_code: "missing_allowed_values",
|
|
1969
|
-
aliases: [],
|
|
1970
|
-
},
|
|
1971
|
-
{
|
|
1972
|
-
code: "missing_budget",
|
|
1973
|
-
meaning: "Missing budget condition.",
|
|
1974
|
-
stability: "provisional",
|
|
1975
|
-
exit_code: 1,
|
|
1976
|
-
class: "generic_failure",
|
|
1977
|
-
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1978
|
-
sources: ["sdk/cli-contracts/flag-lexicon-contracts.ts"],
|
|
2035
|
+
sources: ["core/diagnostics/remediation.ts"],
|
|
1979
2036
|
emitting_commands: ["*"],
|
|
1980
|
-
canonical_code: "
|
|
2037
|
+
canonical_code: "merge_receipts_pending",
|
|
1981
2038
|
aliases: [],
|
|
1982
2039
|
},
|
|
1983
2040
|
{
|
|
1984
|
-
code: "
|
|
1985
|
-
meaning: "
|
|
2041
|
+
code: "merge_reconcile_discards_require_acceptance",
|
|
2042
|
+
meaning: "Merge reconcile discards require acceptance condition.",
|
|
1986
2043
|
stability: "provisional",
|
|
1987
|
-
exit_code:
|
|
1988
|
-
class: "
|
|
2044
|
+
exit_code: 4,
|
|
2045
|
+
class: "conflict",
|
|
1989
2046
|
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
1990
|
-
sources: ["sdk/
|
|
2047
|
+
sources: ["sdk/merge/reconcile.ts"],
|
|
1991
2048
|
emitting_commands: ["*"],
|
|
1992
|
-
canonical_code: "
|
|
2049
|
+
canonical_code: "merge_reconcile_discards_require_acceptance",
|
|
1993
2050
|
aliases: [],
|
|
1994
2051
|
},
|
|
1995
2052
|
{
|
|
1996
|
-
code: "
|
|
1997
|
-
meaning: "
|
|
2053
|
+
code: "merge_reconcile_receipt_evidence_untrusted",
|
|
2054
|
+
meaning: "Merge reconcile receipt evidence untrusted condition.",
|
|
1998
2055
|
stability: "provisional",
|
|
1999
|
-
exit_code:
|
|
2000
|
-
class: "
|
|
2056
|
+
exit_code: 4,
|
|
2057
|
+
class: "conflict",
|
|
2001
2058
|
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
2002
|
-
sources: ["sdk/
|
|
2059
|
+
sources: ["sdk/history-repair.ts"],
|
|
2003
2060
|
emitting_commands: ["*"],
|
|
2004
|
-
canonical_code: "
|
|
2061
|
+
canonical_code: "merge_reconcile_receipt_evidence_untrusted",
|
|
2005
2062
|
aliases: [],
|
|
2006
2063
|
},
|
|
2007
2064
|
{
|
|
2008
|
-
code: "
|
|
2009
|
-
meaning: "
|
|
2065
|
+
code: "merge_root_not_found",
|
|
2066
|
+
meaning: "Merge root not found condition.",
|
|
2010
2067
|
stability: "stable",
|
|
2011
|
-
exit_code:
|
|
2012
|
-
class: "
|
|
2068
|
+
exit_code: 3,
|
|
2069
|
+
class: "not_found",
|
|
2013
2070
|
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
2014
|
-
sources: ["
|
|
2071
|
+
sources: ["sdk/merge/install.ts"],
|
|
2015
2072
|
emitting_commands: ["*"],
|
|
2016
|
-
canonical_code: "
|
|
2073
|
+
canonical_code: "merge_root_not_found",
|
|
2017
2074
|
aliases: [],
|
|
2018
2075
|
},
|
|
2019
2076
|
];
|
|
2020
2077
|
//# sourceMappingURL=generated-error-code-catalog-part-1.js.map
|
|
2021
|
-
//# debugId=
|
|
2078
|
+
//# debugId=d68e7da2-7390-5632-a3d1-375f622d5c87
|
|
@@ -1,7 +1,67 @@
|
|
|
1
1
|
/** Generated partition 2 of the exhaustive error-code catalog. */
|
|
2
2
|
|
|
3
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
3
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="23e8e07d-84f2-54b6-98ad-2e33d996f09d")}catch(e){}}();
|
|
4
4
|
export const PM_ERROR_CODE_CATALOG_PART_2 = [
|
|
5
|
+
{
|
|
6
|
+
code: "missing_allowed_values",
|
|
7
|
+
meaning: "Missing allowed values condition.",
|
|
8
|
+
stability: "provisional",
|
|
9
|
+
exit_code: 1,
|
|
10
|
+
class: "generic_failure",
|
|
11
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
12
|
+
sources: ["sdk/agent/refusal-closure.ts"],
|
|
13
|
+
emitting_commands: ["*"],
|
|
14
|
+
canonical_code: "missing_allowed_values",
|
|
15
|
+
aliases: [],
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
code: "missing_budget",
|
|
19
|
+
meaning: "Missing budget condition.",
|
|
20
|
+
stability: "provisional",
|
|
21
|
+
exit_code: 1,
|
|
22
|
+
class: "generic_failure",
|
|
23
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
24
|
+
sources: ["sdk/cli-contracts/flag-lexicon-contracts.ts"],
|
|
25
|
+
emitting_commands: ["*"],
|
|
26
|
+
canonical_code: "missing_budget",
|
|
27
|
+
aliases: [],
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
code: "missing_cli_flag",
|
|
31
|
+
meaning: "Missing cli flag condition.",
|
|
32
|
+
stability: "provisional",
|
|
33
|
+
exit_code: 1,
|
|
34
|
+
class: "generic_failure",
|
|
35
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
36
|
+
sources: ["sdk/cli-contracts/tool-option-contracts.ts"],
|
|
37
|
+
emitting_commands: ["*"],
|
|
38
|
+
canonical_code: "missing_cli_flag",
|
|
39
|
+
aliases: [],
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
code: "missing_destination",
|
|
43
|
+
meaning: "Missing destination condition.",
|
|
44
|
+
stability: "provisional",
|
|
45
|
+
exit_code: 1,
|
|
46
|
+
class: "generic_failure",
|
|
47
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
48
|
+
sources: ["sdk/cli-contracts/grammar-contracts.ts"],
|
|
49
|
+
emitting_commands: ["*"],
|
|
50
|
+
canonical_code: "missing_destination",
|
|
51
|
+
aliases: [],
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
code: "missing_directory",
|
|
55
|
+
meaning: "Missing directory condition.",
|
|
56
|
+
stability: "stable",
|
|
57
|
+
exit_code: 1,
|
|
58
|
+
class: "generic_failure",
|
|
59
|
+
recovery: "Inspect the structured error guidance and retry the suggested command.",
|
|
60
|
+
sources: ["core/diagnostics/remediation.ts"],
|
|
61
|
+
emitting_commands: ["*"],
|
|
62
|
+
canonical_code: "missing_directory",
|
|
63
|
+
aliases: [],
|
|
64
|
+
},
|
|
5
65
|
{
|
|
6
66
|
code: "missing_init_recovery",
|
|
7
67
|
meaning: "Missing init recovery condition.",
|
|
@@ -2039,4 +2099,4 @@ export const PM_ERROR_CODE_CATALOG_PART_2 = [
|
|
|
2039
2099
|
},
|
|
2040
2100
|
];
|
|
2041
2101
|
//# sourceMappingURL=generated-error-code-catalog-part-2.js.map
|
|
2042
|
-
//# debugId=
|
|
2102
|
+
//# debugId=23e8e07d-84f2-54b6-98ad-2e33d996f09d
|