create-principles-disciple 1.121.8 → 1.121.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/README.md +13 -1
- package/console/dist/server/config/pd-config-store.d.ts +1 -3
- package/console/dist/server/config/pd-config-store.js +4 -4
- package/console/dist/server/feedback/channels.d.ts +2 -8
- package/console/dist/server/feedback/channels.js +0 -11
- package/console/dist/server/index.js +34 -5
- package/console/dist/server/models/ActivationsConsoleModel.d.ts +28 -1
- package/console/dist/server/models/ActivationsConsoleModel.js +72 -30
- package/console/dist/server/models/GovernanceExperienceCollector.d.ts +28 -0
- package/console/dist/server/models/GovernanceExperienceCollector.js +305 -0
- package/console/dist/server/models/GovernanceProjectionCollector.d.ts +60 -2
- package/console/dist/server/models/GovernanceProjectionCollector.js +323 -285
- package/console/dist/server/models/PrincipleClassifier.d.ts +1 -1
- package/console/dist/server/models/PrincipleClassifier.js +7 -4
- package/console/dist/server/models/PrinciplesConsoleModel.d.ts +2 -1
- package/console/dist/server/models/ReceiptsConsoleModel.d.ts +5 -0
- package/console/dist/server/models/ReceiptsConsoleModel.js +140 -13
- package/console/dist/server/routes/activations.js +1 -1
- package/console/dist/server/routes/failed-tasks.js +28 -11
- package/console/dist/server/routes/governance.d.ts +26 -0
- package/console/dist/server/routes/governance.js +51 -0
- package/console/dist/server/routes/owner-identity.d.ts +31 -0
- package/console/dist/server/routes/owner-identity.js +76 -0
- package/console/dist/server/routes/update-history.d.ts +5 -0
- package/console/dist/server/routes/update-history.js +50 -4
- package/console/dist/server/routes/update.js +263 -41
- package/console/dist/server/utils/update-links.d.ts +38 -0
- package/console/dist/server/utils/update-links.js +71 -0
- package/console/dist/shared/feedback-channel-ids.d.ts +13 -0
- package/console/dist/shared/feedback-channel-ids.js +12 -0
- package/console/dist/shared/feedback-contract.d.ts +46 -0
- package/console/dist/shared/feedback-contract.js +45 -0
- package/console/dist/ui/App.js +1 -1
- package/console/dist/ui/api.d.ts +22 -3
- package/console/dist/ui/api.js +63 -3
- package/console/dist/ui/components/receipts/ReceiptCoverageDisclosure.d.ts +6 -0
- package/console/dist/ui/components/receipts/ReceiptCoverageDisclosure.js +66 -0
- package/console/dist/ui/i18n/en.json +198 -2
- package/console/dist/ui/i18n/zh-CN.json +196 -0
- package/console/dist/ui/pages/activation/ActivationPage.js +14 -2
- package/console/dist/ui/pages/failed-tasks/FailedTasksPage.js +25 -5
- package/console/dist/ui/pages/focus/FocusPage.d.ts +28 -1
- package/console/dist/ui/pages/focus/FocusPage.js +128 -15
- package/console/dist/ui/pages/principles/PrincipleDetailPage.d.ts +30 -0
- package/console/dist/ui/pages/principles/PrincipleDetailPage.js +49 -6
- package/console/dist/ui/pages/settings/SettingsPage.js +67 -2
- package/console/dist/ui/pages/settings/UpdatePage.js +7 -7
- package/console/dist/ui/utils/enum-labels.js +0 -1
- package/console/dist/ui/utils/validators.d.ts +53 -21
- package/console/dist/ui/utils/validators.js +248 -21
- package/console/dist/web/assets/app.css +6 -0
- package/console/dist/web/assets/app.js +2721 -1664
- package/console/package.json +3 -1
- package/core/dist/host/host-adapter.d.ts +1 -1
- package/core/dist/host/host-adapter.d.ts.map +1 -1
- package/core/dist/host/host-adapter.js +1 -0
- package/core/dist/host/host-adapter.js.map +1 -1
- package/core/dist/runtime-v2/__tests__/architecture-regression.test.js +12 -2
- package/core/dist/runtime-v2/__tests__/architecture-regression.test.js.map +1 -1
- package/core/dist/runtime-v2/__tests__/attack-e2e-pipeline-smoke.test.js +1 -1
- package/core/dist/runtime-v2/__tests__/attack-e2e-pipeline-smoke.test.js.map +1 -1
- package/core/dist/runtime-v2/__tests__/governance-experience.test.d.ts +2 -0
- package/core/dist/runtime-v2/__tests__/governance-experience.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/__tests__/governance-experience.test.js +300 -0
- package/core/dist/runtime-v2/__tests__/governance-experience.test.js.map +1 -0
- package/core/dist/runtime-v2/__tests__/owner-identity.test.d.ts +2 -0
- package/core/dist/runtime-v2/__tests__/owner-identity.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/__tests__/owner-identity.test.js +147 -0
- package/core/dist/runtime-v2/__tests__/owner-identity.test.js.map +1 -0
- package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.d.ts +18 -0
- package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.js +303 -0
- package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.js.map +1 -0
- package/core/dist/runtime-v2/__tests__/recovery-actions-log.test.js +40 -0
- package/core/dist/runtime-v2/__tests__/recovery-actions-log.test.js.map +1 -1
- package/core/dist/runtime-v2/__tests__/status-contract.test.d.ts +2 -0
- package/core/dist/runtime-v2/__tests__/status-contract.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/__tests__/status-contract.test.js +107 -0
- package/core/dist/runtime-v2/__tests__/status-contract.test.js.map +1 -0
- package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.d.ts +2 -0
- package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.js +104 -0
- package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.js.map +1 -0
- package/core/dist/runtime-v2/activation/__tests__/promotion-readiness-evaluator.test.js +19 -0
- package/core/dist/runtime-v2/activation/__tests__/promotion-readiness-evaluator.test.js.map +1 -1
- package/core/dist/runtime-v2/activation/__tests__/rulecode-owner-decision-service.test.js +20 -0
- package/core/dist/runtime-v2/activation/__tests__/rulecode-owner-decision-service.test.js.map +1 -1
- package/core/dist/runtime-v2/activation/__tests__/sqlite-activation-safety-store.test.js +40 -0
- package/core/dist/runtime-v2/activation/__tests__/sqlite-activation-safety-store.test.js.map +1 -1
- package/core/dist/runtime-v2/activation/index.d.ts +2 -0
- package/core/dist/runtime-v2/activation/index.d.ts.map +1 -1
- package/core/dist/runtime-v2/activation/index.js +1 -0
- package/core/dist/runtime-v2/activation/index.js.map +1 -1
- package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.d.ts +30 -0
- package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.d.ts.map +1 -0
- package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.js +87 -0
- package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.js.map +1 -0
- package/core/dist/runtime-v2/activation/promotion-readiness-evaluator.d.ts.map +1 -1
- package/core/dist/runtime-v2/activation/promotion-readiness-evaluator.js +3 -0
- package/core/dist/runtime-v2/activation/promotion-readiness-evaluator.js.map +1 -1
- package/core/dist/runtime-v2/activation/promotion-readiness-reader.d.ts +1 -1
- package/core/dist/runtime-v2/activation/promotion-readiness-reader.d.ts.map +1 -1
- package/core/dist/runtime-v2/activation/promotion-readiness-reader.js +2 -2
- package/core/dist/runtime-v2/activation/promotion-readiness-reader.js.map +1 -1
- package/core/dist/runtime-v2/activation/rulecode-owner-decision-service.d.ts.map +1 -1
- package/core/dist/runtime-v2/activation/rulecode-owner-decision-service.js +18 -9
- package/core/dist/runtime-v2/activation/rulecode-owner-decision-service.js.map +1 -1
- package/core/dist/runtime-v2/adapter/__tests__/chaos-json-repair.test.js +1 -1
- package/core/dist/runtime-v2/adapter/__tests__/chaos-json-repair.test.js.map +1 -1
- package/core/dist/runtime-v2/adapter/__tests__/json-extractor.test.js +91 -1
- package/core/dist/runtime-v2/adapter/__tests__/json-extractor.test.js.map +1 -1
- package/core/dist/runtime-v2/adapter/__tests__/pi-ai-runtime-adapter.test.js +59 -12
- package/core/dist/runtime-v2/adapter/__tests__/pi-ai-runtime-adapter.test.js.map +1 -1
- package/core/dist/runtime-v2/adapter/__tests__/runtime-config-contract.test.js +10 -9
- package/core/dist/runtime-v2/adapter/__tests__/runtime-config-contract.test.js.map +1 -1
- package/core/dist/runtime-v2/adapter/__tests__/structured-output-repair.test.js +42 -1
- package/core/dist/runtime-v2/adapter/__tests__/structured-output-repair.test.js.map +1 -1
- package/core/dist/runtime-v2/adapter/json-extractor.d.ts +25 -0
- package/core/dist/runtime-v2/adapter/json-extractor.d.ts.map +1 -1
- package/core/dist/runtime-v2/adapter/json-extractor.js +126 -0
- package/core/dist/runtime-v2/adapter/json-extractor.js.map +1 -1
- package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.d.ts +9 -4
- package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.d.ts.map +1 -1
- package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.js +9 -4
- package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.js.map +1 -1
- package/core/dist/runtime-v2/adapter/output-repair-contract.d.ts +5 -1
- package/core/dist/runtime-v2/adapter/output-repair-contract.d.ts.map +1 -1
- package/core/dist/runtime-v2/adapter/output-repair-contract.js +4 -1
- package/core/dist/runtime-v2/adapter/output-repair-contract.js.map +1 -1
- package/core/dist/runtime-v2/adapter/pi-ai-catalog.d.ts +7 -0
- package/core/dist/runtime-v2/adapter/pi-ai-catalog.d.ts.map +1 -0
- package/core/dist/runtime-v2/adapter/pi-ai-catalog.js +19 -0
- package/core/dist/runtime-v2/adapter/pi-ai-catalog.js.map +1 -0
- package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.d.ts +13 -15
- package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.d.ts.map +1 -1
- package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.js +104 -37
- package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.js.map +1 -1
- package/core/dist/runtime-v2/adapter/structured-output-repair.d.ts +16 -1
- package/core/dist/runtime-v2/adapter/structured-output-repair.d.ts.map +1 -1
- package/core/dist/runtime-v2/adapter/structured-output-repair.js +38 -6
- package/core/dist/runtime-v2/adapter/structured-output-repair.js.map +1 -1
- package/core/dist/runtime-v2/adapter/tools/diagnostician-tool.d.ts +1 -1
- package/core/dist/runtime-v2/adapter/tools/diagnostician-tool.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/__tests__/pd-config-agent-binding.test.js +8 -9
- package/core/dist/runtime-v2/config/__tests__/pd-config-agent-binding.test.js.map +1 -1
- package/core/dist/runtime-v2/config/__tests__/pd-config-contract.test.js +27 -3
- package/core/dist/runtime-v2/config/__tests__/pd-config-contract.test.js.map +1 -1
- package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.d.ts +11 -0
- package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.js +93 -0
- package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.js.map +1 -0
- package/core/dist/runtime-v2/config/__tests__/pd-config-workspace.test.js +41 -0
- package/core/dist/runtime-v2/config/__tests__/pd-config-workspace.test.js.map +1 -1
- package/core/dist/runtime-v2/config/index.d.ts +2 -2
- package/core/dist/runtime-v2/config/index.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/index.js +2 -0
- package/core/dist/runtime-v2/config/index.js.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-agent-binding.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-agent-binding.js +4 -13
- package/core/dist/runtime-v2/config/pd-config-agent-binding.js.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-effective.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-effective.js +14 -7
- package/core/dist/runtime-v2/config/pd-config-effective.js.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-feature-flags.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-feature-flags.js +5 -12
- package/core/dist/runtime-v2/config/pd-config-feature-flags.js.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-types.d.ts +8 -0
- package/core/dist/runtime-v2/config/pd-config-types.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-types.js +2 -0
- package/core/dist/runtime-v2/config/pd-config-types.js.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-validate.d.ts.map +1 -1
- package/core/dist/runtime-v2/config/pd-config-validate.js +48 -3
- package/core/dist/runtime-v2/config/pd-config-validate.js.map +1 -1
- package/core/dist/runtime-v2/core-principles/__tests__/core-axiom-block.test.js +36 -8
- package/core/dist/runtime-v2/core-principles/__tests__/core-axiom-block.test.js.map +1 -1
- package/core/dist/runtime-v2/core-principles/__tests__/core-principle-registry.test.js +36 -12
- package/core/dist/runtime-v2/core-principles/__tests__/core-principle-registry.test.js.map +1 -1
- package/core/dist/runtime-v2/core-principles/core-axiom-block.d.ts +22 -8
- package/core/dist/runtime-v2/core-principles/core-axiom-block.d.ts.map +1 -1
- package/core/dist/runtime-v2/core-principles/core-axiom-block.js +28 -13
- package/core/dist/runtime-v2/core-principles/core-axiom-block.js.map +1 -1
- package/core/dist/runtime-v2/core-principles/core-principle-registry.d.ts +29 -4
- package/core/dist/runtime-v2/core-principles/core-principle-registry.d.ts.map +1 -1
- package/core/dist/runtime-v2/core-principles/core-principle-registry.js +68 -33
- package/core/dist/runtime-v2/core-principles/core-principle-registry.js.map +1 -1
- package/core/dist/runtime-v2/core-principles/index.d.ts +3 -3
- package/core/dist/runtime-v2/core-principles/index.d.ts.map +1 -1
- package/core/dist/runtime-v2/core-principles/index.js +1 -1
- package/core/dist/runtime-v2/core-principles/index.js.map +1 -1
- package/core/dist/runtime-v2/evolution/evolution-types.d.ts +2 -1
- package/core/dist/runtime-v2/evolution/evolution-types.d.ts.map +1 -1
- package/core/dist/runtime-v2/evolution/evolution-types.js.map +1 -1
- package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.d.ts +2 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.js +48 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.js.map +1 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.d.ts +2 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.js +46 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.js.map +1 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-contract.test.js +86 -31
- package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-contract.test.js.map +1 -1
- package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.d.ts +2 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.d.ts.map +1 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.js +83 -0
- package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.js.map +1 -0
- package/core/dist/runtime-v2/feature-flags/feature-flag-contract.d.ts +19 -1
- package/core/dist/runtime-v2/feature-flags/feature-flag-contract.d.ts.map +1 -1
- package/core/dist/runtime-v2/feature-flags/feature-flag-contract.js +128 -10
- package/core/dist/runtime-v2/feature-flags/feature-flag-contract.js.map +1 -1
- package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.d.ts +37 -0
- package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.d.ts.map +1 -0
- package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.js +304 -0
- package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.js.map +1 -0
- package/core/dist/runtime-v2/feature-flags/index.d.ts +4 -2
- package/core/dist/runtime-v2/feature-flags/index.d.ts.map +1 -1
- package/core/dist/runtime-v2/feature-flags/index.js +3 -1
- package/core/dist/runtime-v2/feature-flags/index.js.map +1 -1
- package/core/dist/runtime-v2/governance-experience-contract.d.ts +468 -0
- package/core/dist/runtime-v2/governance-experience-contract.d.ts.map +1 -0
- package/core/dist/runtime-v2/governance-experience-contract.js +208 -0
- package/core/dist/runtime-v2/governance-experience-contract.js.map +1 -0
- package/core/dist/runtime-v2/governance-experience.d.ts +11 -0
- package/core/dist/runtime-v2/governance-experience.d.ts.map +1 -0
- package/core/dist/runtime-v2/governance-experience.js +276 -0
- package/core/dist/runtime-v2/governance-experience.js.map +1 -0
- package/core/dist/runtime-v2/index.d.ts +20 -8
- package/core/dist/runtime-v2/index.d.ts.map +1 -1
- package/core/dist/runtime-v2/index.js +20 -6
- package/core/dist/runtime-v2/index.js.map +1 -1
- package/core/dist/runtime-v2/internalization/__tests__/artificer-output-retry-flag.test.js +29 -10
- package/core/dist/runtime-v2/internalization/__tests__/artificer-output-retry-flag.test.js.map +1 -1
- package/core/dist/runtime-v2/owner-identity.d.ts +69 -0
- package/core/dist/runtime-v2/owner-identity.d.ts.map +1 -0
- package/core/dist/runtime-v2/owner-identity.js +179 -0
- package/core/dist/runtime-v2/owner-identity.js.map +1 -0
- package/core/dist/runtime-v2/pain-signal-runtime-factory.d.ts.map +1 -1
- package/core/dist/runtime-v2/pain-signal-runtime-factory.js +2 -3
- package/core/dist/runtime-v2/pain-signal-runtime-factory.js.map +1 -1
- package/core/dist/runtime-v2/product-telemetry/daily-identity.d.ts +70 -0
- package/core/dist/runtime-v2/product-telemetry/daily-identity.d.ts.map +1 -0
- package/core/dist/runtime-v2/product-telemetry/daily-identity.js +89 -0
- package/core/dist/runtime-v2/product-telemetry/daily-identity.js.map +1 -0
- package/core/dist/runtime-v2/product-telemetry/snapshot-contract.d.ts +110 -0
- package/core/dist/runtime-v2/product-telemetry/snapshot-contract.d.ts.map +1 -0
- package/core/dist/runtime-v2/product-telemetry/snapshot-contract.js +250 -0
- package/core/dist/runtime-v2/product-telemetry/snapshot-contract.js.map +1 -0
- package/core/dist/runtime-v2/pruning-read-model.d.ts +2 -1
- package/core/dist/runtime-v2/pruning-read-model.d.ts.map +1 -1
- package/core/dist/runtime-v2/pruning-read-model.js.map +1 -1
- package/core/dist/runtime-v2/receipt-coverage.d.ts +63 -0
- package/core/dist/runtime-v2/receipt-coverage.d.ts.map +1 -0
- package/core/dist/runtime-v2/receipt-coverage.js +19 -0
- package/core/dist/runtime-v2/receipt-coverage.js.map +1 -0
- package/core/dist/runtime-v2/recovery-actions-log.d.ts +7 -0
- package/core/dist/runtime-v2/recovery-actions-log.d.ts.map +1 -1
- package/core/dist/runtime-v2/recovery-actions-log.js +6 -0
- package/core/dist/runtime-v2/recovery-actions-log.js.map +1 -1
- package/core/dist/runtime-v2/runtime-protocol.js +1 -1
- package/core/dist/runtime-v2/runtime-protocol.js.map +1 -1
- package/core/dist/runtime-v2/store/task/__tests__/sqlite-task-store.failed-tasks.test.js +17 -1
- package/core/dist/runtime-v2/store/task/__tests__/sqlite-task-store.failed-tasks.test.js.map +1 -1
- package/core/dist/runtime-v2/store/task/sqlite-task-store.d.ts.map +1 -1
- package/core/dist/runtime-v2/store/task/sqlite-task-store.js +10 -0
- package/core/dist/runtime-v2/store/task/sqlite-task-store.js.map +1 -1
- package/core/dist/runtime-v2/store/task/task-types.d.ts +2 -0
- package/core/dist/runtime-v2/store/task/task-types.d.ts.map +1 -1
- package/core/dist/runtime-v2/task-status.d.ts +9 -5
- package/core/dist/runtime-v2/task-status.d.ts.map +1 -1
- package/core/dist/runtime-v2/task-status.js +15 -7
- package/core/dist/runtime-v2/task-status.js.map +1 -1
- package/core/dist/runtime-v2/types/event-types.d.ts +4 -0
- package/core/dist/runtime-v2/types/event-types.d.ts.map +1 -1
- package/core/dist/runtime-v2/types/event-types.js.map +1 -1
- package/core/dist/runtime-v2/types/index.d.ts +1 -1
- package/core/dist/runtime-v2/types/index.d.ts.map +1 -1
- package/core/dist/runtime-v2/types/index.js +1 -1
- package/core/dist/runtime-v2/types/index.js.map +1 -1
- package/core/dist/runtime-v2/types/principle-enums.d.ts +3 -2
- package/core/dist/runtime-v2/types/principle-enums.d.ts.map +1 -1
- package/core/dist/runtime-v2/types/principle-enums.js +11 -5
- package/core/dist/runtime-v2/types/principle-enums.js.map +1 -1
- package/core/dist/runtime-v2/types/principle-schema.d.ts +1 -1
- package/core/dist/runtime-v2/types/principle-tree-store.d.ts +1 -1
- package/core/dist/runtime-v2/utils/cli-process-runner.d.ts.map +1 -1
- package/core/dist/runtime-v2/utils/cli-process-runner.js +3 -2
- package/core/dist/runtime-v2/utils/cli-process-runner.js.map +1 -1
- package/core/package.json +1 -2
- package/dist/i18n.d.ts.map +1 -1
- package/dist/i18n.js +4 -2
- package/dist/i18n.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +47 -11
- package/dist/index.js.map +1 -1
- package/dist/installer.d.ts +31 -5
- package/dist/installer.d.ts.map +1 -1
- package/dist/installer.js +472 -161
- package/dist/installer.js.map +1 -1
- package/dist/installers/codex-host-installer.d.ts.map +1 -1
- package/dist/installers/codex-host-installer.js +4 -0
- package/dist/installers/codex-host-installer.js.map +1 -1
- package/dist/mvp-config.d.ts +10 -0
- package/dist/mvp-config.d.ts.map +1 -1
- package/dist/mvp-config.js +30 -3
- package/dist/mvp-config.js.map +1 -1
- package/dist/uninstaller.d.ts +9 -1
- package/dist/uninstaller.d.ts.map +1 -1
- package/dist/uninstaller.js +103 -23
- package/dist/uninstaller.js.map +1 -1
- package/dist/update/atomic-file.d.ts +35 -0
- package/dist/update/atomic-file.d.ts.map +1 -0
- package/dist/update/atomic-file.js +120 -0
- package/dist/update/atomic-file.js.map +1 -0
- package/dist/update/bootstrap-protocol.d.ts +55 -0
- package/dist/update/bootstrap-protocol.d.ts.map +1 -0
- package/dist/update/bootstrap-protocol.js +132 -0
- package/dist/update/bootstrap-protocol.js.map +1 -0
- package/dist/update/channel-metadata.d.ts +28 -0
- package/dist/update/channel-metadata.d.ts.map +1 -0
- package/dist/update/channel-metadata.js +90 -0
- package/dist/update/channel-metadata.js.map +1 -0
- package/dist/update/channel-promotion.d.ts +39 -0
- package/dist/update/channel-promotion.d.ts.map +1 -0
- package/dist/update/channel-promotion.js +55 -0
- package/dist/update/channel-promotion.js.map +1 -0
- package/dist/update/data-compatibility.d.ts +35 -0
- package/dist/update/data-compatibility.d.ts.map +1 -0
- package/dist/update/data-compatibility.js +45 -0
- package/dist/update/data-compatibility.js.map +1 -0
- package/dist/update/install-layout.d.ts +59 -0
- package/dist/update/install-layout.d.ts.map +1 -0
- package/dist/update/install-layout.js +127 -0
- package/dist/update/install-layout.js.map +1 -0
- package/dist/update/legacy-migration.d.ts +56 -0
- package/dist/update/legacy-migration.d.ts.map +1 -0
- package/dist/update/legacy-migration.js +254 -0
- package/dist/update/legacy-migration.js.map +1 -0
- package/dist/update/product-identity.d.ts +50 -0
- package/dist/update/product-identity.d.ts.map +1 -0
- package/dist/update/product-identity.js +63 -0
- package/dist/update/product-identity.js.map +1 -0
- package/dist/update/release-asset-manifest.d.ts +31 -0
- package/dist/update/release-asset-manifest.d.ts.map +1 -0
- package/dist/update/release-asset-manifest.js +161 -0
- package/dist/update/release-asset-manifest.js.map +1 -0
- package/dist/update/release-identity.d.ts +33 -0
- package/dist/update/release-identity.d.ts.map +1 -0
- package/dist/update/release-identity.js +108 -0
- package/dist/update/release-identity.js.map +1 -0
- package/dist/update/release-manager.d.ts +96 -0
- package/dist/update/release-manager.d.ts.map +1 -0
- package/dist/update/release-manager.js +253 -0
- package/dist/update/release-manager.js.map +1 -0
- package/dist/update/release-metadata.d.ts +57 -0
- package/dist/update/release-metadata.d.ts.map +1 -0
- package/dist/update/release-metadata.js +200 -0
- package/dist/update/release-metadata.js.map +1 -0
- package/dist/update/release-policy.d.ts +51 -0
- package/dist/update/release-policy.d.ts.map +1 -0
- package/dist/update/release-policy.js +103 -0
- package/dist/update/release-policy.js.map +1 -0
- package/dist/update/rollback-policy.d.ts +56 -0
- package/dist/update/rollback-policy.d.ts.map +1 -0
- package/dist/update/rollback-policy.js +61 -0
- package/dist/update/rollback-policy.js.map +1 -0
- package/dist/update/transaction-journal.d.ts +121 -0
- package/dist/update/transaction-journal.d.ts.map +1 -0
- package/dist/update/transaction-journal.js +333 -0
- package/dist/update/transaction-journal.js.map +1 -0
- package/dist/update/trust-metadata.d.ts +55 -0
- package/dist/update/trust-metadata.d.ts.map +1 -0
- package/dist/update/trust-metadata.js +170 -0
- package/dist/update/trust-metadata.js.map +1 -0
- package/dist/update/update-history.d.ts +46 -0
- package/dist/update/update-history.d.ts.map +1 -0
- package/dist/update/update-history.js +123 -0
- package/dist/update/update-history.js.map +1 -0
- package/dist/utils/env.d.ts +7 -0
- package/dist/utils/env.d.ts.map +1 -1
- package/dist/utils/env.js +134 -44
- package/dist/utils/env.js.map +1 -1
- package/host-runtime/dist/governance-observation-store.d.ts +172 -0
- package/host-runtime/dist/governance-observation-store.js +649 -0
- package/host-runtime/dist/index.d.ts +6 -0
- package/host-runtime/dist/index.js +8 -0
- package/host-runtime/dist/product-telemetry/consent-store.d.ts +107 -0
- package/host-runtime/dist/product-telemetry/consent-store.js +329 -0
- package/host-runtime/dist/product-telemetry/eligibility.d.ts +53 -0
- package/host-runtime/dist/product-telemetry/eligibility.js +69 -0
- package/host-runtime/dist/product-telemetry/exporter.d.ts +46 -0
- package/host-runtime/dist/product-telemetry/exporter.js +71 -0
- package/host-runtime/dist/product-telemetry/milestone-readers.d.ts +61 -0
- package/host-runtime/dist/product-telemetry/milestone-readers.js +234 -0
- package/host-runtime/dist/product-telemetry/service.d.ts +142 -0
- package/host-runtime/dist/product-telemetry/service.js +532 -0
- package/host-runtime/dist/product-telemetry/workspace-scope.d.ts +38 -0
- package/host-runtime/dist/product-telemetry/workspace-scope.js +64 -0
- package/host-runtime/package.json +5 -0
- package/install-layout/dist/index.d.ts +48 -0
- package/install-layout/dist/index.js +81 -0
- package/install-layout/dist/index.test.d.ts +1 -0
- package/install-layout/dist/index.test.js +34 -0
- package/install-layout/package.json +29 -0
- package/package.json +16 -6
- package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.d.ts +9 -0
- package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.d.ts.map +1 -0
- package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.js +76 -0
- package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.js.map +1 -0
- package/pd-cli/dist/commands/__tests__/version.test.d.ts +2 -0
- package/pd-cli/dist/commands/__tests__/version.test.d.ts.map +1 -0
- package/pd-cli/dist/commands/__tests__/version.test.js +134 -0
- package/pd-cli/dist/commands/__tests__/version.test.js.map +1 -0
- package/pd-cli/dist/commands/console.d.ts.map +1 -1
- package/pd-cli/dist/commands/console.js +29 -10
- package/pd-cli/dist/commands/console.js.map +1 -1
- package/pd-cli/dist/commands/pain-record.d.ts.map +1 -1
- package/pd-cli/dist/commands/pain-record.js +6 -15
- package/pd-cli/dist/commands/pain-record.js.map +1 -1
- package/pd-cli/dist/commands/runtime-activation.d.ts +29 -0
- package/pd-cli/dist/commands/runtime-activation.d.ts.map +1 -1
- package/pd-cli/dist/commands/runtime-activation.js +70 -31
- package/pd-cli/dist/commands/runtime-activation.js.map +1 -1
- package/pd-cli/dist/commands/runtime-internalization-enqueue-successors.d.ts.map +1 -1
- package/pd-cli/dist/commands/runtime-internalization-enqueue-successors.js +2 -2
- package/pd-cli/dist/commands/runtime-internalization-enqueue-successors.js.map +1 -1
- package/pd-cli/dist/commands/telemetry.d.ts +82 -0
- package/pd-cli/dist/commands/telemetry.d.ts.map +1 -0
- package/pd-cli/dist/commands/telemetry.js +268 -0
- package/pd-cli/dist/commands/telemetry.js.map +1 -0
- package/pd-cli/dist/commands/version.d.ts +11 -0
- package/pd-cli/dist/commands/version.d.ts.map +1 -0
- package/pd-cli/dist/commands/version.js +48 -0
- package/pd-cli/dist/commands/version.js.map +1 -0
- package/pd-cli/dist/index.js +35 -2
- package/pd-cli/dist/index.js.map +1 -1
- package/pd-cli/dist/services/version-report.d.ts +44 -0
- package/pd-cli/dist/services/version-report.d.ts.map +1 -0
- package/pd-cli/dist/services/version-report.js +152 -0
- package/pd-cli/dist/services/version-report.js.map +1 -0
- package/pd-cli/package.json +1 -0
- package/plugin/dist/bundle.js +868 -936
- package/plugin/dist/core/init.d.ts +2 -1
- package/plugin/dist/core/principle-application-ledger.d.ts +10 -0
- package/plugin/dist/core/product-telemetry-trigger.d.ts +14 -0
- package/plugin/dist/core/thinking-os-parser.d.ts +5 -2
- package/plugin/dist/governance-audit.js +386 -0
- package/plugin/dist/hooks/gate-block-helper.d.ts +25 -1
- package/plugin/dist/hooks/gate.d.ts +22 -0
- package/plugin/dist/rulehost-evidence.js +832 -0
- package/plugin/dist/templates/langs/en/principles/THINKING_OS.md +53 -45
- package/plugin/dist/templates/langs/en/skills/pd-mentor/SKILL.md +1 -1
- package/plugin/dist/templates/langs/zh/principles/THINKING_OS.md +62 -46
- package/plugin/dist/templates/langs/zh/skills/pd-mentor/SKILL.md +1 -1
- package/plugin/dist/templates/workspace/.principles/THINKING_OS.md +66 -38
- package/plugin/openclaw.plugin.json +1 -1
- package/plugin/package.json +1 -1
- package/plugin/templates/langs/en/principles/THINKING_OS.md +53 -45
- package/plugin/templates/langs/en/skills/pd-mentor/SKILL.md +1 -1
- package/plugin/templates/langs/zh/principles/THINKING_OS.md +62 -46
- package/plugin/templates/langs/zh/skills/pd-mentor/SKILL.md +1 -1
- package/plugin/templates/workspace/.principles/THINKING_OS.md +66 -38
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
// PRI-613: feedback submit-ladder data shapes derive from the canonical shared
|
|
2
|
+
// schema contract via `import type` ONLY — a runtime import would bundle
|
|
3
|
+
// @sinclair/typebox into the browser (~850KB, measured; SPEC §10.5 stop
|
|
4
|
+
// condition). The runtime const FEEDBACK_CHANNEL_IDS lives in a separate
|
|
5
|
+
// dependency-free module so browser code can check channel IDs safely.
|
|
6
|
+
import { FEEDBACK_CHANNEL_IDS } from '../../shared/feedback-channel-ids.js';
|
|
1
7
|
// ── Primitive guards ──────────────────────────────────────────────────────────
|
|
2
8
|
function isString(v) {
|
|
3
9
|
return typeof v === 'string';
|
|
@@ -124,6 +130,101 @@ function isOwnerGovernanceView(value) {
|
|
|
124
130
|
export function validateOwnerGovernanceView(value) {
|
|
125
131
|
return isOwnerGovernanceView(value) ? value : null;
|
|
126
132
|
}
|
|
133
|
+
// ── PRI-586: Governance Experience Snapshot v1.5.1 (browser-local validator) ──
|
|
134
|
+
// Mirrors the authoritative TypeBox contract in principles-core
|
|
135
|
+
// (governance-experience-contract.ts). Type-only import above keeps the client
|
|
136
|
+
// bundle free of the Node-oriented core barrel (ERR-100).
|
|
137
|
+
const governancePrimaryAttentions = new Set(['setup_required', 'owner_decision_required', 'recovery_required', 'degraded', 'background_processing', 'all_clear']);
|
|
138
|
+
const governanceExperienceReasonCodes = new Set([
|
|
139
|
+
'governance.exp.reason.owner_identity_missing', 'governance.exp.reason.approval_pending',
|
|
140
|
+
'governance.exp.reason.rulecode_owner_decision', 'governance.exp.reason.no_pending_decision',
|
|
141
|
+
'governance.exp.reason.owner_decision_available', 'governance.exp.reason.break_glass_entry',
|
|
142
|
+
'governance.exp.reason.recovery_required', 'governance.exp.reason.source_unavailable',
|
|
143
|
+
'governance.exp.reason.config_invalid', 'governance.exp.reason.processing',
|
|
144
|
+
'governance.exp.reason.workspace_clear', 'governance.exp.reason.workspace_empty',
|
|
145
|
+
]);
|
|
146
|
+
const governanceExperienceNextActionCodes = new Set([
|
|
147
|
+
'governance.exp.next.configure_owner', 'governance.exp.next.review_approvals',
|
|
148
|
+
'governance.exp.next.inspect_recovery', 'governance.exp.next.inspect_sources',
|
|
149
|
+
'governance.exp.next.fix_config', 'governance.exp.next.monitor', 'governance.exp.next.none',
|
|
150
|
+
]);
|
|
151
|
+
const governanceObservedAuthorities = new Set(['operator_legacy', 'configured_owner', 'break_glass']);
|
|
152
|
+
const governanceActionKinds = new Set(['principle_approval', 'rulecode_owner_decision', 'emergency_pause']);
|
|
153
|
+
const governanceActivityCategories = new Set(['blocked', 'needs_recovery', 'needs_decision', 'processing']);
|
|
154
|
+
const governanceEnvironmentValues = new Set(['production', 'development', 'demo', 'test', 'unknown']);
|
|
155
|
+
const governanceEnvironmentSources = new Set(['workspace_config', 'missing']);
|
|
156
|
+
const governanceIssueGroupSources = new Set(['ledger', 'artifact', 'task', 'approval', 'activation', 'trajectory', 'lineage', 'workspace']);
|
|
157
|
+
function isGovernanceActivityItem(value) {
|
|
158
|
+
return isObject(value) && hasOwnFields(value, ['category', 'reasonCode', 'sourceRefs'])
|
|
159
|
+
&& isStringEnum(value.category, governanceActivityCategories)
|
|
160
|
+
&& typeof value.reasonCode === 'string' && value.reasonCode.length > 0
|
|
161
|
+
&& isGovernanceSourceRefs(value.sourceRefs)
|
|
162
|
+
&& (!Object.hasOwn(value, 'principleId') || (typeof value.principleId === 'string' && value.principleId.length > 0));
|
|
163
|
+
}
|
|
164
|
+
function isGovernanceActionReadiness(value) {
|
|
165
|
+
return isObject(value) && hasOwnFields(value, ['kind', 'observedAuthority', 'status', 'reasonCode', 'nextActionCode'])
|
|
166
|
+
&& isStringEnum(value.kind, governanceActionKinds)
|
|
167
|
+
&& isStringEnum(value.observedAuthority, governanceObservedAuthorities)
|
|
168
|
+
&& isStringEnum(value.status, new Set(['entry_conditions_met', 'blocked']))
|
|
169
|
+
&& isStringEnum(value.reasonCode, governanceExperienceReasonCodes)
|
|
170
|
+
&& isStringEnum(value.nextActionCode, governanceExperienceNextActionCodes);
|
|
171
|
+
}
|
|
172
|
+
function isEnvironmentContext(value) {
|
|
173
|
+
return isObject(value) && hasOwnFields(value, ['environment', 'source'])
|
|
174
|
+
&& isStringEnum(value.environment, governanceEnvironmentValues)
|
|
175
|
+
&& isStringEnum(value.source, governanceEnvironmentSources)
|
|
176
|
+
&& (!Object.hasOwn(value, 'configIssue') || (typeof value.configIssue === 'string' && value.configIssue.length > 0));
|
|
177
|
+
}
|
|
178
|
+
function isGovernanceExperienceSnapshot(value) {
|
|
179
|
+
if (!isObject(value) || !hasOwnFields(value, ['schemaVersion', 'snapshotId', 'asOf', 'summary', 'readiness', 'activity', 'trustContext', 'dataQuality']))
|
|
180
|
+
return false;
|
|
181
|
+
if (value.schemaVersion !== '1' || typeof value.snapshotId !== 'string' || value.snapshotId.length === 0 || !isGovernanceTimestamp(value.asOf))
|
|
182
|
+
return false;
|
|
183
|
+
const { summary, readiness, activity, trustContext, dataQuality } = value;
|
|
184
|
+
if (!isObject(summary) || !hasOwnFields(summary, ['primaryAttention', 'headlineCode', 'reasonCode', 'nextActionCode'])
|
|
185
|
+
|| !isStringEnum(summary.primaryAttention, governancePrimaryAttentions)
|
|
186
|
+
|| typeof summary.headlineCode !== 'string' || summary.headlineCode.length === 0
|
|
187
|
+
|| !isStringEnum(summary.reasonCode, governanceExperienceReasonCodes)
|
|
188
|
+
|| !isStringEnum(summary.nextActionCode, governanceExperienceNextActionCodes))
|
|
189
|
+
return false;
|
|
190
|
+
if (!isObject(readiness) || !hasOwnFields(readiness, ['authenticationMode', 'ownerIdentityConfiguration', 'governanceActions'])
|
|
191
|
+
|| !isStringEnum(readiness.authenticationMode, new Set(['authenticated', 'no_auth']))
|
|
192
|
+
|| !isStringEnum(readiness.ownerIdentityConfiguration, new Set(['configured', 'missing']))
|
|
193
|
+
|| !Array.isArray(readiness.governanceActions) || readiness.governanceActions.length !== 3
|
|
194
|
+
|| !readiness.governanceActions.every(isGovernanceActionReadiness))
|
|
195
|
+
return false;
|
|
196
|
+
if (!isObject(activity) || !hasOwnFields(activity, ['primaryAttention', 'categories'])
|
|
197
|
+
|| !isStringEnum(activity.primaryAttention, governancePrimaryAttentions)
|
|
198
|
+
|| !Array.isArray(activity.categories)
|
|
199
|
+
|| !activity.categories.every((category) => isObject(category)
|
|
200
|
+
&& hasOwnFields(category, ['category', 'count', 'items', 'hasMore'])
|
|
201
|
+
&& isStringEnum(category.category, governanceActivityCategories)
|
|
202
|
+
&& typeof category.count === 'number' && Number.isInteger(category.count) && category.count >= 0
|
|
203
|
+
&& Array.isArray(category.items) && category.items.length <= 10 && category.items.every(isGovernanceActivityItem)
|
|
204
|
+
&& typeof category.hasMore === 'boolean'))
|
|
205
|
+
return false;
|
|
206
|
+
if (!isObject(trustContext) || !hasOwnFields(trustContext, ['environmentContext', 'lineageTransparency'])
|
|
207
|
+
|| !isEnvironmentContext(trustContext.environmentContext)
|
|
208
|
+
|| !isObject(trustContext.lineageTransparency)
|
|
209
|
+
|| !hasOwnFields(trustContext.lineageTransparency, ['confidence', 'strongViewCount', 'weakViewCount', 'unknownViewCount'])
|
|
210
|
+
|| !isStringEnum(trustContext.lineageTransparency.confidence, lineageConfidences)
|
|
211
|
+
|| [trustContext.lineageTransparency.strongViewCount, trustContext.lineageTransparency.weakViewCount, trustContext.lineageTransparency.unknownViewCount]
|
|
212
|
+
.some(count => typeof count !== 'number' || !Number.isInteger(count) || count < 0))
|
|
213
|
+
return false;
|
|
214
|
+
return isObject(dataQuality) && hasOwnFields(dataQuality, ['degraded', 'issueGroups', 'hasMore'])
|
|
215
|
+
&& typeof dataQuality.degraded === 'boolean' && typeof dataQuality.hasMore === 'boolean'
|
|
216
|
+
&& Array.isArray(dataQuality.issueGroups) && dataQuality.issueGroups.length <= 10
|
|
217
|
+
&& dataQuality.issueGroups.every((group) => isObject(group)
|
|
218
|
+
&& hasOwnFields(group, ['source', 'reasonCode', 'nextActionCode', 'count', 'sampleRefs'])
|
|
219
|
+
&& isStringEnum(group.source, governanceIssueGroupSources)
|
|
220
|
+
&& typeof group.reasonCode === 'string' && group.reasonCode.length > 0
|
|
221
|
+
&& typeof group.nextActionCode === 'string' && group.nextActionCode.length > 0
|
|
222
|
+
&& typeof group.count === 'number' && Number.isInteger(group.count) && group.count >= 1
|
|
223
|
+
&& isGovernanceSourceRefs(group.sampleRefs));
|
|
224
|
+
}
|
|
225
|
+
export function validateGovernanceExperienceSnapshot(value) {
|
|
226
|
+
return isGovernanceExperienceSnapshot(value) ? value : null;
|
|
227
|
+
}
|
|
127
228
|
export function validateErrorResponse(v) {
|
|
128
229
|
if (!isObject(v))
|
|
129
230
|
return null;
|
|
@@ -211,35 +312,37 @@ export function validateDeleteEnvelope(v) {
|
|
|
211
312
|
return null;
|
|
212
313
|
return { deleted: v.deleted };
|
|
213
314
|
}
|
|
214
|
-
|
|
315
|
+
function isValidChannelStatus(item) {
|
|
316
|
+
if (!Object.hasOwn(item, 'id') || !isString(item.id) || !FEEDBACK_CHANNEL_IDS.includes(item.id))
|
|
317
|
+
return null;
|
|
318
|
+
if (!Object.hasOwn(item, 'available') || !isBoolean(item.available))
|
|
319
|
+
return null;
|
|
320
|
+
const reason = readNullableString(item, 'reason');
|
|
321
|
+
const nextAction = readNullableString(item, 'nextAction');
|
|
322
|
+
if (!reason.valid || !nextAction.valid)
|
|
323
|
+
return null;
|
|
324
|
+
const status = { id: item.id, available: item.available };
|
|
325
|
+
if (reason.value !== null)
|
|
326
|
+
status.reason = reason.value;
|
|
327
|
+
if (nextAction.value !== null)
|
|
328
|
+
status.nextAction = nextAction.value;
|
|
329
|
+
return status;
|
|
330
|
+
}
|
|
215
331
|
export function validateFeedbackChannels(v) {
|
|
216
332
|
if (!isObject(v))
|
|
217
333
|
return null;
|
|
218
334
|
if (!Object.hasOwn(v, 'channels') || !Array.isArray(v.channels))
|
|
219
335
|
return null;
|
|
336
|
+
// Per-item leniency preserved: invalid channel entries are skipped, the
|
|
337
|
+
// envelope is not rejected (legacy behavior — a bad single probe must not
|
|
338
|
+
// hide the other channels).
|
|
220
339
|
const channels = [];
|
|
221
340
|
for (const item of v.channels) {
|
|
222
341
|
if (!isObject(item))
|
|
223
342
|
continue;
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
continue;
|
|
228
|
-
const status = {
|
|
229
|
-
id: item.id,
|
|
230
|
-
available: item.available,
|
|
231
|
-
};
|
|
232
|
-
const reason = readNullableString(item, 'reason');
|
|
233
|
-
const nextAction = readNullableString(item, 'nextAction');
|
|
234
|
-
if (!reason.valid)
|
|
235
|
-
return null;
|
|
236
|
-
if (!nextAction.valid)
|
|
237
|
-
return null;
|
|
238
|
-
if (reason.value !== null)
|
|
239
|
-
status.reason = reason.value;
|
|
240
|
-
if (nextAction.value !== null)
|
|
241
|
-
status.nextAction = nextAction.value;
|
|
242
|
-
channels.push(status);
|
|
343
|
+
const status = isValidChannelStatus(item);
|
|
344
|
+
if (status !== null)
|
|
345
|
+
channels.push(status);
|
|
243
346
|
}
|
|
244
347
|
return { channels };
|
|
245
348
|
}
|
|
@@ -648,6 +751,11 @@ export function validateRecoveryResult(v) {
|
|
|
648
751
|
newStatus: v.newStatus,
|
|
649
752
|
result: v.result,
|
|
650
753
|
};
|
|
754
|
+
if (Object.hasOwn(v, 'forceApplied')) {
|
|
755
|
+
if (!isBoolean(v.forceApplied))
|
|
756
|
+
return null;
|
|
757
|
+
result.forceApplied = v.forceApplied;
|
|
758
|
+
}
|
|
651
759
|
if (Object.hasOwn(v, 'nextAction')) {
|
|
652
760
|
if (!isString(v.nextAction))
|
|
653
761
|
return null;
|
|
@@ -1004,6 +1112,19 @@ export function validateUpdateStatus(v) {
|
|
|
1004
1112
|
}
|
|
1005
1113
|
return result;
|
|
1006
1114
|
}
|
|
1115
|
+
export const UPDATE_HISTORY_KINDS = [
|
|
1116
|
+
'update',
|
|
1117
|
+
'reinstall',
|
|
1118
|
+
'legacy_migration',
|
|
1119
|
+
'rollback',
|
|
1120
|
+
'refusal',
|
|
1121
|
+
'failure',
|
|
1122
|
+
'recovery',
|
|
1123
|
+
'unknown',
|
|
1124
|
+
];
|
|
1125
|
+
function isUpdateHistoryKind(value) {
|
|
1126
|
+
return typeof value === 'string' && UPDATE_HISTORY_KINDS.includes(value);
|
|
1127
|
+
}
|
|
1007
1128
|
export function validateUpdateHistoryEntry(v) {
|
|
1008
1129
|
if (!isObject(v))
|
|
1009
1130
|
return null;
|
|
@@ -1017,10 +1138,25 @@ export function validateUpdateHistoryEntry(v) {
|
|
|
1017
1138
|
return null;
|
|
1018
1139
|
if (!Object.hasOwn(v, 'success') || !isBoolean(v.success))
|
|
1019
1140
|
return null;
|
|
1020
|
-
|
|
1141
|
+
if (!Object.hasOwn(v, 'kind') || !isUpdateHistoryKind(v.kind))
|
|
1142
|
+
return null;
|
|
1143
|
+
const entry = {
|
|
1144
|
+
id: v.id,
|
|
1145
|
+
timestamp: v.timestamp,
|
|
1146
|
+
fromVersion: v.fromVersion,
|
|
1147
|
+
toVersion: v.toVersion,
|
|
1148
|
+
success: v.success,
|
|
1149
|
+
kind: v.kind,
|
|
1150
|
+
};
|
|
1021
1151
|
if (Object.hasOwn(v, 'backupPath') && isString(v.backupPath)) {
|
|
1022
1152
|
entry.backupPath = v.backupPath;
|
|
1023
1153
|
}
|
|
1154
|
+
if (Object.hasOwn(v, 'reason') && isString(v.reason)) {
|
|
1155
|
+
entry.reason = v.reason;
|
|
1156
|
+
}
|
|
1157
|
+
if (Object.hasOwn(v, 'nextAction') && isString(v.nextAction)) {
|
|
1158
|
+
entry.nextAction = v.nextAction;
|
|
1159
|
+
}
|
|
1024
1160
|
return entry;
|
|
1025
1161
|
}
|
|
1026
1162
|
export function validateUpdateHistory(v) {
|
|
@@ -2099,3 +2235,94 @@ export function validateIntentVersions(v) {
|
|
|
2099
2235
|
return null;
|
|
2100
2236
|
return { versions };
|
|
2101
2237
|
}
|
|
2238
|
+
function parseOwnerGovernanceReadiness(v) {
|
|
2239
|
+
if (!isObject(v))
|
|
2240
|
+
return null;
|
|
2241
|
+
if (!Object.hasOwn(v, 'authenticationMode') || (v.authenticationMode !== 'authenticated' && v.authenticationMode !== 'no_auth'))
|
|
2242
|
+
return null;
|
|
2243
|
+
if (!Object.hasOwn(v, 'ownerIdentityConfiguration') || (v.ownerIdentityConfiguration !== 'configured' && v.ownerIdentityConfiguration !== 'missing'))
|
|
2244
|
+
return null;
|
|
2245
|
+
return { authenticationMode: v.authenticationMode, ownerIdentityConfiguration: v.ownerIdentityConfiguration };
|
|
2246
|
+
}
|
|
2247
|
+
function parseOwnerIdentityRecordData(v) {
|
|
2248
|
+
if (v === undefined || v === null)
|
|
2249
|
+
return null;
|
|
2250
|
+
if (!isObject(v))
|
|
2251
|
+
return null;
|
|
2252
|
+
const rec = v;
|
|
2253
|
+
if (!Object.hasOwn(rec, 'schemaVersion') || !isNumber(rec.schemaVersion))
|
|
2254
|
+
return null;
|
|
2255
|
+
if (!Object.hasOwn(rec, 'ownerId') || !isString(rec.ownerId))
|
|
2256
|
+
return null;
|
|
2257
|
+
if (!Object.hasOwn(rec, 'credentialId') || !isString(rec.credentialId))
|
|
2258
|
+
return null;
|
|
2259
|
+
if (!Object.hasOwn(rec, 'registeredAt') || !isString(rec.registeredAt))
|
|
2260
|
+
return null;
|
|
2261
|
+
return { schemaVersion: rec.schemaVersion, ownerId: rec.ownerId, credentialId: rec.credentialId, registeredAt: rec.registeredAt };
|
|
2262
|
+
}
|
|
2263
|
+
export function validateOwnerIdentityView(v) {
|
|
2264
|
+
if (!isObject(v))
|
|
2265
|
+
return null;
|
|
2266
|
+
if (!Object.hasOwn(v, 'resolved') || !isObject(v.resolved))
|
|
2267
|
+
return null;
|
|
2268
|
+
const r = v.resolved;
|
|
2269
|
+
if (!Object.hasOwn(r, 'ownerId') || (r.ownerId !== null && !isString(r.ownerId)))
|
|
2270
|
+
return null;
|
|
2271
|
+
if (!Object.hasOwn(r, 'credentialId') || (r.credentialId !== null && !isString(r.credentialId)))
|
|
2272
|
+
return null;
|
|
2273
|
+
if (!Object.hasOwn(r, 'source') || (r.source !== 'env' && r.source !== 'file' && r.source !== 'none' && r.source !== 'invalid_env'))
|
|
2274
|
+
return null;
|
|
2275
|
+
const governance = parseOwnerGovernanceReadiness(v.governance);
|
|
2276
|
+
if (governance === null)
|
|
2277
|
+
return null;
|
|
2278
|
+
const out = {
|
|
2279
|
+
resolved: {
|
|
2280
|
+
ownerId: r.ownerId,
|
|
2281
|
+
credentialId: r.credentialId,
|
|
2282
|
+
source: r.source,
|
|
2283
|
+
...(Object.hasOwn(r, 'error') && isString(r.error) ? { error: r.error } : {}),
|
|
2284
|
+
},
|
|
2285
|
+
fileRecord: parseOwnerIdentityRecordData(v.fileRecord),
|
|
2286
|
+
governance,
|
|
2287
|
+
};
|
|
2288
|
+
if (Object.hasOwn(v, 'fileError') && isString(v.fileError))
|
|
2289
|
+
out.fileError = v.fileError;
|
|
2290
|
+
return out;
|
|
2291
|
+
}
|
|
2292
|
+
export function validateOwnerIdentityRegister(v) {
|
|
2293
|
+
if (!isObject(v))
|
|
2294
|
+
return null;
|
|
2295
|
+
if (!Object.hasOwn(v, 'source') || v.source !== 'file')
|
|
2296
|
+
return null;
|
|
2297
|
+
if (!Object.hasOwn(v, 'record') || !isObject(v.record))
|
|
2298
|
+
return null;
|
|
2299
|
+
const rec = v.record;
|
|
2300
|
+
if (!Object.hasOwn(rec, 'schemaVersion') || !isNumber(rec.schemaVersion))
|
|
2301
|
+
return null;
|
|
2302
|
+
if (!Object.hasOwn(rec, 'ownerId') || !isString(rec.ownerId))
|
|
2303
|
+
return null;
|
|
2304
|
+
if (!Object.hasOwn(rec, 'credentialId') || !isString(rec.credentialId))
|
|
2305
|
+
return null;
|
|
2306
|
+
if (!Object.hasOwn(rec, 'registeredAt') || !isString(rec.registeredAt))
|
|
2307
|
+
return null;
|
|
2308
|
+
const governance = parseOwnerGovernanceReadiness(v.governance);
|
|
2309
|
+
if (governance === null)
|
|
2310
|
+
return null;
|
|
2311
|
+
return {
|
|
2312
|
+
source: 'file',
|
|
2313
|
+
record: { schemaVersion: rec.schemaVersion, ownerId: rec.ownerId, credentialId: rec.credentialId, registeredAt: rec.registeredAt },
|
|
2314
|
+
governance,
|
|
2315
|
+
};
|
|
2316
|
+
}
|
|
2317
|
+
export function validateOwnerIdentityUnregister(v) {
|
|
2318
|
+
if (!isObject(v))
|
|
2319
|
+
return null;
|
|
2320
|
+
if (!Object.hasOwn(v, 'ok') || !isBoolean(v.ok) || v.ok !== true)
|
|
2321
|
+
return null;
|
|
2322
|
+
if (!Object.hasOwn(v, 'source') || v.source !== 'none')
|
|
2323
|
+
return null;
|
|
2324
|
+
const governance = parseOwnerGovernanceReadiness(v.governance);
|
|
2325
|
+
if (governance === null)
|
|
2326
|
+
return null;
|
|
2327
|
+
return { ok: true, source: 'none', governance };
|
|
2328
|
+
}
|
|
@@ -457,6 +457,9 @@
|
|
|
457
457
|
.mr-2 {
|
|
458
458
|
margin-right: calc(var(--spacing) * 2);
|
|
459
459
|
}
|
|
460
|
+
.mr-4 {
|
|
461
|
+
margin-right: calc(var(--spacing) * 4);
|
|
462
|
+
}
|
|
460
463
|
.mb-0\.5 {
|
|
461
464
|
margin-bottom: calc(var(--spacing) * 0.5);
|
|
462
465
|
}
|
|
@@ -1779,6 +1782,9 @@
|
|
|
1779
1782
|
.pt-0 {
|
|
1780
1783
|
padding-top: 0px;
|
|
1781
1784
|
}
|
|
1785
|
+
.pt-0\.5 {
|
|
1786
|
+
padding-top: calc(var(--spacing) * 0.5);
|
|
1787
|
+
}
|
|
1782
1788
|
.pt-1 {
|
|
1783
1789
|
padding-top: var(--spacing);
|
|
1784
1790
|
}
|