@unbrained/pm-cli 2026.11.9 → 2026.11.10
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 +1 -1
- package/CHANGELOG.md +16 -0
- package/dist/cli/error-guidance.js +4 -4
- package/dist/cli/main.js +1 -1
- package/dist/cli/public.d.ts +1 -1
- package/dist/cli/register-history-maintenance.js +2 -2
- package/dist/cli/register-setup.js +1 -1
- package/dist/cli-bundle/bundle-manifest.json +1 -1
- package/dist/cli-bundle/chunks/{chunk-G6Q4VQSI.js → chunk-4AASUCHO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-EZRLW4R6.js → chunk-4FLAKTZW.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-5CAMQHEW.js +3 -0
- package/dist/cli-bundle/chunks/{chunk-3BMIAI4P.js → chunk-7NAAW5EX.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-BSJSGDA3.js +3 -0
- package/dist/cli-bundle/chunks/{chunk-XKY4LUXN.js → chunk-CZETQYKO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ASJZMYKM.js → chunk-D727C4RO.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-6V4PGJBZ.js → chunk-EHDGHFMJ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GZVOOHTO.js → chunk-F6FBGLR7.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-O2M3TNFY.js → chunk-F7P2NZEG.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-YK5GAWOT.js → chunk-FYD6LSJA.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-L4WWG2H6.js +6 -0
- package/dist/cli-bundle/chunks/{chunk-YV5ALMG2.js → chunk-NNE63MSM.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-Z3QEEOAM.js → chunk-NZAFLDSH.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-MSJ7IHMJ.js → chunk-OJ2KEDUX.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ELNWRSGZ.js → chunk-T2MNRM3S.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-VATZTJE3.js → chunk-TBBWPEF5.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GDQ2T2OR.js → chunk-U7LILCUN.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-BLUCQ4T4.js → chunk-UFPLZ6LZ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-JK7O7MFO.js → chunk-UL64P6MR.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-GCPP37N6.js → chunk-WNEUWDUE.js} +46 -46
- package/dist/cli-bundle/chunks/{chunk-5VRJPPUC.js → chunk-X7NM5HVQ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-IGT252ES.js → chunk-YSWD2NXB.js} +2 -2
- package/dist/cli-bundle/chunks/{item-revision-Y5CE3EIN.js → item-revision-M7KXLQXF.js} +2 -2
- package/dist/cli-bundle/chunks/item-transaction-4N5P34GO.js +2 -0
- package/dist/cli-bundle/chunks/{mutation-admission-TAQN2AKK.js → mutation-admission-374UR7NI.js} +2 -2
- package/dist/cli-bundle/chunks/{register-list-query-XMQYFUFI.js → register-list-query-GSB7PP5P.js} +2 -2
- package/dist/cli-bundle/chunks/{register-mutation-OBVCFLDK.js → register-mutation-ZBF6ITYK.js} +2 -2
- package/dist/cli-bundle/chunks/{register-operations-CGNFZ6DR.js → register-operations-PWF6GOHE.js} +2 -2
- package/dist/cli-bundle/chunks/{register-setup-LFB5ERXH.js → register-setup-QDZ2Y3CI.js} +2 -2
- package/dist/cli-bundle/chunks/{stage-NQHF6JPC.js → stage-67WGPKPH.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-HNFY3XLC.js → chunk-2Y4H4LIX.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-UIKLNSW3.js → chunk-3DWNH72D.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-3K2MYE7R.js +26 -0
- package/dist/cli-bundle/focused-chunks/{chunk-CUGJ2DY2.js → chunk-56MIAFEN.js} +3 -3
- package/dist/cli-bundle/focused-chunks/{chunk-Q45LDP7P.js → chunk-67M7E2Z3.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-XLSTFUXM.js → chunk-BE2GK2G7.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-C3DO4ZGZ.js → chunk-HTMQDNVC.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-QWUWNFQO.js → chunk-LY3JXL25.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-IS5FLEZW.js → chunk-PAGW6A2X.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-4FWMXQN3.js → chunk-QCHCEFTO.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-AH5IST3V.js → chunk-QHGGO7SY.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-QK7FX4O5.js +44 -0
- package/dist/cli-bundle/focused-chunks/{chunk-RNZUORGI.js → chunk-RFMKS7VD.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-MYBKRV5R.js → chunk-U7HWWEJ2.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-UIZVD36C.js +2 -0
- package/dist/cli-bundle/focused-chunks/{chunk-J7PWHKZK.js → chunk-WJHDUON5.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-LDMBNTOG.js → chunk-WK773UVA.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-ZBOCYFBE.js +82 -0
- package/dist/cli-bundle/focused-chunks/{item-revision-M6FOLME2.js → item-revision-XC4ZJ7MY.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{item-transaction-H6VA5JGB.js → item-transaction-CVGK4RJP.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{mutation-admission-PRTQWQK6.js → mutation-admission-N27D5H64.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{stage-7T77PSJD.js → stage-KPK2UHVO.js} +2 -2
- package/dist/cli-bundle/main.js +26 -26
- package/dist/cli-bundle/sdk-authoring.js +1 -1
- package/dist/cli-bundle/sdk-contracts.js +1 -1
- package/dist/cli-bundle/sdk-core.js +1 -1
- 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 +51 -51
- 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 +1 -1
- package/dist/core/checkpoint/mutation-checkpoint.d.ts +12 -20
- package/dist/core/config/nested-settings.d.ts +14 -45
- package/dist/core/config/nested-settings.js +1 -1
- package/dist/core/config/positional-value.d.ts +11 -14
- package/dist/core/config/positional-value.js +1 -1
- package/dist/core/extensions/activation-summary-markdown.d.ts +4 -5
- package/dist/core/extensions/activation-summary.d.ts +7 -15
- package/dist/core/extensions/capability-usage.d.ts +7 -23
- package/dist/core/extensions/command-hook-context.d.ts +4 -7
- package/dist/core/extensions/command-metadata-contract.d.ts +2 -2
- package/dist/core/extensions/contribution-inventory.d.ts +3 -25
- package/dist/core/extensions/extension-capability-aliases.d.ts +7 -10
- package/dist/core/extensions/extension-hook-runtime.d.ts +2 -2
- package/dist/core/extensions/extension-policy.d.ts +12 -47
- package/dist/core/extensions/extension-registries.d.ts +2 -2
- package/dist/core/extensions/extension-types.d.ts +332 -545
- package/dist/core/extensions/flag-definition-validation.d.ts +11 -13
- package/dist/core/extensions/flag-value-types.d.ts +11 -13
- package/dist/core/extensions/index.d.ts +15 -20
- package/dist/core/extensions/item-field-types.d.ts +5 -5
- package/dist/core/extensions/item-fields.d.ts +4 -7
- package/dist/core/extensions/loader.d.ts +5 -69
- package/dist/core/extensions/manifest-parser.d.ts +3 -3
- package/dist/core/extensions/manifest-schema.d.ts +10 -13
- package/dist/core/extensions/registration-contracts.d.ts +2 -4
- package/dist/core/extensions/registration-validation.d.ts +1 -1
- package/dist/core/extensions/registration-values.d.ts +5 -7
- package/dist/core/extensions/runtime-registrations.d.ts +6 -6
- package/dist/core/extensions/version-compat.d.ts +9 -10
- package/dist/core/fs/fs-utils.d.ts +4 -6
- package/dist/core/fs/host-environment-errors.d.ts +8 -10
- package/dist/core/governance/content-fields.d.ts +10 -14
- package/dist/core/governance/issue-codes.d.ts +12 -18
- package/dist/core/governance/metadata-coverage.d.ts +24 -34
- package/dist/core/history/digest.d.ts +3 -3
- package/dist/core/history/event-classification.d.ts +5 -5
- package/dist/core/history/event-index.d.ts +14 -35
- package/dist/core/history/history-compact-bulk.d.ts +10 -13
- package/dist/core/history/history-diff.d.ts +6 -11
- package/dist/core/history/history-rewrite.d.ts +24 -40
- package/dist/core/history/history-storage-stats.d.ts +9 -17
- package/dist/core/history/history-stream-policy.d.ts +8 -11
- package/dist/core/history/history.d.ts +10 -44
- package/dist/core/history/identity.d.ts +4 -5
- package/dist/core/history/operation-contract.d.ts +5 -15
- package/dist/core/history/projection.d.ts +10 -14
- package/dist/core/history/read.d.ts +6 -7
- package/dist/core/history/replay.d.ts +16 -37
- package/dist/core/history/workspace-history.d.ts +27 -60
- package/dist/core/io/body-file.d.ts +2 -2
- package/dist/core/io/bulk-ids-input.d.ts +7 -8
- package/dist/core/item/actionability.d.ts +16 -22
- package/dist/core/item/dependency-reference.d.ts +2 -2
- package/dist/core/item/id.d.ts +5 -9
- package/dist/core/item/item-format-version.d.ts +11 -13
- package/dist/core/item/item-format.d.ts +11 -59
- package/dist/core/item/item-record.d.ts +2 -2
- package/dist/core/item/literal-mutation-input.d.ts +2 -2
- package/dist/core/item/parent-reference-policy.d.ts +4 -7
- package/dist/core/item/parse.d.ts +10 -26
- package/dist/core/item/plan-lifecycle.d.ts +3 -3
- package/dist/core/item/priority.d.ts +2 -2
- package/dist/core/item/sprint-release-format.d.ts +3 -7
- package/dist/core/item/status-filter.d.ts +5 -7
- package/dist/core/item/status.d.ts +3 -4
- package/dist/core/item/type-registry.d.ts +17 -24
- package/dist/core/item/type-synonyms.d.ts +1 -1
- package/dist/core/lock/lock-owner.d.ts +8 -10
- package/dist/core/lock/lock.d.ts +19 -67
- package/dist/core/output/output-control.d.ts +5 -6
- package/dist/core/output/output.d.ts +10 -19
- package/dist/core/output/tabular.d.ts +2 -2
- package/dist/core/packages/manifest.d.ts +13 -17
- package/dist/core/packages/root.d.ts +3 -3
- package/dist/core/policy/workflow-policy-schema.d.ts +2 -310
- package/dist/core/policy/workflow-policy-store.d.ts +5 -14
- package/dist/core/policy/workflow-policy.d.ts +25 -52
- package/dist/core/profile/profile-describe.d.ts +8 -11
- package/dist/core/profile/profile-lint.d.ts +11 -13
- package/dist/core/profile/profile-plan.d.ts +30 -49
- package/dist/core/profile/profile-presets.d.ts +25 -36
- package/dist/core/reproducibility/context.d.ts +6 -7
- package/dist/core/schema/fields-file.d.ts +14 -21
- package/dist/core/schema/item-types-file.d.ts +16 -22
- package/dist/core/schema/runtime-field-filters.d.ts +2 -2
- package/dist/core/schema/runtime-field-values.d.ts +6 -13
- package/dist/core/schema/runtime-schema.d.ts +19 -31
- package/dist/core/schema/status-defs-file.d.ts +15 -25
- package/dist/core/schema/status-token.d.ts +1 -1
- package/dist/core/schema/type-inference.d.ts +6 -8
- package/dist/core/schema/type-presets.d.ts +5 -5
- package/dist/core/schema/type-workflows.d.ts +11 -16
- package/dist/core/search/background-refresh.d.ts +6 -12
- package/dist/core/search/bm25.d.ts +11 -19
- package/dist/core/search/cache.d.ts +19 -41
- package/dist/core/search/corpus.d.ts +16 -19
- package/dist/core/search/embedding-batches.d.ts +12 -17
- package/dist/core/search/eval-thresholds.d.ts +3 -3
- package/dist/core/search/eval.d.ts +16 -34
- package/dist/core/search/http-client.d.ts +14 -18
- package/dist/core/search/providers.d.ts +22 -39
- package/dist/core/search/relevance.d.ts +14 -19
- package/dist/core/search/semantic-defaults.d.ts +4 -5
- package/dist/core/search/vector-stores.d.ts +35 -57
- package/dist/core/search/vectorization-metadata.d.ts +9 -11
- package/dist/core/sentry/helpers.d.ts +6 -31
- package/dist/core/sentry/instrument.d.ts +6 -59
- package/dist/core/session/session-state.d.ts +12 -32
- package/dist/core/shared/agent-session-context.d.ts +10 -17
- package/dist/core/shared/author.d.ts +48 -69
- package/dist/core/shared/command-line.d.ts +3 -3
- package/dist/core/shared/command-types.d.ts +3 -4
- package/dist/core/shared/constants.d.ts +14 -32
- package/dist/core/shared/error-details.d.ts +5 -18
- package/dist/core/shared/errors.d.ts +42 -83
- package/dist/core/shared/html-entity-decode.d.ts +1 -1
- package/dist/core/shared/item-metadata-contract.d.ts +2 -2
- package/dist/core/shared/lazy-module.d.ts +1 -1
- package/dist/core/shared/levenshtein.d.ts +1 -1
- package/dist/core/shared/numeric-parsers.d.ts +1 -1
- package/dist/core/shared/option-alias-visibility.d.ts +2 -2
- package/dist/core/shared/output-unicode.d.ts +1 -1
- package/dist/core/shared/primitives.d.ts +10 -10
- package/dist/core/shared/secret-rules.d.ts +7 -93
- package/dist/core/shared/serial-queue.d.ts +7 -9
- package/dist/core/shared/serialization.d.ts +1 -1
- package/dist/core/shared/split-comma-list.d.ts +4 -5
- package/dist/core/shared/text-normalization.d.ts +1 -1
- package/dist/core/shared/time.d.ts +6 -20
- package/dist/core/store/item-format-migration.d.ts +4 -5
- package/dist/core/store/item-metadata-cache.d.ts +22 -27
- package/dist/core/store/item-metadata-query-index.d.ts +20 -61
- package/dist/core/store/item-metadata-read-work.d.ts +3 -7
- package/dist/core/store/item-mutation-precondition.d.ts +19 -35
- package/dist/core/store/item-store.d.ts +18 -141
- package/dist/core/store/paths.d.ts +5 -10
- package/dist/core/store/settings-read-cache.d.ts +7 -9
- package/dist/core/store/settings-sections.d.ts +15 -19
- package/dist/core/store/settings-validator.d.ts +27 -143
- package/dist/core/store/settings-validator.js +1 -1
- package/dist/core/store/settings.d.ts +19 -94
- package/dist/core/store/sqlite-runtime.d.ts +3 -3
- package/dist/core/store/tracker-preflight.d.ts +2 -2
- package/dist/core/telemetry/consent.d.ts +2 -2
- package/dist/core/telemetry/observability.d.ts +8 -19
- package/dist/core/telemetry/policy.d.ts +8 -23
- package/dist/core/telemetry/runtime.d.ts +44 -254
- package/dist/core/test/background-runs.d.ts +35 -79
- package/dist/core/test/run-selectors.d.ts +10 -12
- package/dist/core/validate/fix-planning.d.ts +19 -28
- package/dist/core/validate/missing-by-type.d.ts +3 -4
- package/dist/core/validate/missing-link-owners.d.ts +12 -16
- package/dist/core/validate/stale-file-classification.d.ts +5 -6
- package/dist/mcp/tool-definitions.d.ts +7 -30
- package/dist/sdk/actionability.d.ts +1 -1
- package/dist/sdk/agent/closed-domain-contracts.d.ts +4 -5
- package/dist/sdk/agent/command-recovery.d.ts +9 -13
- package/dist/sdk/agent/command-suggestions.d.ts +2 -2
- package/dist/sdk/agent/create-option-policy.d.ts +2 -2
- package/dist/sdk/agent/identity-config.d.ts +13 -18
- package/dist/sdk/agent/item-addressing.d.ts +4 -5
- package/dist/sdk/agent/linked-resource-recovery.d.ts +3 -4
- package/dist/sdk/agent/refusal-closure-census.d.ts +13 -25
- package/dist/sdk/agent/refusal-closure.d.ts +8 -11
- package/dist/sdk/agent/refusal-corpus-contracts.d.ts +15 -21
- package/dist/sdk/agent/refusal-reachability.d.ts +38 -52
- package/dist/sdk/agent/subcommand-recovery.d.ts +7 -15
- package/dist/sdk/agent/task-transcript-contracts.d.ts +12 -15
- package/dist/sdk/agent/tracker-preflight-contracts.d.ts +13 -17
- package/dist/sdk/agent-capability-contracts.d.ts +19 -32
- package/dist/sdk/agent-session-context.d.ts +1 -1
- package/dist/sdk/annotations.d.ts +32 -68
- package/dist/sdk/author-attribution.d.ts +22 -33
- package/dist/sdk/authoring.d.ts +1 -19
- package/dist/sdk/cli-bootstrap.d.ts +22 -59
- package/dist/sdk/cli-contracts/agent-output-contracts.d.ts +31 -57
- package/dist/sdk/cli-contracts/command-aliases.d.ts +7 -8
- package/dist/sdk/cli-contracts/command-exit-contracts.d.ts +19 -65
- package/dist/sdk/cli-contracts/commander-mutation-options.d.ts +2 -2
- package/dist/sdk/cli-contracts/commander-types.d.ts +6 -11
- package/dist/sdk/cli-contracts/completeness.d.ts +11 -15
- package/dist/sdk/cli-contracts/enum-contracts.d.ts +25 -37
- package/dist/sdk/cli-contracts/flag-contracts.d.ts +16 -20
- package/dist/sdk/cli-contracts/flag-lexicon-contracts.d.ts +14 -19
- package/dist/sdk/cli-contracts/grammar-contracts.d.ts +29 -47
- package/dist/sdk/cli-contracts/runtime-contracts.d.ts +44 -265
- package/dist/sdk/cli-contracts/tool-option-contracts.d.ts +11 -564
- package/dist/sdk/cli-contracts/tool-schema.d.ts +18 -51
- package/dist/sdk/cli-contracts/typed-action-inputs.d.ts +18 -37
- package/dist/sdk/cli-contracts.d.ts +1 -16
- package/dist/sdk/cli-program.d.ts +2 -2
- package/dist/sdk/command-line.d.ts +3 -4
- package/dist/sdk/comments.d.ts +6 -10
- package/dist/sdk/compile-cache.d.ts +4 -5
- package/dist/sdk/completion/bash.d.ts +2 -2
- package/dist/sdk/completion/fish.d.ts +2 -2
- package/dist/sdk/completion/shared.d.ts +10 -77
- package/dist/sdk/completion/shared.js +1 -1
- package/dist/sdk/completion/zsh.d.ts +2 -2
- package/dist/sdk/completion.d.ts +2 -6
- package/dist/sdk/compose.d.ts +49 -74
- package/dist/sdk/config.d.ts +18 -94
- package/dist/sdk/config.js +1 -1
- package/dist/sdk/context/recency.d.ts +2 -2
- package/dist/sdk/context/semantic-session-attribution.d.ts +6 -25
- package/dist/sdk/context/usage-ledger.d.ts +9 -21
- package/dist/sdk/context-intent-contracts.d.ts +24 -35
- package/dist/sdk/context-intent-runtime.d.ts +7 -9
- package/dist/sdk/context-packing.d.ts +16 -34
- package/dist/sdk/context-relevance.d.ts +58 -93
- package/dist/sdk/context-signal-store.d.ts +29 -60
- package/dist/sdk/context-usage.d.ts +22 -69
- package/dist/sdk/contracts.d.ts +1 -24
- package/dist/sdk/core-governance.d.ts +1 -5
- package/dist/sdk/core.d.ts +1 -27
- package/dist/sdk/corpus-shape.d.ts +16 -28
- package/dist/sdk/define.d.ts +10 -14
- package/dist/sdk/dependencies.d.ts +32 -50
- package/dist/sdk/dependency-provenance.d.ts +19 -23
- package/dist/sdk/docs.d.ts +6 -10
- package/dist/sdk/duplicates.d.ts +8 -15
- package/dist/sdk/environment/agent-environment.d.ts +60 -101
- package/dist/sdk/environment/host-environment-errors.d.ts +1 -1
- package/dist/sdk/environment/project-runtime-compatibility.d.ts +15 -29
- package/dist/sdk/environment/source-context.d.ts +6 -7
- package/dist/sdk/environment/tracker-preflight.d.ts +1 -1
- package/dist/sdk/error-code-catalog.d.ts +9 -26
- package/dist/sdk/error-runtime.d.ts +6 -8
- package/dist/sdk/errors.d.ts +10 -17
- package/dist/sdk/eval.d.ts +11 -21
- package/dist/sdk/extension/command-options.d.ts +14 -26
- package/dist/sdk/extension/describe.d.ts +14 -19
- package/dist/sdk/extension/doctor.d.ts +8 -48
- package/dist/sdk/extension/install-plan.d.ts +12 -26
- package/dist/sdk/extension/install-runtime.d.ts +10 -11
- package/dist/sdk/extension/install-sources.d.ts +22 -104
- package/dist/sdk/extension/managed-state.d.ts +13 -18
- package/dist/sdk/extension/migrations.d.ts +22 -37
- package/dist/sdk/extension/output-ownership.d.ts +3 -30
- package/dist/sdk/extension/shared.d.ts +9 -15
- package/dist/sdk/extension/source-resolution.d.ts +13 -18
- package/dist/sdk/extension/static-inventory.d.ts +17 -21
- package/dist/sdk/extension/update-check.d.ts +7 -11
- package/dist/sdk/extension-command-context.d.ts +2 -3
- package/dist/sdk/extension-contracts.d.ts +11 -14
- package/dist/sdk/extension.d.ts +31 -192
- package/dist/sdk/files.d.ts +27 -68
- package/dist/sdk/flag-invocation-contracts.d.ts +13 -17
- package/dist/sdk/generated/generated-error-code-catalog-part-1.js +1 -1
- package/dist/sdk/generated-error-code-catalog.d.ts +1 -1
- package/dist/sdk/governance/artifact-ledgers.d.ts +9 -16
- package/dist/sdk/governance/assurance-action-contracts.d.ts +1 -1
- package/dist/sdk/governance/assurance-action.d.ts +13 -45
- package/dist/sdk/governance/assurance-mutation-error.d.ts +12 -17
- package/dist/sdk/governance/assurance-presets.d.ts +10 -21
- package/dist/sdk/governance/assurance-runtime.d.ts +5 -6
- package/dist/sdk/governance/assurance.d.ts +97 -154
- package/dist/sdk/governance/boundary-fixtures.d.ts +17 -23
- package/dist/sdk/governance/closure-timestamps.d.ts +5 -15
- package/dist/sdk/governance/coverage-assurance.d.ts +5 -6
- package/dist/sdk/governance/defect-recurrence-coverage.d.ts +13 -23
- package/dist/sdk/governance/defect-recurrence-graph.d.ts +9 -13
- package/dist/sdk/governance/defect-recurrence.d.ts +43 -67
- package/dist/sdk/governance/extension-host-version.d.ts +8 -10
- package/dist/sdk/governance/gc.d.ts +12 -20
- package/dist/sdk/governance/health/projection.d.ts +8 -23
- package/dist/sdk/governance/health.d.ts +23 -167
- package/dist/sdk/governance/hierarchy-validation.d.ts +2 -18
- package/dist/sdk/governance/linked-file-report.d.ts +6 -10
- package/dist/sdk/governance/merge-receipt-history.d.ts +12 -16
- package/dist/sdk/governance/provenance-health.d.ts +17 -23
- package/dist/sdk/governance/reindex.d.ts +13 -116
- package/dist/sdk/governance/reliability.d.ts +13 -17
- package/dist/sdk/governance/stale-work.d.ts +8 -11
- package/dist/sdk/governance/status-role-diagnostics.d.ts +4 -6
- package/dist/sdk/governance/storage-integrity.d.ts +16 -23
- package/dist/sdk/governance/upgrade.d.ts +17 -57
- package/dist/sdk/governance/validate-item-reader.d.ts +3 -11
- package/dist/sdk/governance/validate-normalization.d.ts +2 -2
- package/dist/sdk/governance/validate.d.ts +29 -175
- package/dist/sdk/governance/workflow-completeness.d.ts +5 -17
- package/dist/sdk/governance/workflow-policy.d.ts +8 -16
- package/dist/sdk/governance/workspace-position.d.ts +12 -43
- package/dist/sdk/governance.d.ts +1 -39
- package/dist/sdk/graph/adapter.d.ts +23 -41
- package/dist/sdk/graph/analytics.d.ts +20 -31
- package/dist/sdk/graph/assembly.d.ts +24 -35
- package/dist/sdk/graph/cache.d.ts +13 -25
- package/dist/sdk/graph/cardinality-integrity.d.ts +4 -6
- package/dist/sdk/graph/centrality.d.ts +14 -20
- package/dist/sdk/graph/conformance.d.ts +12 -19
- package/dist/sdk/graph/deadline-scheduling.d.ts +14 -20
- package/dist/sdk/graph/durable-cache.d.ts +11 -14
- package/dist/sdk/graph/governance-contracts.d.ts +2 -2
- package/dist/sdk/graph/governance.d.ts +22 -36
- package/dist/sdk/graph/hierarchy-integrity.d.ts +18 -26
- package/dist/sdk/graph/index.d.ts +1 -17
- package/dist/sdk/graph/lifecycle-coverage.d.ts +8 -12
- package/dist/sdk/graph/mutation-advisory.d.ts +5 -16
- package/dist/sdk/graph/query-contracts.d.ts +1 -2
- package/dist/sdk/graph/remediation.d.ts +11 -18
- package/dist/sdk/graph/run.d.ts +73 -115
- package/dist/sdk/graph/scheduling.d.ts +8 -15
- package/dist/sdk/graph/traversal.d.ts +9 -15
- package/dist/sdk/graph/workspace-relationship-kind-registry.d.ts +2 -2
- package/dist/sdk/graph.d.ts +1 -12
- package/dist/sdk/guide-topics.d.ts +7 -10
- package/dist/sdk/guide.d.ts +21 -43
- package/dist/sdk/history/attestation-command.d.ts +7 -10
- package/dist/sdk/history/attestation-contract.d.ts +19 -34
- package/dist/sdk/history/attestation.d.ts +2 -3
- package/dist/sdk/history/maintenance.d.ts +17 -27
- package/dist/sdk/history/salvage.d.ts +5 -22
- package/dist/sdk/history/subject.d.ts +5 -11
- package/dist/sdk/history-analytics.d.ts +28 -59
- package/dist/sdk/history-compact.d.ts +25 -66
- package/dist/sdk/history-provenance.d.ts +16 -33
- package/dist/sdk/history-read.d.ts +9 -16
- package/dist/sdk/history-redact.d.ts +19 -74
- package/dist/sdk/history-redact.js +1 -1
- package/dist/sdk/history-repair.d.ts +26 -71
- package/dist/sdk/improvement-ledger-validation.d.ts +2 -2
- package/dist/sdk/improvement-ledger.d.ts +20 -39
- package/dist/sdk/index.d.ts +1 -268
- package/dist/sdk/init-agent-guidance.d.ts +13 -68
- package/dist/sdk/init.d.ts +24 -94
- package/dist/sdk/invocation-author.d.ts +1 -1
- package/dist/sdk/item-children.d.ts +10 -13
- package/dist/sdk/item-metadata-index.d.ts +1 -2
- package/dist/sdk/item-schedule.d.ts +8 -9
- package/dist/sdk/item-transaction.d.ts +46 -90
- package/dist/sdk/learnings.d.ts +6 -10
- package/dist/sdk/lifecycle/append.d.ts +7 -9
- package/dist/sdk/lifecycle/claim.d.ts +26 -42
- package/dist/sdk/lifecycle/cli-input.d.ts +1 -1
- package/dist/sdk/lifecycle/close-many.d.ts +14 -65
- package/dist/sdk/lifecycle/close.d.ts +10 -26
- package/dist/sdk/lifecycle/copy.d.ts +6 -10
- package/dist/sdk/lifecycle/create.d.ts +15 -83
- package/dist/sdk/lifecycle/delete.d.ts +7 -9
- package/dist/sdk/lifecycle/focus.d.ts +9 -11
- package/dist/sdk/lifecycle/item-revision.d.ts +25 -45
- package/dist/sdk/lifecycle/lifecycle-transitions.d.ts +4 -5
- package/dist/sdk/lifecycle/mutation-command-options.d.ts +6 -9
- package/dist/sdk/lifecycle/plan-mutation-receipt.d.ts +5 -13
- package/dist/sdk/lifecycle/plan.d.ts +34 -74
- package/dist/sdk/lifecycle/reopen.d.ts +8 -14
- package/dist/sdk/lifecycle/restore.d.ts +9 -38
- package/dist/sdk/lifecycle/shared-unset-fields.d.ts +23 -614
- package/dist/sdk/lifecycle/start-blockers.d.ts +7 -27
- package/dist/sdk/lifecycle/structured-mutation-plan.d.ts +8 -16
- package/dist/sdk/lifecycle/task-composition.d.ts +6 -14
- package/dist/sdk/lifecycle/update-many.d.ts +15 -65
- package/dist/sdk/lifecycle/update.d.ts +21 -104
- package/dist/sdk/lifecycle/workflow-transition.d.ts +2 -11
- package/dist/sdk/lifecycle-completion.d.ts +11 -14
- package/dist/sdk/lifecycle-policy.d.ts +23 -32
- package/dist/sdk/linked-artifacts.d.ts +31 -41
- package/dist/sdk/mcp/apps.d.ts +12 -27
- package/dist/sdk/mcp/authorization.d.ts +30 -63
- package/dist/sdk/mcp/discovery.d.ts +23 -52
- package/dist/sdk/mcp/executable.d.ts +3 -10
- package/dist/sdk/mcp/interactions.d.ts +25 -47
- package/dist/sdk/mcp/protocol.d.ts +32 -64
- package/dist/sdk/mcp/skills.d.ts +21 -71
- package/dist/sdk/mcp/subscriptions.d.ts +14 -28
- package/dist/sdk/mcp/tasks.d.ts +21 -55
- package/dist/sdk/mcp/transport.d.ts +7 -15
- package/dist/sdk/merge/driver.d.ts +13 -37
- package/dist/sdk/merge/index.d.ts +1 -6
- package/dist/sdk/merge/install.d.ts +27 -55
- package/dist/sdk/merge/receipt-operation.d.ts +5 -6
- package/dist/sdk/merge/receipt-schema.d.ts +6 -9
- package/dist/sdk/merge/receipts.d.ts +29 -79
- package/dist/sdk/merge/reconcile.d.ts +9 -18
- package/dist/sdk/merge/three-way.d.ts +21 -30
- package/dist/sdk/merge.d.ts +1 -5
- package/dist/sdk/mutation-events.d.ts +21 -53
- package/dist/sdk/mutation-guard.d.ts +15 -135
- package/dist/sdk/notes.d.ts +6 -10
- package/dist/sdk/output/fit-envelope.d.ts +21 -28
- package/dist/sdk/output/list-envelope.d.ts +1 -1
- package/dist/sdk/output/table-rows.d.ts +8 -12
- package/dist/sdk/output-contracts.d.ts +11 -14
- package/dist/sdk/output-projection.d.ts +18 -130
- package/dist/sdk/output-token-accounting.d.ts +8 -15
- package/dist/sdk/output.d.ts +10 -15
- package/dist/sdk/ownership-source.d.ts +4 -5
- package/dist/sdk/package-import-adapters.d.ts +27 -37
- package/dist/sdk/package-migrations.d.ts +2 -2
- package/dist/sdk/package-runtime-options.d.ts +3 -3
- package/dist/sdk/pagination.d.ts +12 -24
- package/dist/sdk/profile.d.ts +25 -42
- package/dist/sdk/provenance.d.ts +21 -32
- package/dist/sdk/query/activity.d.ts +24 -77
- package/dist/sdk/query/aggregate.d.ts +20 -95
- package/dist/sdk/query/calendar.d.ts +26 -74
- package/dist/sdk/query/complete-list.d.ts +19 -35
- package/dist/sdk/query/context.d.ts +69 -240
- package/dist/sdk/query/declared-blockers.d.ts +2 -9
- package/dist/sdk/query/duplicate-candidates.d.ts +3 -5
- package/dist/sdk/query/get.d.ts +13 -55
- package/dist/sdk/query/history.d.ts +18 -29
- package/dist/sdk/query/item-filter-options.d.ts +7 -12
- package/dist/sdk/query/list-filter-shared.d.ts +4 -8
- package/dist/sdk/query/list.d.ts +44 -168
- package/dist/sdk/query/multi-value-filters.d.ts +7 -9
- package/dist/sdk/query/next-ranking-policy.d.ts +4 -10
- package/dist/sdk/query/next-ready-budget.d.ts +4 -5
- package/dist/sdk/query/next.d.ts +27 -86
- package/dist/sdk/query/parsers.d.ts +4 -6
- package/dist/sdk/query/projection-contracts.d.ts +12 -21
- package/dist/sdk/query/search/corpus.d.ts +5 -20
- package/dist/sdk/query/search/filters.d.ts +5 -17
- package/dist/sdk/query/search/input.d.ts +4 -9
- package/dist/sdk/query/search/lexical.d.ts +5 -9
- package/dist/sdk/query/search/response.d.ts +5 -22
- package/dist/sdk/query/search/semantic.d.ts +24 -170
- package/dist/sdk/query/search/types.d.ts +19 -73
- package/dist/sdk/query/search-contracts.d.ts +24 -34
- package/dist/sdk/query/search-pagination.d.ts +5 -24
- package/dist/sdk/query/search-rendering.d.ts +8 -32
- package/dist/sdk/query/search.d.ts +3 -63
- package/dist/sdk/query/workspace-contracts.d.ts +2 -2
- package/dist/sdk/query.d.ts +1 -43
- package/dist/sdk/read-output/continuation.d.ts +5 -6
- package/dist/sdk/read-output/options.d.ts +3 -8
- package/dist/sdk/read-output/session-result.d.ts +2 -33
- package/dist/sdk/read-output/tail-retention.d.ts +6 -8
- package/dist/sdk/read-output-budget.d.ts +14 -16
- package/dist/sdk/read-output-contracts.d.ts +59 -103
- package/dist/sdk/read-output-rows.d.ts +5 -9
- package/dist/sdk/read-output-session.d.ts +11 -14
- package/dist/sdk/relationship-analytics.d.ts +17 -37
- package/dist/sdk/relationship-context.d.ts +15 -33
- package/dist/sdk/relationship-history.d.ts +29 -50
- package/dist/sdk/relationship-kinds/contract.d.ts +11 -12
- package/dist/sdk/relationship-migration.d.ts +6 -10
- package/dist/sdk/relationships.d.ts +22 -34
- package/dist/sdk/reproducibility/process.d.ts +7 -11
- package/dist/sdk/runtime/context.d.ts +6 -22
- package/dist/sdk/runtime/schema-preview.d.ts +1 -1
- package/dist/sdk/runtime-input.d.ts +9 -20
- package/dist/sdk/runtime-primitives.d.ts +3 -82
- package/dist/sdk/runtime-public-contracts.d.ts +30 -50
- package/dist/sdk/runtime.d.ts +77 -302
- package/dist/sdk/scheduling-shortcuts.d.ts +8 -12
- package/dist/sdk/schema-migration.d.ts +18 -80
- package/dist/sdk/schema.d.ts +89 -192
- package/dist/sdk/search-refresh-worker.d.ts +1 -1
- package/dist/sdk/similarity-scoring.d.ts +6 -8
- package/dist/sdk/similarity.d.ts +33 -64
- package/dist/sdk/start-task-status.d.ts +2 -2
- package/dist/sdk/stats.d.ts +13 -48
- package/dist/sdk/structured-mutations.d.ts +18 -26
- package/dist/sdk/telemetry-flush.d.ts +1 -1
- package/dist/sdk/telemetry.d.ts +14 -20
- package/dist/sdk/templates.d.ts +14 -35
- package/dist/sdk/test/batch.d.ts +10 -25
- package/dist/sdk/test/execution.d.ts +44 -209
- package/dist/sdk/test/json-path.d.ts +2 -5
- package/dist/sdk/test/linked-command-detection.d.ts +10 -25
- package/dist/sdk/test/measurements.d.ts +10 -13
- package/dist/sdk/test/parsers.d.ts +16 -20
- package/dist/sdk/test/prerequisites.d.ts +2 -3
- package/dist/sdk/test/runs.d.ts +19 -52
- package/dist/sdk/test/trust.d.ts +8 -12
- package/dist/sdk/test/update.d.ts +9 -25
- package/dist/sdk/testing.d.ts +97 -206
- package/dist/sdk/traceability/source-traceability.d.ts +25 -56
- package/dist/sdk/tracker-root-discovery.d.ts +1 -1
- package/dist/sdk/workspace-contracts-cache.d.ts +2 -2
- package/dist/sdk/workspace-contracts.d.ts +8 -14
- package/dist/sdk/workspace-memory.d.ts +24 -42
- package/dist/sdk/workspace-recipe.d.ts +10 -14
- package/dist/sdk/workspace-snapshot.d.ts +26 -53
- package/dist/sdk/workspace-transaction-gc.d.ts +12 -16
- package/dist/sdk/workspace-transaction.d.ts +26 -40
- package/dist/sdk/workspace.d.ts +8 -10
- package/dist/types/index.d.ts +1 -1
- package/dist/types.d.ts +210 -353
- package/docs/COMMANDS.md +8 -0
- package/docs/CONFIGURATION.md +17 -0
- package/docs/DIAGNOSTIC_OUTPUT_CONTRACTS.md +28 -9
- package/docs/RELEASING.md +25 -0
- package/docs/SDK.md +17 -2
- package/docs/TESTING.md +11 -0
- package/marketplace.json +1 -1
- 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/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/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-claude/package.json +1 -1
- package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
- package/plugins/pm-codex/package.json +1 -1
- package/plugins/pm-codex/plugin.json +1 -1
- package/runtime-dependencies.json +1 -1
- package/scripts/finalize-build.mjs +41 -4
- package/dist/cli-bundle/chunks/chunk-JYQXIC6C.js +0 -3
- package/dist/cli-bundle/chunks/chunk-LVDFPGD7.js +0 -3
- package/dist/cli-bundle/chunks/chunk-UFIM5ZC5.js +0 -6
- package/dist/cli-bundle/chunks/item-transaction-XBIN4KYM.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-HLQOGAWG.js +0 -26
- package/dist/cli-bundle/focused-chunks/chunk-IB6TCE7N.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-JU62TKJP.js +0 -82
- package/dist/cli-bundle/focused-chunks/chunk-NUFO3OR6.js +0 -44
|
@@ -4,30 +4,28 @@
|
|
|
4
4
|
*/
|
|
5
5
|
export declare const EXTENSION_LONG_FLAG_PATTERN:RegExp;
|
|
6
6
|
/** Canonical identity and value syntax of a supported long flag declaration. */
|
|
7
|
-
export interface ExtensionLongFlagSpelling
|
|
7
|
+
export interface ExtensionLongFlagSpelling{
|
|
8
8
|
/** Bare long option identity used for dispatch and discovery. */
|
|
9
9
|
name:string;
|
|
10
10
|
/** Inline value label, or null for a bare declaration. */
|
|
11
|
-
valueName:string
|
|
11
|
+
valueName:string|null;
|
|
12
12
|
/** Whether the inline value uses optional brackets. */
|
|
13
|
-
optional:boolean;
|
|
14
|
-
}
|
|
13
|
+
optional:boolean;}
|
|
15
14
|
/** Parse supported legacy placeholder syntax without duplicating its option identity. */
|
|
16
|
-
export declare function parseExtensionLongFlagToken(value:unknown):ExtensionLongFlagSpelling
|
|
15
|
+
export declare function parseExtensionLongFlagToken(value:unknown):ExtensionLongFlagSpelling|null;
|
|
17
16
|
/** Resolve supported canonical names while preserving trimmed legacy spellings for permissive consumers. Validation remains separate. */
|
|
18
|
-
export declare function resolveExtensionLongFlagName(value:unknown):string
|
|
17
|
+
export declare function resolveExtensionLongFlagName(value:unknown):string|null;
|
|
19
18
|
/** Machine-readable failure returned for one invalid extension flag token. */
|
|
20
|
-
export type ExtensionFlagTokenFailure
|
|
19
|
+
export type ExtensionFlagTokenFailure="host_owned_flag_collision"|"malformed_long_flag";
|
|
21
20
|
/** Invalid token and failure classification returned for one flag definition. */
|
|
22
|
-
export interface ExtensionFlagTokenFinding
|
|
21
|
+
export interface ExtensionFlagTokenFinding{
|
|
23
22
|
/** Trimmed long or short token that failed validation. */
|
|
24
23
|
token:string;
|
|
25
24
|
/** Stable failure classification shared by lint and activation. */
|
|
26
|
-
failure:ExtensionFlagTokenFailure;
|
|
27
|
-
}
|
|
25
|
+
failure:ExtensionFlagTokenFailure;}
|
|
28
26
|
/** Describe why a declared long flag cannot be registered, or `null` when valid. */
|
|
29
|
-
export declare function validateExtensionLongFlagToken(value:unknown):ExtensionFlagTokenFailure
|
|
27
|
+
export declare function validateExtensionLongFlagToken(value:unknown):ExtensionFlagTokenFailure|null;
|
|
30
28
|
/** Find the first host-owned or malformed token in one extension flag definition. */
|
|
31
|
-
export declare function findExtensionFlagTokenFailure(long:unknown,short:unknown):ExtensionFlagTokenFinding
|
|
29
|
+
export declare function findExtensionFlagTokenFailure(long:unknown,short:unknown):ExtensionFlagTokenFinding|null;
|
|
32
30
|
/** Render the shared actionable diagnostic used by preflight and activation. */
|
|
33
|
-
export declare function describeExtensionLongFlagFailure(token:string,failure:ExtensionFlagTokenFailure):string;
|
|
31
|
+
export declare function describeExtensionLongFlagFailure(token:string,failure:ExtensionFlagTokenFailure):string;
|
|
@@ -1,37 +1,35 @@
|
|
|
1
1
|
/** Shared scalar coercion and value-token grammar for contributed flags. */
|
|
2
|
-
import type
|
|
2
|
+
import type{FlagDefinition}from "./extension-types.js";
|
|
3
3
|
/** Canonical scalar value kinds accepted by extension command flag definitions. */
|
|
4
|
-
export type FlagValueKind
|
|
4
|
+
export type FlagValueKind="string"|"number"|"boolean";
|
|
5
5
|
/** Resolve a declared flag value type (string) to its canonical kind, or `null` when it is not a recognized type/alias. Matching is trim- and case-insensitive. */
|
|
6
|
-
export declare function resolveFlagValueKind(raw:unknown):FlagValueKind
|
|
6
|
+
export declare function resolveFlagValueKind(raw:unknown):FlagValueKind|null;
|
|
7
7
|
/** Value-token grammar retained separately from scalar coercion and required flag presence. */
|
|
8
|
-
export interface ExtensionFlagValueContract
|
|
8
|
+
export interface ExtensionFlagValueContract{
|
|
9
9
|
/** Canonical kind after coercion; null means the declaration has no explicit scalar type. */
|
|
10
|
-
value_type:FlagValueKind
|
|
10
|
+
value_type:FlagValueKind|null;
|
|
11
11
|
/** Whether argv consumes no value, a mandatory value, or an optional value. */
|
|
12
|
-
value_arity:"none"
|
|
12
|
+
value_arity:"none"|"required"|"optional";
|
|
13
13
|
/** Display label for a consumed value; null for switches. */
|
|
14
|
-
value_name:string
|
|
15
|
-
}
|
|
14
|
+
value_name:string|null;}
|
|
16
15
|
/** Preserve legacy bool value tokens and inline optionality before canonicalizing the scalar kind. */
|
|
17
16
|
export declare function resolveExtensionFlagValueContract(definition:Readonly<FlagDefinition>):ExtensionFlagValueContract;
|
|
18
17
|
/** Flatten a `list` flag value (or default) into its individual entries the same way the runtime does: nested arrays are flattened and comma-joined strings are split, with surrounding whitespace trimmed and empty segments dropped. No type coercion is applied. Shared by the CLI coercion path and the registration-time default validator so the two never disagree. */
|
|
19
18
|
export declare function flattenFlagListValue(value:unknown):unknown[];
|
|
20
19
|
/** Whether a scalar flag default would cleanly coerce under the declared kind, mirroring the runtime coercion rules in `coerceLooseCommandOptionsWithFlagDefinitions`. Used to reject contradictory definitions (e.g. `value_type: "number"` with `default: "abc"`) at registration instead of letting an untyped value pass through to activation. */
|
|
21
|
-
export declare function isFlagDefaultValueCoercible(value:string
|
|
20
|
+
export declare function isFlagDefaultValueCoercible(value:string|number|boolean,kind:FlagValueKind):boolean;
|
|
22
21
|
/** One refused scalar token, described for a typed usage error. */
|
|
23
|
-
export interface FlagScalarValueFailure
|
|
22
|
+
export interface FlagScalarValueFailure{
|
|
24
23
|
/** Declared kind the token failed to satisfy. */
|
|
25
24
|
kind:Exclude<FlagValueKind,"string">;
|
|
26
25
|
/** Original token as the caller supplied it (`true` when the flag carried no value). */
|
|
27
26
|
received:unknown;
|
|
28
27
|
/** Accepted token grammar, for the recovery message. */
|
|
29
|
-
expected:string;
|
|
30
|
-
}
|
|
28
|
+
expected:string;}
|
|
31
29
|
/**
|
|
32
30
|
* Describe why a coerced scalar is still malformed under a `number` or
|
|
33
31
|
* `boolean` kind, or return null when it coerced cleanly. A value-less
|
|
34
32
|
* occurrence (`true`) of a `number` flag is malformed; a value-less occurrence
|
|
35
33
|
* of a `boolean` flag is switch presence and is accepted.
|
|
36
34
|
*/
|
|
37
|
-
export declare function describeFlagScalarValueFailure(value:unknown,kind:Exclude<FlagValueKind,"string">):FlagScalarValueFailure
|
|
35
|
+
export declare function describeFlagScalarValueFailure(value:unknown,kind:Exclude<FlagValueKind,"string">):FlagScalarValueFailure|null;
|
|
@@ -1,30 +1,29 @@
|
|
|
1
|
-
import
|
|
2
|
-
import type { ItemMetadata } from "../../types/index.js";
|
|
1
|
+
import{type CommandHandlerContext,type CommandHandlerResult,type CommandOverrideContext,type CommandOverrideResult,type ExtensionCommandRegistry,type ExtensionHookRegistry,type ExtensionParserRegistry,type ExtensionPreflightRegistry,type ExtensionRegistrationRegistry,type ExtensionRendererRegistry,type ExtensionServiceName,type ExtensionServiceRegistry,type AfterCommandAffectedItem,type OnIndexHookContext,type OnReadHookContext,type OnWriteHookContext,type BeforeMutationHookContext,type OutputRendererFormat,type ParserOverrideContext,type ParserOverrideResult,type PortableWorkspaceContext,type PreflightOverrideContext,type PreflightOverrideResult,type RendererOverrideResult,type ServiceOverrideResult}from "./loader.js";import type{ItemMetadata}from "../../types/index.js";
|
|
3
2
|
/** Run one embedded request with extension registries isolated from concurrent workspaces. */
|
|
4
|
-
export declare function runWithIsolatedExtensionRuntime<T>(run:()
|
|
3
|
+
export declare function runWithIsolatedExtensionRuntime<T>(run:()=> Promise<T>):Promise<T>;
|
|
5
4
|
/**
|
|
6
5
|
* Resolve portable workspace coordinates without reading tracker state.
|
|
7
6
|
*
|
|
8
7
|
* Linked-test runners set `PM_SOURCE_WORKSPACE_ROOT` before swapping `PM_PATH`,
|
|
9
8
|
* preserving source VCS identity while every mutation remains sandboxed.
|
|
10
9
|
*/
|
|
11
|
-
export declare function resolvePortableWorkspaceContext(pmRoot:string
|
|
10
|
+
export declare function resolvePortableWorkspaceContext(pmRoot:string|undefined):PortableWorkspaceContext;
|
|
12
11
|
/** Implements set active extension hooks for the public runtime surface of this module. */
|
|
13
|
-
export declare function setActiveExtensionHooks(hooks:ExtensionHookRegistry
|
|
12
|
+
export declare function setActiveExtensionHooks(hooks:ExtensionHookRegistry|null):void;
|
|
14
13
|
/** Implements set active extension commands for the public runtime surface of this module. */
|
|
15
|
-
export declare function setActiveExtensionCommands(commands:ExtensionCommandRegistry
|
|
14
|
+
export declare function setActiveExtensionCommands(commands:ExtensionCommandRegistry|null):void;
|
|
16
15
|
/** Implements set active extension parsers for the public runtime surface of this module. */
|
|
17
|
-
export declare function setActiveExtensionParsers(parsers:ExtensionParserRegistry
|
|
16
|
+
export declare function setActiveExtensionParsers(parsers:ExtensionParserRegistry|null):void;
|
|
18
17
|
/** Implements set active extension preflight for the public runtime surface of this module. */
|
|
19
|
-
export declare function setActiveExtensionPreflight(preflight:ExtensionPreflightRegistry
|
|
18
|
+
export declare function setActiveExtensionPreflight(preflight:ExtensionPreflightRegistry|null):void;
|
|
20
19
|
/** Implements set active extension services for the public runtime surface of this module. */
|
|
21
|
-
export declare function setActiveExtensionServices(services:ExtensionServiceRegistry
|
|
20
|
+
export declare function setActiveExtensionServices(services:ExtensionServiceRegistry|null):void;
|
|
22
21
|
/** Implements set active extension renderers for the public runtime surface of this module. */
|
|
23
|
-
export declare function setActiveExtensionRenderers(renderers:ExtensionRendererRegistry
|
|
22
|
+
export declare function setActiveExtensionRenderers(renderers:ExtensionRendererRegistry|null):void;
|
|
24
23
|
/** Implements set active extension registrations for the public runtime surface of this module. */
|
|
25
|
-
export declare function setActiveExtensionRegistrations(registrations:ExtensionRegistrationRegistry
|
|
24
|
+
export declare function setActiveExtensionRegistrations(registrations:ExtensionRegistrationRegistry|null):void;
|
|
26
25
|
/** Implements get active extension registrations for the public runtime surface of this module. */
|
|
27
|
-
export declare function getActiveExtensionRegistrations():ExtensionRegistrationRegistry
|
|
26
|
+
export declare function getActiveExtensionRegistrations():ExtensionRegistrationRegistry|null;
|
|
28
27
|
/**
|
|
29
28
|
* Clear every request-local or module-level active-extension registry in one step.
|
|
30
29
|
*
|
|
@@ -35,9 +34,9 @@ export declare function getActiveExtensionRegistrations():ExtensionRegistrationR
|
|
|
35
34
|
*/
|
|
36
35
|
export declare function resetActiveExtensionRuntimeState():void;
|
|
37
36
|
/** Implements set active command context for the public runtime surface of this module. */
|
|
38
|
-
export declare function setActiveCommandContext(context:Omit<CommandOverrideContext,"result"
|
|
37
|
+
export declare function setActiveCommandContext(context:Omit<CommandOverrideContext,"result">|null):void;
|
|
39
38
|
/** Return a defensive snapshot of the current invocation's command context. */
|
|
40
|
-
export declare function getActiveCommandContext():Omit<CommandOverrideContext,"result"
|
|
39
|
+
export declare function getActiveCommandContext():Omit<CommandOverrideContext,"result">|null;
|
|
41
40
|
/**
|
|
42
41
|
* Prove that the active command has no extension execution surface. Unrelated
|
|
43
42
|
* command registrations are harmless; hooks, services, renderers, migrations,
|
|
@@ -54,7 +53,7 @@ export declare function recordAfterCommandAffectedItem(item:AfterCommandAffected
|
|
|
54
53
|
/** Implements project after command item snapshot for the public runtime surface of this module. */
|
|
55
54
|
export declare function projectAfterCommandItemSnapshot(metadata:ItemMetadata,changedFields:readonly string[]):Partial<ItemMetadata>;
|
|
56
55
|
/** Implements consume after command affected items for the public runtime surface of this module. */
|
|
57
|
-
export declare function consumeAfterCommandAffectedItems():AfterCommandAffectedItem[]
|
|
56
|
+
export declare function consumeAfterCommandAffectedItems():AfterCommandAffectedItem[]|undefined;
|
|
58
57
|
/** Implements clear active extension hooks for the public runtime surface of this module. */
|
|
59
58
|
export declare function clearActiveExtensionHooks():void;
|
|
60
59
|
/** Implements run active on write hooks for the public runtime surface of this module. */
|
|
@@ -80,8 +79,4 @@ export declare function runActiveRendererOverride(format:OutputRendererFormat,re
|
|
|
80
79
|
/** Implements run active service override for the public runtime surface of this module. */
|
|
81
80
|
export declare function runActiveServiceOverride(service:ExtensionServiceName,payload:unknown):Promise<ServiceOverrideResult>;
|
|
82
81
|
/** Implements run active service override sync for the public runtime surface of this module. */
|
|
83
|
-
export declare function runActiveServiceOverrideSync(service:ExtensionServiceName,payload:unknown):ServiceOverrideResult;
|
|
84
|
-
export * from "./loader.js";
|
|
85
|
-
export * from "./command-hook-context.js";
|
|
86
|
-
export { createSerialQueue } from "../shared/serial-queue.js";
|
|
87
|
-
export { EXTENSION_CAPABILITY_REGISTRATION_SURFACES,collectUsedExtensionCapabilities,reconcileExtensionCapabilityUsage,type CollectUsedExtensionCapabilitiesOptions,type ExtensionCapabilityUsageReconciliation,} from "./capability-usage.js";
|
|
82
|
+
export declare function runActiveServiceOverrideSync(service:ExtensionServiceName,payload:unknown):ServiceOverrideResult;export * from "./loader.js";export * from "./command-hook-context.js";export{createSerialQueue}from "../shared/serial-queue.js";export{EXTENSION_CAPABILITY_REGISTRATION_SURFACES,collectUsedExtensionCapabilities,reconcileExtensionCapabilityUsage,type CollectUsedExtensionCapabilitiesOptions,type ExtensionCapabilityUsageReconciliation,}from "./capability-usage.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{type RuntimeFieldType}from "../../types/index.js";
|
|
2
2
|
/**
|
|
3
3
|
* Canonical coercion kinds accepted for extension-registered custom item fields.
|
|
4
4
|
*
|
|
@@ -6,10 +6,10 @@ import { type RuntimeFieldType } from "../../types/index.js";
|
|
|
6
6
|
* value is later coerced by that kind (see `coerceRegisteredFieldValue`). Keep
|
|
7
7
|
* this list in lock-step with the coercion switch in `item-fields.ts`.
|
|
8
8
|
*/
|
|
9
|
-
export declare const KNOWN_ITEM_FIELD_TYPES:readonly
|
|
9
|
+
export declare const KNOWN_ITEM_FIELD_TYPES:readonly["string","number","boolean","string_array","array","object"];
|
|
10
10
|
/** Restricts known item field type values accepted by command, SDK, and storage contracts. */
|
|
11
|
-
export type KnownItemFieldType
|
|
11
|
+
export type KnownItemFieldType=RuntimeFieldType;
|
|
12
12
|
/** Normalize a declared field type to its canonical kind, or `null` when the value is not a known type. Matching is trim- and case-insensitive. */
|
|
13
|
-
export declare function normalizeItemFieldType(value:string):KnownItemFieldType
|
|
13
|
+
export declare function normalizeItemFieldType(value:string):KnownItemFieldType|null;
|
|
14
14
|
/** Suggest a known field type for a typo'd declaration (e.g. `"strnig"` -> `"string"`), using the shared OSA Damerau–Levenshtein helper so adjacent transpositions count as a single edit. Returns the first canonical type within the proportional edit budget (in declaration order — the kinds are distinct enough that at most one matches), or `null` when nothing is close enough. */
|
|
15
|
-
export declare function suggestKnownItemFieldType(value:string):KnownItemFieldType
|
|
15
|
+
export declare function suggestKnownItemFieldType(value:string):KnownItemFieldType|null;
|
|
@@ -3,20 +3,17 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Implements extension runtime contracts and governance for Item Fields.
|
|
5
5
|
*/
|
|
6
|
-
import type
|
|
7
|
-
import { type PmCliErrorContext } from "../shared/errors.js";
|
|
6
|
+
import type{ExtensionRegistrationRegistry}from "./loader.js";import{type PmCliErrorContext}from "../shared/errors.js";
|
|
8
7
|
/** Item metadata keys extension-provided fields may never shadow, exposed without mutation methods. */
|
|
9
8
|
export declare const RESERVED_ITEM_FIELD_NAMES:ReadonlySet<string>;
|
|
10
9
|
/** Implements collect registered item field names for the public runtime surface of this module. */
|
|
11
|
-
export declare function collectRegisteredItemFieldNames(registrations:ExtensionRegistrationRegistry
|
|
10
|
+
export declare function collectRegisteredItemFieldNames(registrations:ExtensionRegistrationRegistry|null):string[];
|
|
12
11
|
/**
|
|
13
12
|
* Parse typed assignments using active extension declarations into a new object.
|
|
14
13
|
* Reserved keys name their dedicated core flags; unknown keys identify the
|
|
15
14
|
* rejected input separately from legal registered keys. Parsing never writes
|
|
16
15
|
* tracker state, so a failed assignment cannot persist partial metadata.
|
|
17
16
|
*/
|
|
18
|
-
export declare function parseRegisteredItemFieldAssignments(rawFields:string[]
|
|
17
|
+
export declare function parseRegisteredItemFieldAssignments(rawFields:string[]|undefined,registrations:ExtensionRegistrationRegistry|null,resolveCoreFieldRecovery?:(field:string)=> Pick<PmCliErrorContext,"recovery"|"nextSteps">,resolveSchemaFieldRecovery?:(field:string)=> Pick<PmCliErrorContext,"recovery"|"nextSteps">|undefined):Record<string,unknown>;
|
|
19
18
|
/** Implements apply registered item field defaults and validation for the public runtime surface of this module. */
|
|
20
|
-
export declare function applyRegisteredItemFieldDefaultsAndValidation(itemMetadata:Record<string,unknown>,registrations:ExtensionRegistrationRegistry
|
|
21
|
-
skipDefaultFields?:ReadonlySet<string>;
|
|
22
|
-
}):void;
|
|
19
|
+
export declare function applyRegisteredItemFieldDefaultsAndValidation(itemMetadata:Record<string,unknown>,registrations:ExtensionRegistrationRegistry|null,options?:{skipDefaultFields?:ReadonlySet<string>;}):void;
|
|
@@ -1,38 +1,12 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import { type DiscoverExtensionsOptions,type EffectiveExtension,type ExtensionActivationResult,type ExtensionApi,type ExtensionCommandRegistry,type ExtensionDeactivationOptions,type ExtensionDeactivationResult,type ExtensionDiscoveryResult,type ExtensionHookRegistry,type ExtensionLayer,type ExtensionLoadResult,type ExtensionManifest,type ExtensionParserRegistry,type ExtensionPreflightRegistry,type ExtensionRegistrationCounts,type ExtensionRegistrationRegistry,type ExtensionRendererRegistry,type ExtensionServiceRegistry,type FailedExtensionActivation,type LoadedExtension,type PmMaxVersionExceededMode } from "./extension-types.js";
|
|
3
|
-
import { parseExtensionManifestDocument } from "./manifest-parser.js";
|
|
4
|
-
import { assertFlagValueTypeAndDefault,normalizeCommandDefinitionArguments,resolveCommandDefinitionAction,validateItemFieldDefinitions } from "./registration-contracts.js";
|
|
5
|
-
import { assertOptionalStringField,normalizeOptionalStringArrayField } from "./registration-validation.js";
|
|
6
|
-
import { createRegistrationValidationError,extractRegistrationValidationTrace,normalizeRegistrationRecord,normalizeRegistrationRecordList,normalizeRuntimeRegistrationRecord,sanitizeRegistrationValue } from "./registration-values.js";
|
|
7
|
-
import { compareComparableVersions,parseComparableVersion } from "./version-compat.js";
|
|
8
|
-
export { parseLegacyExtensionCapabilityAliasWarning,parseUnknownExtensionCapabilityWarning } from "./extension-capability-aliases.js";
|
|
9
|
-
export { createEmptyExtensionCommandRegistry,createEmptyExtensionHookRegistry,createEmptyExtensionParserRegistry,createEmptyExtensionPreflightRegistry,createEmptyExtensionRegistrationRegistry,createEmptyExtensionRendererRegistry,createEmptyExtensionServiceRegistry } from "./extension-registries.js";
|
|
10
|
-
export { runAfterCommandHooks,runBeforeCommandHooks,runBeforeMutationHooks,runCommandHandler,runCommandOverride,runOnIndexHooks,runOnReadHooks,runOnWriteHooks,runParserOverride,runPreflightOverride,runRendererOverride,runServiceOverride,runServiceOverrideSync } from "./extension-hook-runtime.js";
|
|
11
|
-
export * from "./extension-types.js";
|
|
12
|
-
export { DEFAULT_EXTENSION_PRIORITY,parseExtensionManifestDocument } from "./manifest-parser.js";
|
|
1
|
+
import{type NormalizedExtensionPolicy}from "./extension-policy.js";import{type DiscoverExtensionsOptions,type EffectiveExtension,type ExtensionActivationResult,type ExtensionApi,type ExtensionCommandRegistry,type ExtensionDeactivationOptions,type ExtensionDeactivationResult,type ExtensionDiscoveryResult,type ExtensionHookRegistry,type ExtensionLayer,type ExtensionLoadResult,type ExtensionManifest,type ExtensionParserRegistry,type ExtensionPreflightRegistry,type ExtensionRegistrationCounts,type ExtensionRegistrationRegistry,type ExtensionRendererRegistry,type ExtensionServiceRegistry,type FailedExtensionActivation,type LoadedExtension,type PmMaxVersionExceededMode}from "./extension-types.js";import{parseExtensionManifestDocument}from "./manifest-parser.js";import{assertFlagValueTypeAndDefault,normalizeCommandDefinitionArguments,resolveCommandDefinitionAction,validateItemFieldDefinitions}from "./registration-contracts.js";import{assertOptionalStringField,normalizeOptionalStringArrayField}from "./registration-validation.js";import{createRegistrationValidationError,extractRegistrationValidationTrace,normalizeRegistrationRecord,normalizeRegistrationRecordList,normalizeRuntimeRegistrationRecord,sanitizeRegistrationValue}from "./registration-values.js";import{compareComparableVersions,parseComparableVersion}from "./version-compat.js";export{parseLegacyExtensionCapabilityAliasWarning,parseUnknownExtensionCapabilityWarning}from "./extension-capability-aliases.js";export{createEmptyExtensionCommandRegistry,createEmptyExtensionHookRegistry,createEmptyExtensionParserRegistry,createEmptyExtensionPreflightRegistry,createEmptyExtensionRegistrationRegistry,createEmptyExtensionRendererRegistry,createEmptyExtensionServiceRegistry}from "./extension-registries.js";export{runAfterCommandHooks,runBeforeCommandHooks,runBeforeMutationHooks,runCommandHandler,runCommandOverride,runOnIndexHooks,runOnReadHooks,runOnWriteHooks,runParserOverride,runPreflightOverride,runRendererOverride,runServiceOverride,runServiceOverrideSync}from "./extension-hook-runtime.js";export * from "./extension-types.js";export{DEFAULT_EXTENSION_PRIORITY,parseExtensionManifestDocument}from "./manifest-parser.js";
|
|
13
2
|
/** Implements next extension reload token for the public runtime surface of this module. */
|
|
14
3
|
export declare function nextExtensionReloadToken(seed?:number):string;
|
|
15
4
|
/** Resolve symlinks on both paths before the containment check so a link inside the directory cannot escape it. */
|
|
16
5
|
export declare function isCanonicalPathWithinDirectory(directory:string,targetPath:string):Promise<boolean>;
|
|
17
6
|
/** Implements resolve extension roots for the public runtime surface of this module. */
|
|
18
|
-
export declare function resolveExtensionRoots(pmRoot:string,cwd?:string):{
|
|
19
|
-
global:string;
|
|
20
|
-
project:string;
|
|
21
|
-
};
|
|
7
|
+
export declare function resolveExtensionRoots(pmRoot:string,cwd?:string):{global:string;project:string;};
|
|
22
8
|
/** Implements discover extensions for the public runtime surface of this module. */
|
|
23
|
-
export declare function discoverExtensions(options:DiscoverExtensionsOptions):Promise<ExtensionDiscoveryResult>;
|
|
24
|
-
declare function readCurrentPmCliVersion():Promise<string | null>;
|
|
25
|
-
declare function resolveCurrentPmCliVersion():Promise<string | null>;
|
|
26
|
-
declare function evaluatePmMinVersionCompatibility(layer:ExtensionLayer,manifest:ExtensionManifest):Promise<{
|
|
27
|
-
allowed:boolean;
|
|
28
|
-
warning?:string;
|
|
29
|
-
}>;
|
|
30
|
-
declare function evaluatePmMaxVersionCompatibility(layer:ExtensionLayer,manifest:ExtensionManifest,exceededMode:PmMaxVersionExceededMode):Promise<{
|
|
31
|
-
allowed:boolean;
|
|
32
|
-
warning?:string;
|
|
33
|
-
}>;
|
|
34
|
-
declare function fingerprintPath(pathToInspect:string):Promise<string>;
|
|
35
|
-
declare function resolveExtensionImportHref(extension:EffectiveExtension,options:DiscoverExtensionsOptions):Promise<string>;
|
|
9
|
+
export declare function discoverExtensions(options:DiscoverExtensionsOptions):Promise<ExtensionDiscoveryResult>;declare function readCurrentPmCliVersion():Promise<string|null>;declare function resolveCurrentPmCliVersion():Promise<string|null>;declare function evaluatePmMinVersionCompatibility(layer:ExtensionLayer,manifest:ExtensionManifest):Promise<{allowed:boolean;warning?:string;}>;declare function evaluatePmMaxVersionCompatibility(layer:ExtensionLayer,manifest:ExtensionManifest,exceededMode:PmMaxVersionExceededMode):Promise<{allowed:boolean;warning?:string;}>;declare function fingerprintPath(pathToInspect:string):Promise<string>;declare function resolveExtensionImportHref(extension:EffectiveExtension,options:DiscoverExtensionsOptions):Promise<string>;
|
|
36
10
|
/** Implements load extensions for the public runtime surface of this module. */
|
|
37
11
|
export declare function loadExtensions(options:DiscoverExtensionsOptions):Promise<ExtensionLoadResult>;
|
|
38
12
|
/**
|
|
@@ -49,46 +23,8 @@ export declare function loadExtensions(options:DiscoverExtensionsOptions):Promis
|
|
|
49
23
|
* indefinitely unless the host explicitly disables the timeout; the returned
|
|
50
24
|
* warnings/failures preserve loaded order.
|
|
51
25
|
*/
|
|
52
|
-
export declare function deactivateExtensions(loadResult:ExtensionLoadResult,activationResult?:Pick<ExtensionActivationResult,"failed">,options?:ExtensionDeactivationOptions):Promise<ExtensionDeactivationResult>;
|
|
53
|
-
declare function normalizeExtensionDeactivateTimeout(rawTimeout:unknown):number;
|
|
54
|
-
declare function createExtensionApi(extension:LoadedExtension,hooks:ExtensionHookRegistry,commands:ExtensionCommandRegistry,parsers:ExtensionParserRegistry,preflight:ExtensionPreflightRegistry,services:ExtensionServiceRegistry,renderers:ExtensionRendererRegistry,registrations:ExtensionRegistrationRegistry,activationWarnings:string[],activationFailures:FailedExtensionActivation[],policy:NormalizedExtensionPolicy):ExtensionApi;
|
|
55
|
-
declare function getRegistrationCounts(registrations:ExtensionRegistrationRegistry):ExtensionRegistrationCounts;
|
|
56
|
-
declare function collectCommandCollisionWarnings(commands:ExtensionCommandRegistry):string[];
|
|
57
|
-
declare function collectRendererCollisionWarnings(renderers:ExtensionRendererRegistry):string[];
|
|
58
|
-
declare function collectParserCollisionWarnings(parsers:ExtensionParserRegistry):string[];
|
|
59
|
-
declare function collectServiceCollisionWarnings(services:ExtensionServiceRegistry):string[];
|
|
26
|
+
export declare function deactivateExtensions(loadResult:ExtensionLoadResult,activationResult?:Pick<ExtensionActivationResult,"failed">,options?:ExtensionDeactivationOptions):Promise<ExtensionDeactivationResult>;declare function normalizeExtensionDeactivateTimeout(rawTimeout:unknown):number;declare function createExtensionApi(extension:LoadedExtension,hooks:ExtensionHookRegistry,commands:ExtensionCommandRegistry,parsers:ExtensionParserRegistry,preflight:ExtensionPreflightRegistry,services:ExtensionServiceRegistry,renderers:ExtensionRendererRegistry,registrations:ExtensionRegistrationRegistry,activationWarnings:string[],activationFailures:FailedExtensionActivation[],policy:NormalizedExtensionPolicy):ExtensionApi;declare function getRegistrationCounts(registrations:ExtensionRegistrationRegistry):ExtensionRegistrationCounts;declare function collectCommandCollisionWarnings(commands:ExtensionCommandRegistry):string[];declare function collectRendererCollisionWarnings(renderers:ExtensionRendererRegistry):string[];declare function collectParserCollisionWarnings(parsers:ExtensionParserRegistry):string[];declare function collectServiceCollisionWarnings(services:ExtensionServiceRegistry):string[];
|
|
60
27
|
/** Implements activate extensions for the public runtime surface of this module. */
|
|
61
28
|
export declare function activateExtensions(loadResult:ExtensionLoadResult):Promise<ExtensionActivationResult>;
|
|
62
29
|
/** Public contract for test only loader, shared by SDK and presentation-layer consumers. */
|
|
63
|
-
export declare const _testOnlyLoader:{
|
|
64
|
-
assertFlagValueTypeAndDefault:typeof assertFlagValueTypeAndDefault;
|
|
65
|
-
assertOptionalStringField:typeof assertOptionalStringField;
|
|
66
|
-
compareComparableVersions:typeof compareComparableVersions;
|
|
67
|
-
collectCommandCollisionWarnings:typeof collectCommandCollisionWarnings;
|
|
68
|
-
collectParserCollisionWarnings:typeof collectParserCollisionWarnings;
|
|
69
|
-
collectRendererCollisionWarnings:typeof collectRendererCollisionWarnings;
|
|
70
|
-
collectServiceCollisionWarnings:typeof collectServiceCollisionWarnings;
|
|
71
|
-
createExtensionApi:typeof createExtensionApi;
|
|
72
|
-
createRegistrationValidationError:typeof createRegistrationValidationError;
|
|
73
|
-
evaluatePmMaxVersionCompatibility:typeof evaluatePmMaxVersionCompatibility;
|
|
74
|
-
evaluatePmMinVersionCompatibility:typeof evaluatePmMinVersionCompatibility;
|
|
75
|
-
extractRegistrationValidationTrace:typeof extractRegistrationValidationTrace;
|
|
76
|
-
fingerprintPath:typeof fingerprintPath;
|
|
77
|
-
getRegistrationCounts:typeof getRegistrationCounts;
|
|
78
|
-
normalizeCommandDefinitionArguments:typeof normalizeCommandDefinitionArguments;
|
|
79
|
-
normalizeExtensionDeactivateTimeout:typeof normalizeExtensionDeactivateTimeout;
|
|
80
|
-
normalizeOptionalStringArrayField:typeof normalizeOptionalStringArrayField;
|
|
81
|
-
normalizeRegistrationRecord:typeof normalizeRegistrationRecord;
|
|
82
|
-
normalizeRegistrationRecordList:typeof normalizeRegistrationRecordList;
|
|
83
|
-
normalizeRuntimeRegistrationRecord:typeof normalizeRuntimeRegistrationRecord;
|
|
84
|
-
parseComparableVersion:typeof parseComparableVersion;
|
|
85
|
-
parseManifest:typeof parseExtensionManifestDocument;
|
|
86
|
-
readCurrentPmCliVersion:typeof readCurrentPmCliVersion;
|
|
87
|
-
readManagedExtensionSourcePackages:(extensionsRoot:string) => Promise<Map<string,string>>;
|
|
88
|
-
resolveExtensionImportHref:typeof resolveExtensionImportHref;
|
|
89
|
-
resolveCurrentPmCliVersion:typeof resolveCurrentPmCliVersion;
|
|
90
|
-
resolveCommandDefinitionAction:typeof resolveCommandDefinitionAction;
|
|
91
|
-
sanitizeRegistrationValue:typeof sanitizeRegistrationValue;
|
|
92
|
-
validateItemFieldDefinitions:typeof validateItemFieldDefinitions;
|
|
93
|
-
resetCurrentPmCliVersionCacheForTest:() => void;
|
|
94
|
-
};
|
|
30
|
+
export declare const _testOnlyLoader:{assertFlagValueTypeAndDefault:typeof assertFlagValueTypeAndDefault;assertOptionalStringField:typeof assertOptionalStringField;compareComparableVersions:typeof compareComparableVersions;collectCommandCollisionWarnings:typeof collectCommandCollisionWarnings;collectParserCollisionWarnings:typeof collectParserCollisionWarnings;collectRendererCollisionWarnings:typeof collectRendererCollisionWarnings;collectServiceCollisionWarnings:typeof collectServiceCollisionWarnings;createExtensionApi:typeof createExtensionApi;createRegistrationValidationError:typeof createRegistrationValidationError;evaluatePmMaxVersionCompatibility:typeof evaluatePmMaxVersionCompatibility;evaluatePmMinVersionCompatibility:typeof evaluatePmMinVersionCompatibility;extractRegistrationValidationTrace:typeof extractRegistrationValidationTrace;fingerprintPath:typeof fingerprintPath;getRegistrationCounts:typeof getRegistrationCounts;normalizeCommandDefinitionArguments:typeof normalizeCommandDefinitionArguments;normalizeExtensionDeactivateTimeout:typeof normalizeExtensionDeactivateTimeout;normalizeOptionalStringArrayField:typeof normalizeOptionalStringArrayField;normalizeRegistrationRecord:typeof normalizeRegistrationRecord;normalizeRegistrationRecordList:typeof normalizeRegistrationRecordList;normalizeRuntimeRegistrationRecord:typeof normalizeRuntimeRegistrationRecord;parseComparableVersion:typeof parseComparableVersion;parseManifest:typeof parseExtensionManifestDocument;readCurrentPmCliVersion:typeof readCurrentPmCliVersion;readManagedExtensionSourcePackages:(extensionsRoot:string)=> Promise<Map<string,string>>;resolveExtensionImportHref:typeof resolveExtensionImportHref;resolveCurrentPmCliVersion:typeof resolveCurrentPmCliVersion;resolveCommandDefinitionAction:typeof resolveCommandDefinitionAction;sanitizeRegistrationValue:typeof sanitizeRegistrationValue;validateItemFieldDefinitions:typeof validateItemFieldDefinitions;resetCurrentPmCliVersionCacheForTest:()=> void;};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{type ExtensionManifest}from "./extension-types.js";
|
|
2
2
|
/** Fallback extension priority used when callers do not provide an override. */
|
|
3
|
-
export declare const DEFAULT_EXTENSION_PRIORITY
|
|
3
|
+
export declare const DEFAULT_EXTENSION_PRIORITY=100;
|
|
4
4
|
/** Parse and normalize one complete on-disk extension manifest contract. */
|
|
5
|
-
export declare function parseExtensionManifestDocument(raw:unknown):ExtensionManifest
|
|
5
|
+
export declare function parseExtensionManifestDocument(raw:unknown):ExtensionManifest|null;
|
|
@@ -4,37 +4,34 @@
|
|
|
4
4
|
* Defines the closed extension-manifest key vocabulary and returns pure schema
|
|
5
5
|
* diagnostics shared by SDK authoring checks and runtime discovery.
|
|
6
6
|
*/
|
|
7
|
-
import type
|
|
7
|
+
import type{ExtensionLayer,ExtensionManifest}from "./extension-types.js";
|
|
8
8
|
/** Canonical top-level keys accepted by an extension `manifest.json`. */
|
|
9
9
|
export declare const KNOWN_EXTENSION_MANIFEST_KEYS:Set<string>;
|
|
10
10
|
/** Pure closed-schema inspection result for one raw extension manifest. */
|
|
11
|
-
export interface ExtensionManifestSchemaInspection
|
|
11
|
+
export interface ExtensionManifestSchemaInspection{
|
|
12
12
|
/** Unknown top-level keys in deterministic lexical order. */
|
|
13
13
|
unknownKeys:string[];
|
|
14
14
|
/** Whether neither canonical pm compatibility bound is present. */
|
|
15
|
-
missingVersionBounds:boolean;
|
|
16
|
-
}
|
|
15
|
+
missingVersionBounds:boolean;}
|
|
17
16
|
/** Stable machine-readable schema finding emitted by author-time lint. */
|
|
18
|
-
export interface ExtensionManifestSchemaFinding
|
|
17
|
+
export interface ExtensionManifestSchemaFinding{
|
|
19
18
|
/** Schema condition an author must review. */
|
|
20
|
-
code:"manifest_unknown_key"
|
|
19
|
+
code:"manifest_unknown_key"|"no_version_bounds_declared";
|
|
21
20
|
/** JSON-style manifest location responsible for the finding. */
|
|
22
21
|
path:string;
|
|
23
22
|
/** Canonical key to use when the mistaken or missing field has one. */
|
|
24
|
-
suggested_key?:"pm_min_version"
|
|
23
|
+
suggested_key?:"pm_min_version"|"pm_max_version";
|
|
25
24
|
/** Actionable explanation of the ignored or missing declaration. */
|
|
26
|
-
message:string;
|
|
27
|
-
}
|
|
25
|
+
message:string;}
|
|
28
26
|
/** Pure schema-lint result for one raw extension manifest. */
|
|
29
|
-
export interface ExtensionManifestSchemaLintResult
|
|
27
|
+
export interface ExtensionManifestSchemaLintResult{
|
|
30
28
|
/** False when at least one author-facing schema finding is present. */
|
|
31
29
|
ok:boolean;
|
|
32
30
|
/** Deterministically ordered schema findings. */
|
|
33
|
-
findings:ExtensionManifestSchemaFinding[];
|
|
34
|
-
}
|
|
31
|
+
findings:ExtensionManifestSchemaFinding[];}
|
|
35
32
|
/** Inspect raw manifest keys without parsing, loading, or mutating an extension. */
|
|
36
33
|
export declare function inspectExtensionManifestSchema(manifest:Readonly<Record<string,unknown>>):ExtensionManifestSchemaInspection;
|
|
37
34
|
/** Lint raw extension-manifest keys without loading code or evaluating versions. */
|
|
38
35
|
export declare function lintExtensionManifestSchema(manifest:Readonly<Record<string,unknown>>):ExtensionManifestSchemaLintResult;
|
|
39
36
|
/** Format runtime discovery warnings for unknown keys and absent canonical compatibility bounds. */
|
|
40
|
-
export declare function formatExtensionManifestSchemaWarnings(layer:ExtensionLayer,manifest:ExtensionManifest,rawManifest:Readonly<Record<string,unknown>>):string[];
|
|
37
|
+
export declare function formatExtensionManifestSchemaWarnings(layer:ExtensionLayer,manifest:ExtensionManifest,rawManifest:Readonly<Record<string,unknown>>):string[];
|
|
@@ -2,8 +2,7 @@
|
|
|
2
2
|
* @module core/extensions/registration-contracts
|
|
3
3
|
* Validates contributed command, flag, schema and profile definitions before registration.
|
|
4
4
|
*/
|
|
5
|
-
import type
|
|
6
|
-
import { type ExtensionCommandArgumentDefinition,type FlagDefinition } from "./extension-types.js";
|
|
5
|
+
import type{ProjectProfileDefinition}from "../profile/profile-presets.js";import{type ExtensionCommandArgumentDefinition,type FlagDefinition}from "./extension-types.js";
|
|
7
6
|
/** Normalize registration records and expand the repeatable alias into the canonical list flag property. */
|
|
8
7
|
declare function normalizeFlagDefinitions(name:string,value:unknown):FlagDefinition[];
|
|
9
8
|
/** Derive an action from the command path or reject an invalid explicit action before registration. */
|
|
@@ -30,5 +29,4 @@ declare function validateProjectProfileDefinition(profile:unknown):void;
|
|
|
30
29
|
* validation on the cloned snapshot, so it only ever supplies missing defaults
|
|
31
30
|
* and never has to coerce an invalid type (those are already rejected).
|
|
32
31
|
*/
|
|
33
|
-
declare function applyProjectProfileDefaults(profile:Record<string,unknown>):ProjectProfileDefinition;
|
|
34
|
-
export { applyProjectProfileDefaults,assertFlagValueTypeAndDefault,normalizeCommandDefinitionArguments,normalizeFlagDefinitions,resolveCommandDefinitionAction,validateFlagDefinitions,validateItemFieldDefinitions,validateItemTypeDefinitions,validateMigrationDefinition,validateProjectProfileDefinition };
|
|
32
|
+
declare function applyProjectProfileDefaults(profile:Record<string,unknown>):ProjectProfileDefinition;export{applyProjectProfileDefaults,assertFlagValueTypeAndDefault,normalizeCommandDefinitionArguments,normalizeFlagDefinitions,resolveCommandDefinitionAction,validateFlagDefinitions,validateItemFieldDefinitions,validateItemTypeDefinitions,validateMigrationDefinition,validateProjectProfileDefinition};
|
|
@@ -14,4 +14,4 @@ export declare function assertOptionalFlagDefaultField(name:string,value:unknown
|
|
|
14
14
|
/** Validate an optional array containing only non-empty strings. */
|
|
15
15
|
export declare function assertOptionalStringArrayField(name:string,value:unknown):void;
|
|
16
16
|
/** Normalize an optional string array by trimming and preserving first occurrence order. */
|
|
17
|
-
export declare function normalizeOptionalStringArrayField(name:string,value:unknown):string[];
|
|
17
|
+
export declare function normalizeOptionalStringArrayField(name:string,value:unknown):string[];
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Preserves executable extension registrations while producing deterministic,
|
|
5
5
|
* serializable public inventory snapshots and validates assurance providers.
|
|
6
6
|
*/
|
|
7
|
-
import
|
|
7
|
+
import{type AssuranceMeasurementProviderDefinition,type ExtensionActivationFailureTrace,type ExtensionServiceName,type OutputRendererFormat}from "./extension-types.js";
|
|
8
8
|
/** Narrow a string to a renderer format accepted by the extension host. */
|
|
9
9
|
export declare function isOutputRendererFormat(value:string):value is OutputRendererFormat;
|
|
10
10
|
/** Narrow a string to a service name accepted by the extension host. */
|
|
@@ -14,7 +14,7 @@ export declare function assertHookHandler(hookName:string,hook:unknown):void;
|
|
|
14
14
|
/** Create a validation error carrying a hidden structured activation trace. */
|
|
15
15
|
export declare function createRegistrationValidationError(message:string,trace:ExtensionActivationFailureTrace):TypeError;
|
|
16
16
|
/** Recover a hidden structured activation trace from a validation error. */
|
|
17
|
-
export declare function extractRegistrationValidationTrace(error:unknown):ExtensionActivationFailureTrace
|
|
17
|
+
export declare function extractRegistrationValidationTrace(error:unknown):ExtensionActivationFailureTrace|undefined;
|
|
18
18
|
/** Recursively project an arbitrary registration value into serializable data. */
|
|
19
19
|
export declare function sanitizeRegistrationValue(value:unknown):unknown;
|
|
20
20
|
/** Recursively clone registration containers while preserving function identities. */
|
|
@@ -34,10 +34,8 @@ export declare function assertRegistrationFunction(name:string,value:unknown):vo
|
|
|
34
34
|
/** Canonicalize a user-facing registration name for stable routing. */
|
|
35
35
|
export declare function normalizeRegistrationName(name:string):string;
|
|
36
36
|
/** Build the canonical command path synthesized for an importer or exporter. */
|
|
37
|
-
export declare function toRegistrationCommandPath(name:string,action:"import"
|
|
37
|
+
export declare function toRegistrationCommandPath(name:string,action:"import"|"export"):string;
|
|
38
38
|
/** Attach an executable definition as hidden immutable runtime-only state. */
|
|
39
|
-
export declare function attachRuntimeDefinition<TEntry extends
|
|
40
|
-
definition:Record<string,unknown>;
|
|
41
|
-
}>(entry:TEntry,runtimeDefinition:Record<string,unknown>):TEntry;
|
|
39
|
+
export declare function attachRuntimeDefinition<TEntry extends{definition:Record<string,unknown>;}>(entry:TEntry,runtimeDefinition:Record<string,unknown>):TEntry;
|
|
42
40
|
/** Validate the closed provider schema before any activation registry mutation. */
|
|
43
|
-
export declare function validateAssuranceMeasurementProviderDefinition(provider:unknown):asserts provider is AssuranceMeasurementProviderDefinition;
|
|
41
|
+
export declare function validateAssuranceMeasurementProviderDefinition(provider:unknown):asserts provider is AssuranceMeasurementProviderDefinition;
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Implements extension runtime contracts and governance for Runtime Registrations.
|
|
5
5
|
*/
|
|
6
|
-
import type
|
|
6
|
+
import type{ExtensionRegistrationRegistry,RegisteredExtensionSchemaMigrationDefinition,RegisteredExtensionSearchProvider,RegisteredExtensionVectorStoreAdapter,RegisteredExtensionAssuranceMeasurementProvider,SchemaFieldDefinition}from "./loader.js";
|
|
7
7
|
/** Resolve the last-activated assurance provider with the requested stable id. */
|
|
8
|
-
export declare function resolveRegisteredAssuranceMeasurementProvider(registrations:ExtensionRegistrationRegistry
|
|
8
|
+
export declare function resolveRegisteredAssuranceMeasurementProvider(registrations:ExtensionRegistrationRegistry|null,providerId:string|undefined):RegisteredExtensionAssuranceMeasurementProvider|null;
|
|
9
9
|
/** Implements collect registered item fields for the public runtime surface of this module. */
|
|
10
|
-
export declare function collectRegisteredItemFields(registrations:ExtensionRegistrationRegistry
|
|
10
|
+
export declare function collectRegisteredItemFields(registrations:ExtensionRegistrationRegistry|null):SchemaFieldDefinition[];
|
|
11
11
|
/** Implements resolve registered search provider for the public runtime surface of this module. */
|
|
12
|
-
export declare function resolveRegisteredSearchProvider(registrations:ExtensionRegistrationRegistry
|
|
12
|
+
export declare function resolveRegisteredSearchProvider(registrations:ExtensionRegistrationRegistry|null,configuredProvider:string|undefined):RegisteredExtensionSearchProvider|null;
|
|
13
13
|
/** Implements resolve registered vector store adapter for the public runtime surface of this module. */
|
|
14
|
-
export declare function resolveRegisteredVectorStoreAdapter(registrations:ExtensionRegistrationRegistry
|
|
14
|
+
export declare function resolveRegisteredVectorStoreAdapter(registrations:ExtensionRegistrationRegistry|null,configuredAdapter:string|undefined):RegisteredExtensionVectorStoreAdapter|null;
|
|
15
15
|
/** Implements get migration runtime definition for the public runtime surface of this module. */
|
|
16
|
-
export declare function getMigrationRuntimeDefinition(migration:RegisteredExtensionSchemaMigrationDefinition):Record<string,unknown>;
|
|
16
|
+
export declare function getMigrationRuntimeDefinition(migration:RegisteredExtensionSchemaMigrationDefinition):Record<string,unknown>;
|
|
@@ -20,9 +20,9 @@
|
|
|
20
20
|
* version resolution stay with the loader; finding/message presentation stays
|
|
21
21
|
* with the SDK.
|
|
22
22
|
*/
|
|
23
|
-
import type
|
|
23
|
+
import type{PmMaxVersionExceededMode}from "./extension-types.js";
|
|
24
24
|
/** The two inclusive manifest version bounds pm evaluates at load time. */
|
|
25
|
-
export type PmVersionBoundKind
|
|
25
|
+
export type PmVersionBoundKind="pm_min_version"|"pm_max_version";
|
|
26
26
|
/**
|
|
27
27
|
* The outcome of evaluating a single manifest version bound against a pm version.
|
|
28
28
|
*
|
|
@@ -42,9 +42,9 @@ export type PmVersionBoundKind = "pm_min_version" | "pm_max_version";
|
|
|
42
42
|
* exceeded mode is `warn`, so the extension loads with an advisory warning
|
|
43
43
|
* (only emitted for `pm_max_version`).
|
|
44
44
|
*/
|
|
45
|
-
export type PmVersionBoundStatus
|
|
45
|
+
export type PmVersionBoundStatus="absent"|"ok"|"invalid"|"unchecked"|"unmet"|"exceeded"|"exceeded_warn";
|
|
46
46
|
/** The structured result of evaluating one manifest version bound, consumed by the loader (to format its `extension_pm_*_version_*` warning strings) and the SDK (to build author-time compatibility findings). */
|
|
47
|
-
export interface PmVersionBoundEvaluation
|
|
47
|
+
export interface PmVersionBoundEvaluation{
|
|
48
48
|
/** Which bound this evaluation describes. */
|
|
49
49
|
kind:PmVersionBoundKind;
|
|
50
50
|
/** The classified outcome of comparing the bound against the current version. */
|
|
@@ -54,8 +54,7 @@ allowed:boolean;
|
|
|
54
54
|
/** The declared bound value, verbatim; the empty string when the bound is absent. */
|
|
55
55
|
required:string;
|
|
56
56
|
/** The current version compared against, or `null` when it could not be resolved. */
|
|
57
|
-
current:string
|
|
58
|
-
}
|
|
57
|
+
current:string|null;}
|
|
59
58
|
/**
|
|
60
59
|
* Parse a comparable release string into numeric segments, or `null` when it is
|
|
61
60
|
* not an interpretable dotted-numeric version.
|
|
@@ -64,7 +63,7 @@ current:string | null;
|
|
|
64
63
|
* (so `engines.pm`-style `">=2026.5.31"` and `"v1.2.3"` both parse), then drops
|
|
65
64
|
* any build/pre-release suffix and keeps the leading dotted-numeric release.
|
|
66
65
|
*/
|
|
67
|
-
export declare function parseComparableVersion(value:string):number[]
|
|
66
|
+
export declare function parseComparableVersion(value:string):number[]|null;
|
|
68
67
|
/**
|
|
69
68
|
* Compare two comparable version strings segment by segment.
|
|
70
69
|
*
|
|
@@ -73,7 +72,7 @@ export declare function parseComparableVersion(value:string):number[] | null;
|
|
|
73
72
|
* can classify the comparison as `unchecked`). Missing trailing segments are
|
|
74
73
|
* treated as `0`, so `1.2` and `1.2.0` compare equal.
|
|
75
74
|
*/
|
|
76
|
-
export declare function compareComparableVersions(currentVersion:string,otherVersion:string):number
|
|
75
|
+
export declare function compareComparableVersions(currentVersion:string,otherVersion:string):number|null;
|
|
77
76
|
/**
|
|
78
77
|
* Evaluate a manifest `pm_min_version` inclusive lower bound against the current
|
|
79
78
|
* pm version.
|
|
@@ -84,7 +83,7 @@ export declare function compareComparableVersions(currentVersion:string,otherVer
|
|
|
84
83
|
* `currentVersion` is `null` when the loader could not resolve the running CLI
|
|
85
84
|
* version.
|
|
86
85
|
*/
|
|
87
|
-
export declare function evaluatePmMinVersionBound(required:unknown,currentVersion:string
|
|
86
|
+
export declare function evaluatePmMinVersionBound(required:unknown,currentVersion:string|null):PmVersionBoundEvaluation;
|
|
88
87
|
/**
|
|
89
88
|
* Evaluate a manifest `pm_max_version` inclusive upper bound against the current
|
|
90
89
|
* pm version.
|
|
@@ -100,4 +99,4 @@ export declare function evaluatePmMinVersionBound(required:unknown,currentVersio
|
|
|
100
99
|
* `exceeded_warn` when `exceededMode` is `warn`, so the extension still loads
|
|
101
100
|
* during a controlled upgrade window); otherwise the bound is satisfied (`ok`).
|
|
102
101
|
*/
|
|
103
|
-
export declare function evaluatePmMaxVersionBound(required:unknown,currentVersion:string
|
|
102
|
+
export declare function evaluatePmMaxVersionBound(required:unknown,currentVersion:string|null,exceededMode:PmMaxVersionExceededMode):PmVersionBoundEvaluation;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{PmCliError}from "../shared/errors.js";
|
|
2
2
|
/** Implements ensure dir for the public runtime surface of this module. */
|
|
3
3
|
export declare function ensureDir(dirPath:string):Promise<void>;
|
|
4
4
|
/** Implements path exists for the public runtime surface of this module. */
|
|
@@ -16,7 +16,7 @@ export declare function isFileAbsentError(error:unknown):boolean;
|
|
|
16
16
|
/** Report an exact missing-entry race while preserving ENOTDIR as structural corruption. */
|
|
17
17
|
export declare function isFileMissingError(error:unknown):boolean;
|
|
18
18
|
/** Implements read file if exists for the public runtime surface of this module. */
|
|
19
|
-
export declare function readFileIfExists(targetPath:string):Promise<string
|
|
19
|
+
export declare function readFileIfExists(targetPath:string):Promise<string|null>;
|
|
20
20
|
/**
|
|
21
21
|
* Read UTF-8 bytes after checking that the opened descriptor is a regular file.
|
|
22
22
|
* Callers validate entries, ancestors and optional-file absence before opening.
|
|
@@ -41,9 +41,7 @@ export declare function transactionPreviewNonRegularFileError(relativePath?:stri
|
|
|
41
41
|
* that behavior to respect removal of their storage while work is in flight;
|
|
42
42
|
* missing parents then produce the native filesystem error without recreation.
|
|
43
43
|
*/
|
|
44
|
-
export declare function writeFileAtomic(targetPath:string,contents:string,options?:{
|
|
45
|
-
createParentDirectories?:boolean;
|
|
46
|
-
}):Promise<void>;
|
|
44
|
+
export declare function writeFileAtomic(targetPath:string,contents:string,options?:{createParentDirectories?:boolean;}):Promise<void>;
|
|
47
45
|
/**
|
|
48
46
|
* Append a single newline-terminated line to a file, opened with `O_APPEND`.
|
|
49
47
|
*
|
|
@@ -65,4 +63,4 @@ createParentDirectories?:boolean;
|
|
|
65
63
|
*/
|
|
66
64
|
export declare function appendLineAtomic(targetPath:string,line:string):Promise<void>;
|
|
67
65
|
/** Implements remove file if exists for the public runtime surface of this module. */
|
|
68
|
-
export declare function removeFileIfExists(targetPath:string):Promise<void>;
|
|
66
|
+
export declare function removeFileIfExists(targetPath:string):Promise<void>;
|
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{PmCliError}from "../shared/errors.js";
|
|
2
2
|
/** Optional stable codes used by an existing SDK surface for each fault class. */
|
|
3
|
-
export interface HostEnvironmentFaultCodeOverrides
|
|
3
|
+
export interface HostEnvironmentFaultCodeOverrides{
|
|
4
4
|
/** Code used for quota and storage exhaustion. */
|
|
5
5
|
capacity?:string;
|
|
6
6
|
/** Code used for access policy and read-only filesystems. */
|
|
7
7
|
permission?:string;
|
|
8
8
|
/** Code used for file-descriptor and memory exhaustion. */
|
|
9
|
-
resource?:string;
|
|
10
|
-
}
|
|
9
|
+
resource?:string;}
|
|
11
10
|
/** Context and compatibility controls for a host-environment boundary. */
|
|
12
|
-
export interface HostEnvironmentBoundaryOptions
|
|
11
|
+
export interface HostEnvironmentBoundaryOptions{
|
|
13
12
|
/** Existing surface-specific codes that must remain compatible. */
|
|
14
13
|
codes?:HostEnvironmentFaultCodeOverrides;
|
|
15
14
|
/** Human explanation of why the operation needs host resources. */
|
|
@@ -17,11 +16,10 @@ why?:string;
|
|
|
17
16
|
/** Additional ordered recovery guidance. */
|
|
18
17
|
nextSteps?:readonly string[];
|
|
19
18
|
/** Copyable retry command when one is safe. */
|
|
20
|
-
suggestedRetry?:string;
|
|
21
|
-
}
|
|
19
|
+
suggestedRetry?:string;}
|
|
22
20
|
/** Return a declared host errno only when it represents recoverable environment state. */
|
|
23
|
-
export declare function classifyHostEnvironmentFault(error:unknown):string
|
|
21
|
+
export declare function classifyHostEnvironmentFault(error:unknown):string|null;
|
|
24
22
|
/** Translate one known host fault into a stable path-redacted SDK refusal. */
|
|
25
|
-
export declare function translateHostEnvironmentFault(error:unknown,operation:string,options?:HostEnvironmentBoundaryOptions):PmCliError
|
|
23
|
+
export declare function translateHostEnvironmentFault(error:unknown,operation:string,options?:HostEnvironmentBoundaryOptions):PmCliError|null;
|
|
26
24
|
/** Run one SDK filesystem stage and translate only declared host faults. */
|
|
27
|
-
export declare function withHostEnvironmentBoundary<T>(operation:string,run:()
|
|
25
|
+
export declare function withHostEnvironmentBoundary<T>(operation:string,run:()=> Promise<T>,options?:HostEnvironmentBoundaryOptions):Promise<T>;
|