@wildo-ai/platform-config-lib 1.1.9 → 1.1.11

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.
Files changed (188) hide show
  1. package/dist/esm/_unimplemented/unimplemented-field-warning.d.ts +1 -1
  2. package/dist/esm/_unimplemented/unimplemented-field-warning.js +1 -1
  3. package/dist/esm/_unimplemented/unimplemented-field-warning.js.map +1 -1
  4. package/dist/esm/blueprint/anchored-region.d.ts +83 -0
  5. package/dist/esm/blueprint/anchored-region.d.ts.map +1 -0
  6. package/dist/esm/blueprint/anchored-region.js +263 -0
  7. package/dist/esm/blueprint/anchored-region.js.map +1 -0
  8. package/dist/esm/blueprint/blueprint.schemas.d.ts +689 -0
  9. package/dist/esm/blueprint/blueprint.schemas.d.ts.map +1 -0
  10. package/dist/esm/blueprint/blueprint.schemas.js +638 -0
  11. package/dist/esm/blueprint/blueprint.schemas.js.map +1 -0
  12. package/dist/esm/bootstrap/bootstrap.contracts.d.ts +13 -1
  13. package/dist/esm/bootstrap/bootstrap.contracts.d.ts.map +1 -1
  14. package/dist/esm/bootstrap/bootstrap.contracts.js +6 -0
  15. package/dist/esm/bootstrap/bootstrap.contracts.js.map +1 -1
  16. package/dist/esm/bootstrap/bootstrap.schemas.d.ts +21 -3
  17. package/dist/esm/bootstrap/bootstrap.schemas.d.ts.map +1 -1
  18. package/dist/esm/bootstrap/bootstrap.schemas.js +14 -3
  19. package/dist/esm/bootstrap/bootstrap.schemas.js.map +1 -1
  20. package/dist/esm/bootstrap/platform-runtime-env.contracts.d.ts +121 -0
  21. package/dist/esm/bootstrap/platform-runtime-env.contracts.d.ts.map +1 -1
  22. package/dist/esm/bootstrap/platform-runtime-env.contracts.js +129 -0
  23. package/dist/esm/bootstrap/platform-runtime-env.contracts.js.map +1 -1
  24. package/dist/esm/bootstrap/runtime-response-integrity.d.ts +249 -0
  25. package/dist/esm/bootstrap/runtime-response-integrity.d.ts.map +1 -0
  26. package/dist/esm/bootstrap/runtime-response-integrity.js +353 -0
  27. package/dist/esm/bootstrap/runtime-response-integrity.js.map +1 -0
  28. package/dist/esm/bootstrap/runtime-secret-env.contracts.d.ts +32 -0
  29. package/dist/esm/bootstrap/runtime-secret-env.contracts.d.ts.map +1 -0
  30. package/dist/esm/bootstrap/runtime-secret-env.contracts.js +43 -0
  31. package/dist/esm/bootstrap/runtime-secret-env.contracts.js.map +1 -0
  32. package/dist/esm/canonical-json/rfc8785-canonical-json.d.ts +51 -0
  33. package/dist/esm/canonical-json/rfc8785-canonical-json.d.ts.map +1 -0
  34. package/dist/esm/canonical-json/rfc8785-canonical-json.js +231 -0
  35. package/dist/esm/canonical-json/rfc8785-canonical-json.js.map +1 -0
  36. package/dist/esm/index.d.ts +15 -0
  37. package/dist/esm/index.d.ts.map +1 -1
  38. package/dist/esm/index.js +15 -0
  39. package/dist/esm/index.js.map +1 -1
  40. package/dist/esm/key-management/approval-seal-verifier.d.ts +216 -0
  41. package/dist/esm/key-management/approval-seal-verifier.d.ts.map +1 -0
  42. package/dist/esm/key-management/approval-seal-verifier.js +233 -0
  43. package/dist/esm/key-management/approval-seal-verifier.js.map +1 -0
  44. package/dist/esm/key-management/approval-seal.contracts.d.ts +131 -0
  45. package/dist/esm/key-management/approval-seal.contracts.d.ts.map +1 -0
  46. package/dist/esm/key-management/approval-seal.contracts.js +115 -0
  47. package/dist/esm/key-management/approval-seal.contracts.js.map +1 -0
  48. package/dist/esm/key-management/data-key.contracts.d.ts +108 -0
  49. package/dist/esm/key-management/data-key.contracts.d.ts.map +1 -0
  50. package/dist/esm/key-management/data-key.contracts.js +54 -0
  51. package/dist/esm/key-management/data-key.contracts.js.map +1 -0
  52. package/dist/esm/key-management/es256-jws.d.ts +60 -0
  53. package/dist/esm/key-management/es256-jws.d.ts.map +1 -0
  54. package/dist/esm/key-management/es256-jws.js +135 -0
  55. package/dist/esm/key-management/es256-jws.js.map +1 -0
  56. package/dist/esm/key-management/key-provider.spi.d.ts +151 -0
  57. package/dist/esm/key-management/key-provider.spi.d.ts.map +1 -0
  58. package/dist/esm/key-management/key-provider.spi.js +38 -0
  59. package/dist/esm/key-management/key-provider.spi.js.map +1 -0
  60. package/dist/esm/key-management/keyring-rotation.contracts.d.ts +93 -0
  61. package/dist/esm/key-management/keyring-rotation.contracts.d.ts.map +1 -0
  62. package/dist/esm/key-management/keyring-rotation.contracts.js +101 -0
  63. package/dist/esm/key-management/keyring-rotation.contracts.js.map +1 -0
  64. package/dist/esm/key-management/keyring-status.contracts.d.ts +66 -0
  65. package/dist/esm/key-management/keyring-status.contracts.d.ts.map +1 -0
  66. package/dist/esm/key-management/keyring-status.contracts.js +45 -0
  67. package/dist/esm/key-management/keyring-status.contracts.js.map +1 -0
  68. package/dist/esm/key-management/signature-request.contracts.d.ts +95 -0
  69. package/dist/esm/key-management/signature-request.contracts.d.ts.map +1 -0
  70. package/dist/esm/key-management/signature-request.contracts.js +96 -0
  71. package/dist/esm/key-management/signature-request.contracts.js.map +1 -0
  72. package/dist/esm/key-management/signing-log-export.contracts.d.ts +216 -0
  73. package/dist/esm/key-management/signing-log-export.contracts.d.ts.map +1 -0
  74. package/dist/esm/key-management/signing-log-export.contracts.js +268 -0
  75. package/dist/esm/key-management/signing-log-export.contracts.js.map +1 -0
  76. package/dist/esm/key-management/vault-custody.contracts.d.ts +55 -0
  77. package/dist/esm/key-management/vault-custody.contracts.d.ts.map +1 -0
  78. package/dist/esm/key-management/vault-custody.contracts.js +88 -0
  79. package/dist/esm/key-management/vault-custody.contracts.js.map +1 -0
  80. package/dist/esm/lockfile/lockfile-io.d.ts +7 -9
  81. package/dist/esm/lockfile/lockfile-io.d.ts.map +1 -1
  82. package/dist/esm/lockfile/lockfile-io.js +23 -22
  83. package/dist/esm/lockfile/lockfile-io.js.map +1 -1
  84. package/dist/esm/lockfile/materialize-infra-section.d.ts +17 -14
  85. package/dist/esm/lockfile/materialize-infra-section.d.ts.map +1 -1
  86. package/dist/esm/lockfile/materialize-infra-section.js +9 -9
  87. package/dist/esm/lockfile/materialize-infra-section.js.map +1 -1
  88. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.d.ts +26 -2
  89. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.d.ts.map +1 -1
  90. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.js +27 -2
  91. package/dist/esm/lockfile/wildo-saas-lock.shared.schemas.js.map +1 -1
  92. package/dist/esm/project-config/application-public-pricing-catalog.loader.d.ts.map +1 -1
  93. package/dist/esm/project-config/application-public-pricing-catalog.loader.js +9 -2
  94. package/dist/esm/project-config/application-public-pricing-catalog.loader.js.map +1 -1
  95. package/dist/esm/project-config/application-served-public-documents.loader.d.ts +26 -0
  96. package/dist/esm/project-config/application-served-public-documents.loader.d.ts.map +1 -0
  97. package/dist/esm/project-config/application-served-public-documents.loader.js +78 -0
  98. package/dist/esm/project-config/application-served-public-documents.loader.js.map +1 -0
  99. package/dist/esm/project-config/define-infra-env-config.d.ts +236 -15
  100. package/dist/esm/project-config/define-infra-env-config.d.ts.map +1 -1
  101. package/dist/esm/project-config/define-infra-env-config.js +104 -91
  102. package/dist/esm/project-config/define-infra-env-config.js.map +1 -1
  103. package/dist/esm/project-config/define-saas-config.d.ts +133 -3
  104. package/dist/esm/project-config/define-saas-config.d.ts.map +1 -1
  105. package/dist/esm/project-config/define-saas-config.js +170 -19
  106. package/dist/esm/project-config/define-saas-config.js.map +1 -1
  107. package/dist/esm/project-config/hosted-infra-env-config.d.ts.map +1 -1
  108. package/dist/esm/project-config/hosted-infra-env-config.js +3 -0
  109. package/dist/esm/project-config/hosted-infra-env-config.js.map +1 -1
  110. package/dist/esm/project-config/index.d.ts +3 -0
  111. package/dist/esm/project-config/index.d.ts.map +1 -1
  112. package/dist/esm/project-config/index.js +3 -0
  113. package/dist/esm/project-config/index.js.map +1 -1
  114. package/dist/esm/project-config/npm-version-range.d.ts.map +1 -1
  115. package/dist/esm/project-config/npm-version-range.js +39 -16
  116. package/dist/esm/project-config/npm-version-range.js.map +1 -1
  117. package/dist/esm/project-config/owning-package-tsconfig.d.ts +15 -0
  118. package/dist/esm/project-config/owning-package-tsconfig.d.ts.map +1 -0
  119. package/dist/esm/project-config/owning-package-tsconfig.js +29 -0
  120. package/dist/esm/project-config/owning-package-tsconfig.js.map +1 -0
  121. package/dist/esm/project-config/provider-companion-discovery.d.ts +4 -4
  122. package/dist/esm/project-config/provider-companion-discovery.d.ts.map +1 -1
  123. package/dist/esm/project-config/provider-companion-discovery.js +13 -9
  124. package/dist/esm/project-config/provider-companion-discovery.js.map +1 -1
  125. package/dist/esm/project-config/provider-runtime-artifacts.d.ts +32 -3
  126. package/dist/esm/project-config/provider-runtime-artifacts.d.ts.map +1 -1
  127. package/dist/esm/project-config/provider-runtime-artifacts.js +67 -13
  128. package/dist/esm/project-config/provider-runtime-artifacts.js.map +1 -1
  129. package/dist/esm/project-config/shared/csp-defaults.d.ts +4 -5
  130. package/dist/esm/project-config/shared/csp-defaults.d.ts.map +1 -1
  131. package/dist/esm/project-config/shared/csp-defaults.js +4 -5
  132. package/dist/esm/project-config/shared/csp-defaults.js.map +1 -1
  133. package/dist/esm/project-config/shared/csp.schemas.d.ts +1 -2
  134. package/dist/esm/project-config/shared/csp.schemas.d.ts.map +1 -1
  135. package/dist/esm/project-config/shared/csp.schemas.js +1 -2
  136. package/dist/esm/project-config/shared/csp.schemas.js.map +1 -1
  137. package/dist/esm/project-config/shared/environment.schemas.d.ts +6 -0
  138. package/dist/esm/project-config/shared/environment.schemas.d.ts.map +1 -1
  139. package/dist/esm/project-config/shared/environment.schemas.js +8 -1
  140. package/dist/esm/project-config/shared/environment.schemas.js.map +1 -1
  141. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.d.ts +1 -0
  142. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.d.ts.map +1 -1
  143. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.js +3 -0
  144. package/dist/esm/project-config/shared/infrastructure-defaults.schemas.js.map +1 -1
  145. package/dist/esm/project-config/shared/minion-resource-access.validation.d.ts +4 -0
  146. package/dist/esm/project-config/shared/minion-resource-access.validation.d.ts.map +1 -1
  147. package/dist/esm/project-config/shared/minion-resource-access.validation.js +6 -2
  148. package/dist/esm/project-config/shared/minion-resource-access.validation.js.map +1 -1
  149. package/dist/esm/project-config/shared/platform-key-management.schemas.d.ts +250 -0
  150. package/dist/esm/project-config/shared/platform-key-management.schemas.d.ts.map +1 -0
  151. package/dist/esm/project-config/shared/platform-key-management.schemas.js +194 -0
  152. package/dist/esm/project-config/shared/platform-key-management.schemas.js.map +1 -0
  153. package/dist/esm/registry/index.d.ts +1 -0
  154. package/dist/esm/registry/index.d.ts.map +1 -1
  155. package/dist/esm/registry/index.js +1 -0
  156. package/dist/esm/registry/index.js.map +1 -1
  157. package/dist/esm/registry/local-checkout-source.d.ts +22 -2
  158. package/dist/esm/registry/local-checkout-source.d.ts.map +1 -1
  159. package/dist/esm/registry/local-checkout-source.js +66 -3
  160. package/dist/esm/registry/local-checkout-source.js.map +1 -1
  161. package/dist/esm/registry/lockfile-modules-section.schemas.d.ts +10 -0
  162. package/dist/esm/registry/lockfile-modules-section.schemas.d.ts.map +1 -1
  163. package/dist/esm/registry/module-artifact.schemas.d.ts +23 -0
  164. package/dist/esm/registry/module-artifact.schemas.d.ts.map +1 -1
  165. package/dist/esm/registry/module-manifest.schemas.d.ts +336 -18
  166. package/dist/esm/registry/module-manifest.schemas.d.ts.map +1 -1
  167. package/dist/esm/registry/module-manifest.schemas.js +245 -19
  168. package/dist/esm/registry/module-manifest.schemas.js.map +1 -1
  169. package/dist/esm/registry/module-search.schemas.d.ts +2 -0
  170. package/dist/esm/registry/module-search.schemas.d.ts.map +1 -1
  171. package/dist/esm/registry/module-search.schemas.js +14 -1
  172. package/dist/esm/registry/module-search.schemas.js.map +1 -1
  173. package/dist/esm/registry/registry-errors.d.ts +22 -2
  174. package/dist/esm/registry/registry-errors.d.ts.map +1 -1
  175. package/dist/esm/registry/registry-errors.js +28 -2
  176. package/dist/esm/registry/registry-errors.js.map +1 -1
  177. package/dist/esm/registry/registry-section-schemas.constants.d.ts +5 -0
  178. package/dist/esm/registry/registry-section-schemas.constants.d.ts.map +1 -1
  179. package/dist/esm/registry/registry-url-resolution.d.ts +72 -0
  180. package/dist/esm/registry/registry-url-resolution.d.ts.map +1 -0
  181. package/dist/esm/registry/registry-url-resolution.js +157 -0
  182. package/dist/esm/registry/registry-url-resolution.js.map +1 -0
  183. package/dist/esm/schemas/framework-secrets.schemas.d.ts +55 -0
  184. package/dist/esm/schemas/framework-secrets.schemas.d.ts.map +1 -1
  185. package/dist/esm/schemas/framework-secrets.schemas.js +53 -0
  186. package/dist/esm/schemas/framework-secrets.schemas.js.map +1 -1
  187. package/dist/tsconfig.build.tsbuildinfo +1 -1
  188. package/package.json +7 -7
@@ -1 +1 @@
1
- {"version":3,"file":"hosted-infra-env-config.js","sourceRoot":"","sources":["../../../../src/project-config/hosted-infra-env-config.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,uCAAuC,EACvC,sBAAsB,EACtB,yBAAyB,GAK1B,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,kBAAkB,EAAiC,MAAM,mCAAmC,CAAC;AACtG,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA8B,CAAC;AAiBtE;;;GAGG;AACH,MAAM,OAAO,mCAAoC,SAAQ,KAAK;IACnD,MAAM,CAAoB;IAEnC,YAAY,gBAAwB,EAAE,cAAsB,EAAE,MAAyB;QACrF,KAAK,CAAC;YACJ,oDAAoD,gBAAgB,oCAAoC,cAAc,GAAG;YACzH,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,OAAO,KAAK,EAAE,CAAC;SACzC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;QACd,IAAI,CAAC,IAAI,GAAG,qCAAqC,CAAC;QAClD,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;CACF;AAED;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AAG,MAAM,CAAC,UAAU,CAAC;IACnC,IAAI,QAAQ,KAAK,SAAS;QAAE,OAAO,SAAS,CAAC;IAE7C,IAAI,IAAI,CAAC,OAAO,KAAK,sBAAsB,CAAC,UAAU,EAAE,CAAC;QACvD,MAAM,aAAa,GAAG,IAAI,CAAC,UAAU,EAAE,OAAO,KAAK,sBAAsB,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC;QAC7H,OAAO;YACL,OAAO,EAAE,sBAAsB,CAAC,UAAU;YAC1C,MAAM,EAAE,QAAQ,CAAC,MAAM;YACvB,GAAG,CAAC,QAAQ,CAAC,gBAAgB,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,QAAQ,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;YACnG,GAAG,CAAC,aAAa,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,aAAa,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SACrE,CAAC;IACJ,CAAC;IAED,OAAO;QACL,OAAO,EAAE,sBAAsB,CAAC,cAAc;QAC9C,MAAM,EAAE,QAAQ,CAAC,MAAM;QACvB,GAAG,CAAC,QAAQ,CAAC,gBAAgB,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,QAAQ,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACpG,CAAC;AACJ,CAAC","sourcesContent":["import {\n BACKING_SERVICE_APPLICATION_NAME_FIELDS,\n isHostedInfraEnvConfig,\n WildoInfraEnvConfigSchema,\n type WildoAuthoredInfraEnvConfig,\n type WildoHostedInfraEnvConfig,\n type WildoInfraEnvConfig,\n type WildoInfraEnvConfigInput,\n} from './define-infra-env-config';\nimport { BackingServiceKind, type BackingServicesEnvConfig } from './shared/backing-services.schemas';\nimport { WildoDeploymentRuntime } from './shared/environment.schemas';\n\n/**\n * Everything {@link resolveHostedInfraEnvConfig} needs, with the file paths kept so every refusal can name\n * BOTH descriptors — the one being resolved and the one it depends on.\n */\nexport interface HostedInfraEnvConfigResolutionInput {\n hosted: WildoHostedInfraEnvConfig;\n hostedConfigPath: string;\n /** The host's descriptor as evaluated — refused if it is itself hosted. */\n host: WildoAuthoredInfraEnvConfig;\n /** Absolute. */\n hostApplicationRoot: string;\n /** Absolute. */\n hostConfigPath: string;\n}\n\n/**\n * A hosted descriptor that cannot be resolved against its host. Carries every issue at once: an author\n * fixing a descriptor should not have to rediscover the next problem one load at a time.\n */\nexport class HostedInfraEnvConfigResolutionError extends Error {\n readonly issues: readonly string[];\n\n constructor(hostedConfigPath: string, hostConfigPath: string, issues: readonly string[]) {\n super([\n `Cannot resolve the hosted environment descriptor ${hostedConfigPath} against its infrastructure host ${hostConfigPath}:`,\n ...issues.map((issue) => ` - ${issue}`),\n ].join('\\n'));\n this.name = 'HostedInfraEnvConfigResolutionError';\n this.issues = issues;\n }\n}\n\n/**\n * Turn a hosted descriptor into the environment it actually runs in: the host's platform, the\n * application's own settings.\n *\n * A PURE function of the two evaluated descriptors — no filesystem — so the whole merge contract is\n * testable without a checkout. `loadInfraEnvConfig` does the reading and calls this.\n *\n * ## What comes from where\n *\n * Decided per member by `INFRA_ENV_FIELD_OWNERSHIP`:\n * - HOST members (runtime, location, runtime environment, platform database, remote provider, platform\n * storage) are the host's, verbatim;\n * - APPLICATION members are the hosted descriptor's, verbatim;\n * - `backingServices`: the kinds are the ones the HOSTED application lists (its needs), each of which the\n * host must declare; each entry is the host's server with the host's own name removed, overlaid with the\n * application's name;\n * - `kubernetes`: the host's namespace and ingress class, the application's replica counts;\n * - `deployment`: the host's runtime, the application's branch and tagging. The image registry is the host's\n * `remoteProvider.registryEndpoint` like everything else about where images live (#1165).\n *\n * ## Why the kinds are the application's, not the host's\n *\n * Rejected: handing a hosted application every store its host declares. That would give Wonder CRM a\n * MongoDB address it never asked for, named by the shared `'wildo_app'` fallback — the exact collision\n * the name rule exists to prevent. Declaring a kind stays how an application says it needs a store; what\n * changes is that it cannot say where that store is.\n *\n * ## The merged result is re-validated\n *\n * The merge is parsed through the STANDALONE schema, so every cross-field rule that holds for an owning\n * environment (an application on PostgreSQL needs `backingServices.postgresql`; a local environment cannot\n * author `cdn`; …) holds for the effective hosted one. Validating the hosted descriptor alone could not do\n * that: it does not know whether its host is local or remote.\n */\nexport function resolveHostedInfraEnvConfig(input: HostedInfraEnvConfigResolutionInput): WildoInfraEnvConfig {\n const { hosted, host, hostedConfigPath, hostConfigPath } = input;\n const fail = (issues: readonly string[]): never => {\n throw new HostedInfraEnvConfigResolutionError(hostedConfigPath, hostConfigPath, issues);\n };\n\n if (isHostedInfraEnvConfig(host)) {\n fail([\n `the host is itself hosted (its infrastructureHost is '${host.infrastructureHost.applicationRoot}'). An infrastructure `\n + 'host must OWN its infrastructure: point infrastructureHost at the application that does.',\n ]);\n }\n const owningHost = host as WildoInfraEnvConfig;\n const issues: string[] = [];\n\n if (owningHost.environment !== hosted.environment) {\n issues.push(`the host describes environment '${owningHost.environment}', this descriptor '${hosted.environment}'. A hosted `\n + 'application shares its host\\'s platform for ONE environment at a time, so both must describe the same one.');\n }\n\n const backingServices = resolveBackingServices(hosted, owningHost, hostConfigPath, issues);\n const kubernetes = resolveKubernetes(hosted, owningHost, issues);\n const deployment = resolveDeployment(hosted, owningHost, issues);\n\n if (issues.length > 0) fail(issues);\n\n const merged: WildoInfraEnvConfigInput = {\n version: hosted.version,\n environment: hosted.environment,\n locationType: owningHost.locationType,\n runtimeEnvironment: owningHost.runtimeEnvironment,\n runtime: owningHost.runtime,\n database: owningHost.database,\n applicationDatabase: hosted.applicationDatabase,\n publicDomain: hosted.publicDomain,\n serviceHosts: hosted.serviceHosts,\n kubernetes,\n remoteProvider: owningHost.remoteProvider,\n deployment,\n backingServices,\n logging: hosted.logging,\n observability: hosted.observability,\n providerSelection: hosted.providerSelection,\n providerConfigurations: hosted.providerConfigurations,\n systemsOfRecord: hosted.systemsOfRecord,\n documentationSite: hosted.documentationSite,\n applicationCreationVerification: hosted.applicationCreationVerification,\n serviceAuth: hosted.serviceAuth,\n csp: hosted.csp,\n cdn: hosted.cdn,\n platformStorage: owningHost.platformStorage,\n devCompanion: hosted.devCompanion,\n infrastructureHost: {\n applicationRoot: input.hostApplicationRoot,\n infraConfigPath: hostConfigPath,\n },\n };\n\n const parsed = WildoInfraEnvConfigSchema.safeParse(merged);\n if (!parsed.success) {\n fail(parsed.error.issues.map((issue) => {\n const path = issue.path.length > 0 ? `${issue.path.join('.')}: ` : '';\n return `the effective environment (host platform + this application) is invalid — ${path}${issue.message}`;\n }));\n }\n return (parsed as { data: WildoInfraEnvConfig }).data;\n}\n\nfunction resolveBackingServices(\n hosted: WildoHostedInfraEnvConfig,\n host: WildoInfraEnvConfig,\n hostConfigPath: string,\n issues: string[],\n): BackingServicesEnvConfig {\n const resolved: Record<string, Record<string, unknown>> = {};\n for (const kind of Object.values(BackingServiceKind)) {\n const hostedEntry = hosted.backingServices?.[kind] as Record<string, unknown> | undefined;\n if (hostedEntry === undefined) continue;\n\n const hostEntry = host.backingServices[kind] as Record<string, unknown> | undefined;\n if (hostEntry === undefined) {\n issues.push(`this application uses backingServices.${kind}, which its host does not declare. Every backing service a `\n + `hosted application needs is declared by its host: add backingServices.${kind} to ${hostConfigPath}.`);\n continue;\n }\n\n const nameField = BACKING_SERVICE_APPLICATION_NAME_FIELDS[kind];\n const server = { ...hostEntry };\n if (nameField !== null) delete server[nameField.field];\n\n if (nameField?.mustDifferFromHost) {\n const hostName = hostEntry[nameField.field];\n if (hostName === undefined) {\n /*\n * An unnamed host slice uses the framework's SHARED fallback (`'wildo_app'`, the default vhost `/`, the\n * fixed bucket). Those constants live with the env generators, not here, so the collision cannot be\n * decided by value — and refusing is the only answer that stays right when a fallback changes. A host\n * whose store is shared names its own slice.\n */\n issues.push(`the host declares backingServices.${kind} without a ${nameField.field}, so it uses the framework's `\n + `shared fallback name — which an application on its platform could collide with without either naming it. `\n + `A host whose ${kind} is shared must name its own ${nameField.field}: add it to ${hostConfigPath}.`);\n } else if (hostName === hostedEntry[nameField.field]) {\n issues.push(`backingServices.${kind}.${nameField.field} is '${String(hostedEntry[nameField.field])}', the same as the `\n + `host's. Both applications would read and write one ${kind} ${nameField.field}: name this application's own.`);\n }\n }\n\n resolved[kind] = { ...server, ...hostedEntry };\n }\n return resolved as BackingServicesEnvConfig;\n}\n\nfunction resolveKubernetes(\n hosted: WildoHostedInfraEnvConfig,\n host: WildoInfraEnvConfig,\n issues: string[],\n): WildoInfraEnvConfigInput['kubernetes'] {\n const services = hosted.kubernetes?.services;\n if (host.kubernetes === undefined) {\n if (services !== undefined) {\n issues.push('kubernetes.services sets replica counts, but the host declares no kubernetes block: there is no cluster '\n + 'for them to apply to. Remove them, or run the host on Kubernetes.');\n }\n return undefined;\n }\n return {\n namespace: host.kubernetes.namespace,\n ...(host.kubernetes.ingressClass !== undefined ? { ingressClass: host.kubernetes.ingressClass } : {}),\n ...(services !== undefined ? { services } : {}),\n };\n}\n\nfunction resolveDeployment(\n hosted: WildoHostedInfraEnvConfig,\n host: WildoInfraEnvConfig,\n issues: string[],\n): WildoInfraEnvConfigInput['deployment'] {\n const authored = hosted.deployment;\n if (authored === undefined) return undefined;\n\n if (host.runtime === WildoDeploymentRuntime.KUBERNETES) {\n const hostNamespace = host.deployment?.runtime === WildoDeploymentRuntime.KUBERNETES ? host.deployment.namespace : undefined;\n return {\n runtime: WildoDeploymentRuntime.KUBERNETES,\n branch: authored.branch,\n ...(authored.imageTagStrategy !== undefined ? { imageTagStrategy: authored.imageTagStrategy } : {}),\n ...(hostNamespace !== undefined ? { namespace: hostNamespace } : {}),\n };\n }\n\n return {\n runtime: WildoDeploymentRuntime.DOCKER_COMPOSE,\n branch: authored.branch,\n ...(authored.imageTagStrategy !== undefined ? { imageTagStrategy: authored.imageTagStrategy } : {}),\n };\n}\n"]}
1
+ {"version":3,"file":"hosted-infra-env-config.js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BAAgB,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,QAAQ,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;YACnG,GAAG,CAAC,aAAa,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,aAAa,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SACrE,CAAC;IACJ,CAAC;IAED,OAAO;QACL,OAAO,EAAE,sBAAsB,CAAC,cAAc;QAC9C,MAAM,EAAE,QAAQ,CAAC,MAAM;QACvB,GAAG,CAAC,QAAQ,CAAC,gBAAgB,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,QAAQ,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACpG,CAAC;AACJ,CAAC","sourcesContent":["import {\n BACKING_SERVICE_APPLICATION_NAME_FIELDS,\n isHostedInfraEnvConfig,\n WildoInfraEnvConfigSchema,\n type WildoAuthoredInfraEnvConfig,\n type WildoHostedInfraEnvConfig,\n type WildoInfraEnvConfig,\n type WildoInfraEnvConfigInput,\n} from './define-infra-env-config';\nimport { BackingServiceKind, type BackingServicesEnvConfig } from './shared/backing-services.schemas';\nimport { WildoDeploymentRuntime } from './shared/environment.schemas';\n\n/**\n * Everything {@link resolveHostedInfraEnvConfig} needs, with the file paths kept so every refusal can name\n * BOTH descriptors — the one being resolved and the one it depends on.\n */\nexport interface HostedInfraEnvConfigResolutionInput {\n hosted: WildoHostedInfraEnvConfig;\n hostedConfigPath: string;\n /** The host's descriptor as evaluated — refused if it is itself hosted. */\n host: WildoAuthoredInfraEnvConfig;\n /** Absolute. */\n hostApplicationRoot: string;\n /** Absolute. */\n hostConfigPath: string;\n}\n\n/**\n * A hosted descriptor that cannot be resolved against its host. Carries every issue at once: an author\n * fixing a descriptor should not have to rediscover the next problem one load at a time.\n */\nexport class HostedInfraEnvConfigResolutionError extends Error {\n readonly issues: readonly string[];\n\n constructor(hostedConfigPath: string, hostConfigPath: string, issues: readonly string[]) {\n super([\n `Cannot resolve the hosted environment descriptor ${hostedConfigPath} against its infrastructure host ${hostConfigPath}:`,\n ...issues.map((issue) => ` - ${issue}`),\n ].join('\\n'));\n this.name = 'HostedInfraEnvConfigResolutionError';\n this.issues = issues;\n }\n}\n\n/**\n * Turn a hosted descriptor into the environment it actually runs in: the host's platform, the\n * application's own settings.\n *\n * A PURE function of the two evaluated descriptors — no filesystem — so the whole merge contract is\n * testable without a checkout. `loadInfraEnvConfig` does the reading and calls this.\n *\n * ## What comes from where\n *\n * Decided per member by `INFRA_ENV_FIELD_OWNERSHIP`:\n * - HOST members (runtime, location, runtime environment, platform database, remote provider, platform\n * storage) are the host's, verbatim;\n * - APPLICATION members are the hosted descriptor's, verbatim;\n * - `backingServices`: the kinds are the ones the HOSTED application lists (its needs), each of which the\n * host must declare; each entry is the host's server with the host's own name removed, overlaid with the\n * application's name;\n * - `kubernetes`: the host's namespace and ingress class, the application's replica counts;\n * - `deployment`: the host's runtime, the application's branch and tagging. The image registry is the host's\n * `remoteProvider.registryEndpoint` like everything else about where images live (#1165).\n *\n * ## Why the kinds are the application's, not the host's\n *\n * Rejected: handing a hosted application every store its host declares. That would give Wonder CRM a\n * MongoDB address it never asked for, named by the shared `'wildo_app'` fallback — the exact collision\n * the name rule exists to prevent. Declaring a kind stays how an application says it needs a store; what\n * changes is that it cannot say where that store is.\n *\n * ## The merged result is re-validated\n *\n * The merge is parsed through the STANDALONE schema, so every cross-field rule that holds for an owning\n * environment (an application on PostgreSQL needs `backingServices.postgresql`; a local environment cannot\n * author `cdn`; …) holds for the effective hosted one. Validating the hosted descriptor alone could not do\n * that: it does not know whether its host is local or remote.\n */\nexport function resolveHostedInfraEnvConfig(input: HostedInfraEnvConfigResolutionInput): WildoInfraEnvConfig {\n const { hosted, host, hostedConfigPath, hostConfigPath } = input;\n const fail = (issues: readonly string[]): never => {\n throw new HostedInfraEnvConfigResolutionError(hostedConfigPath, hostConfigPath, issues);\n };\n\n if (isHostedInfraEnvConfig(host)) {\n fail([\n `the host is itself hosted (its infrastructureHost is '${host.infrastructureHost.applicationRoot}'). An infrastructure `\n + 'host must OWN its infrastructure: point infrastructureHost at the application that does.',\n ]);\n }\n const owningHost = host as WildoInfraEnvConfig;\n const issues: string[] = [];\n\n if (owningHost.environment !== hosted.environment) {\n issues.push(`the host describes environment '${owningHost.environment}', this descriptor '${hosted.environment}'. A hosted `\n + 'application shares its host\\'s platform for ONE environment at a time, so both must describe the same one.');\n }\n\n const backingServices = resolveBackingServices(hosted, owningHost, hostConfigPath, issues);\n const kubernetes = resolveKubernetes(hosted, owningHost, issues);\n const deployment = resolveDeployment(hosted, owningHost, issues);\n\n if (issues.length > 0) fail(issues);\n\n const merged: WildoInfraEnvConfigInput = {\n version: hosted.version,\n environment: hosted.environment,\n locationType: owningHost.locationType,\n runtimeEnvironment: owningHost.runtimeEnvironment,\n runtime: owningHost.runtime,\n database: owningHost.database,\n applicationDatabase: hosted.applicationDatabase,\n publicDomain: hosted.publicDomain,\n serviceHosts: hosted.serviceHosts,\n kubernetes,\n remoteProvider: owningHost.remoteProvider,\n deployment,\n backingServices,\n logging: hosted.logging,\n observability: hosted.observability,\n providerSelection: hosted.providerSelection,\n providerConfigurations: hosted.providerConfigurations,\n email: hosted.email,\n ownershipDnsStandIn: hosted.ownershipDnsStandIn,\n systemsOfRecord: hosted.systemsOfRecord,\n documentationSite: hosted.documentationSite,\n applicationCreationVerification: hosted.applicationCreationVerification,\n serviceAuth: hosted.serviceAuth,\n csp: hosted.csp,\n cdn: hosted.cdn,\n platformStorage: owningHost.platformStorage,\n platformKeyManagement: owningHost.platformKeyManagement,\n devCompanion: hosted.devCompanion,\n infrastructureHost: {\n applicationRoot: input.hostApplicationRoot,\n infraConfigPath: hostConfigPath,\n },\n };\n\n const parsed = WildoInfraEnvConfigSchema.safeParse(merged);\n if (!parsed.success) {\n fail(parsed.error.issues.map((issue) => {\n const path = issue.path.length > 0 ? `${issue.path.join('.')}: ` : '';\n return `the effective environment (host platform + this application) is invalid — ${path}${issue.message}`;\n }));\n }\n return (parsed as { data: WildoInfraEnvConfig }).data;\n}\n\nfunction resolveBackingServices(\n hosted: WildoHostedInfraEnvConfig,\n host: WildoInfraEnvConfig,\n hostConfigPath: string,\n issues: string[],\n): BackingServicesEnvConfig {\n const resolved: Record<string, Record<string, unknown>> = {};\n for (const kind of Object.values(BackingServiceKind)) {\n const hostedEntry = hosted.backingServices?.[kind] as Record<string, unknown> | undefined;\n if (hostedEntry === undefined) continue;\n\n const hostEntry = host.backingServices[kind] as Record<string, unknown> | undefined;\n if (hostEntry === undefined) {\n issues.push(`this application uses backingServices.${kind}, which its host does not declare. Every backing service a `\n + `hosted application needs is declared by its host: add backingServices.${kind} to ${hostConfigPath}.`);\n continue;\n }\n\n const nameField = BACKING_SERVICE_APPLICATION_NAME_FIELDS[kind];\n const server = { ...hostEntry };\n if (nameField !== null) delete server[nameField.field];\n\n if (nameField?.mustDifferFromHost) {\n const hostName = hostEntry[nameField.field];\n if (hostName === undefined) {\n /*\n * An unnamed host slice uses the framework's SHARED fallback (`'wildo_app'`, the default vhost `/`, the\n * fixed bucket). Those constants live with the env generators, not here, so the collision cannot be\n * decided by value — and refusing is the only answer that stays right when a fallback changes. A host\n * whose store is shared names its own slice.\n */\n issues.push(`the host declares backingServices.${kind} without a ${nameField.field}, so it uses the framework's `\n + `shared fallback name — which an application on its platform could collide with without either naming it. `\n + `A host whose ${kind} is shared must name its own ${nameField.field}: add it to ${hostConfigPath}.`);\n } else if (hostName === hostedEntry[nameField.field]) {\n issues.push(`backingServices.${kind}.${nameField.field} is '${String(hostedEntry[nameField.field])}', the same as the `\n + `host's. Both applications would read and write one ${kind} ${nameField.field}: name this application's own.`);\n }\n }\n\n resolved[kind] = { ...server, ...hostedEntry };\n }\n return resolved as BackingServicesEnvConfig;\n}\n\nfunction resolveKubernetes(\n hosted: WildoHostedInfraEnvConfig,\n host: WildoInfraEnvConfig,\n issues: string[],\n): WildoInfraEnvConfigInput['kubernetes'] {\n const services = hosted.kubernetes?.services;\n if (host.kubernetes === undefined) {\n if (services !== undefined) {\n issues.push('kubernetes.services sets replica counts, but the host declares no kubernetes block: there is no cluster '\n + 'for them to apply to. Remove them, or run the host on Kubernetes.');\n }\n return undefined;\n }\n return {\n namespace: host.kubernetes.namespace,\n ...(host.kubernetes.ingressClass !== undefined ? { ingressClass: host.kubernetes.ingressClass } : {}),\n ...(services !== undefined ? { services } : {}),\n };\n}\n\nfunction resolveDeployment(\n hosted: WildoHostedInfraEnvConfig,\n host: WildoInfraEnvConfig,\n issues: string[],\n): WildoInfraEnvConfigInput['deployment'] {\n const authored = hosted.deployment;\n if (authored === undefined) return undefined;\n\n if (host.runtime === WildoDeploymentRuntime.KUBERNETES) {\n const hostNamespace = host.deployment?.runtime === WildoDeploymentRuntime.KUBERNETES ? host.deployment.namespace : undefined;\n return {\n runtime: WildoDeploymentRuntime.KUBERNETES,\n branch: authored.branch,\n ...(authored.imageTagStrategy !== undefined ? { imageTagStrategy: authored.imageTagStrategy } : {}),\n ...(hostNamespace !== undefined ? { namespace: hostNamespace } : {}),\n };\n }\n\n return {\n runtime: WildoDeploymentRuntime.DOCKER_COMPOSE,\n branch: authored.branch,\n ...(authored.imageTagStrategy !== undefined ? { imageTagStrategy: authored.imageTagStrategy } : {}),\n };\n}\n"]}
@@ -5,6 +5,7 @@ export * from './shared/application-creation-verification.schemas';
5
5
  export * from './shared/cdn.schemas';
6
6
  export * from './shared/systems-of-record-env.schemas';
7
7
  export * from './shared/platform-storage.schemas';
8
+ export * from './shared/platform-key-management.schemas';
8
9
  export * from './shared/csp.schemas';
9
10
  export * from './shared/csp-defaults';
10
11
  export * from './shared/csp-emit';
@@ -21,7 +22,9 @@ export * from './shared/k8s-utils';
21
22
  export * from './shared/env-example-defaults';
22
23
  export * from './loader';
23
24
  export * from './static-asset-import-noop';
25
+ export * from './owning-package-tsconfig';
24
26
  export * from './application-public-pricing-catalog.loader';
27
+ export * from './application-served-public-documents.loader';
25
28
  export * from './define-framework-config';
26
29
  export * from './define-infra-env-config';
27
30
  export * from './hosted-infra-env-config';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/project-config/index.ts"],"names":[],"mappings":"AAAA,cAAc,mCAAmC,CAAC;AAClD,cAAc,sCAAsC,CAAC;AACrD,cAAc,uBAAuB,CAAC;AACtC,cAAc,oDAAoD,CAAC;AACnE,cAAc,sBAAsB,CAAC;AACrC,cAAc,wCAAwC,CAAC;AACvD,cAAc,mCAAmC,CAAC;AAClD,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,kCAAkC,CAAC;AACjD,cAAc,oCAAoC,CAAC;AACnD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0CAA0C,CAAC;AACzD,cAAc,oBAAoB,CAAC;AACnC,cAAc,+BAA+B,CAAC;AAE9C,cAAc,UAAU,CAAC;AACzB,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6CAA6C,CAAC;AAE5D,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,4CAA4C,CAAC;AAC3D,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/project-config/index.ts"],"names":[],"mappings":"AAAA,cAAc,mCAAmC,CAAC;AAClD,cAAc,sCAAsC,CAAC;AACrD,cAAc,uBAAuB,CAAC;AACtC,cAAc,oDAAoD,CAAC;AACnE,cAAc,sBAAsB,CAAC;AACrC,cAAc,wCAAwC,CAAC;AACvD,cAAc,mCAAmC,CAAC;AAClD,cAAc,0CAA0C,CAAC;AACzD,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,kCAAkC,CAAC;AACjD,cAAc,oCAAoC,CAAC;AACnD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0CAA0C,CAAC;AACzD,cAAc,oBAAoB,CAAC;AACnC,cAAc,+BAA+B,CAAC;AAE9C,cAAc,UAAU,CAAC;AACzB,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,6CAA6C,CAAC;AAC5D,cAAc,8CAA8C,CAAC;AAE7D,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,4CAA4C,CAAC;AAC3D,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC"}
@@ -5,6 +5,7 @@ export * from './shared/application-creation-verification.schemas.js';
5
5
  export * from './shared/cdn.schemas.js';
6
6
  export * from './shared/systems-of-record-env.schemas.js';
7
7
  export * from './shared/platform-storage.schemas.js';
8
+ export * from './shared/platform-key-management.schemas.js';
8
9
  export * from './shared/csp.schemas.js';
9
10
  export * from './shared/csp-defaults.js';
10
11
  export * from './shared/csp-emit.js';
@@ -21,7 +22,9 @@ export * from './shared/k8s-utils.js';
21
22
  export * from './shared/env-example-defaults.js';
22
23
  export * from './loader.js';
23
24
  export * from './static-asset-import-noop.js';
25
+ export * from './owning-package-tsconfig.js';
24
26
  export * from './application-public-pricing-catalog.loader.js';
27
+ export * from './application-served-public-documents.loader.js';
25
28
  export * from './define-framework-config.js';
26
29
  export * from './define-infra-env-config.js';
27
30
  export * from './hosted-infra-env-config.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/project-config/index.ts"],"names":[],"mappings":"AAAA,cAAc,mCAAmC,CAAC;AAClD,cAAc,sCAAsC,CAAC;AACrD,cAAc,uBAAuB,CAAC;AACtC,cAAc,oDAAoD,CAAC;AACnE,cAAc,sBAAsB,CAAC;AACrC,cAAc,wCAAwC,CAAC;AACvD,cAAc,mCAAmC,CAAC;AAClD,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,kCAAkC,CAAC;AACjD,cAAc,oCAAoC,CAAC;AACnD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0CAA0C,CAAC;AACzD,cAAc,oBAAoB,CAAC;AACnC,cAAc,+BAA+B,CAAC;AAE9C,cAAc,UAAU,CAAC;AACzB,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6CAA6C,CAAC;AAE5D,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,4CAA4C,CAAC;AAC3D,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC","sourcesContent":["export * from './shared/backing-services.schemas';\nexport * from './shared/backing-service-servability';\nexport * from './shared/auth.schemas';\nexport * from './shared/application-creation-verification.schemas';\nexport * from './shared/cdn.schemas';\nexport * from './shared/systems-of-record-env.schemas';\nexport * from './shared/platform-storage.schemas';\nexport * from './shared/csp.schemas';\nexport * from './shared/csp-defaults';\nexport * from './shared/csp-emit';\nexport * from './shared/infra-service.schemas';\nexport * from './shared/infra-providers.schemas';\nexport * from './shared/platform-services.schemas';\nexport * from './shared/data-services.schemas';\nexport * from './shared/application-modules.schemas';\nexport * from './shared/application-modules.utils';\nexport * from './shared/service-definitions.schemas';\nexport * from './shared/environment.schemas';\nexport * from './shared/infrastructure-defaults.schemas';\nexport * from './shared/k8s-utils';\nexport * from './shared/env-example-defaults';\n\nexport * from './loader';\nexport * from './static-asset-import-noop';\nexport * from './application-public-pricing-catalog.loader';\n\nexport * from './define-framework-config';\nexport * from './define-infra-env-config';\nexport * from './hosted-infra-env-config';\nexport * from './shared/minion-platform-access.vocabulary';\nexport * from './define-saas-config';\nexport * from './provider-companion-discovery';\nexport * from './provider-catalog-types';\nexport * from './provider-runtime-artifacts';\nexport * from './define-worker-config';\nexport * from './define-minion-config';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/project-config/index.ts"],"names":[],"mappings":"AAAA,cAAc,mCAAmC,CAAC;AAClD,cAAc,sCAAsC,CAAC;AACrD,cAAc,uBAAuB,CAAC;AACtC,cAAc,oDAAoD,CAAC;AACnE,cAAc,sBAAsB,CAAC;AACrC,cAAc,wCAAwC,CAAC;AACvD,cAAc,mCAAmC,CAAC;AAClD,cAAc,0CAA0C,CAAC;AACzD,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,kCAAkC,CAAC;AACjD,cAAc,oCAAoC,CAAC;AACnD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0CAA0C,CAAC;AACzD,cAAc,oBAAoB,CAAC;AACnC,cAAc,+BAA+B,CAAC;AAE9C,cAAc,UAAU,CAAC;AACzB,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,6CAA6C,CAAC;AAC5D,cAAc,8CAA8C,CAAC;AAE7D,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,4CAA4C,CAAC;AAC3D,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC","sourcesContent":["export * from './shared/backing-services.schemas';\nexport * from './shared/backing-service-servability';\nexport * from './shared/auth.schemas';\nexport * from './shared/application-creation-verification.schemas';\nexport * from './shared/cdn.schemas';\nexport * from './shared/systems-of-record-env.schemas';\nexport * from './shared/platform-storage.schemas';\nexport * from './shared/platform-key-management.schemas';\nexport * from './shared/csp.schemas';\nexport * from './shared/csp-defaults';\nexport * from './shared/csp-emit';\nexport * from './shared/infra-service.schemas';\nexport * from './shared/infra-providers.schemas';\nexport * from './shared/platform-services.schemas';\nexport * from './shared/data-services.schemas';\nexport * from './shared/application-modules.schemas';\nexport * from './shared/application-modules.utils';\nexport * from './shared/service-definitions.schemas';\nexport * from './shared/environment.schemas';\nexport * from './shared/infrastructure-defaults.schemas';\nexport * from './shared/k8s-utils';\nexport * from './shared/env-example-defaults';\n\nexport * from './loader';\nexport * from './static-asset-import-noop';\nexport * from './owning-package-tsconfig';\nexport * from './application-public-pricing-catalog.loader';\nexport * from './application-served-public-documents.loader';\n\nexport * from './define-framework-config';\nexport * from './define-infra-env-config';\nexport * from './hosted-infra-env-config';\nexport * from './shared/minion-platform-access.vocabulary';\nexport * from './define-saas-config';\nexport * from './provider-companion-discovery';\nexport * from './provider-catalog-types';\nexport * from './provider-runtime-artifacts';\nexport * from './define-worker-config';\nexport * from './define-minion-config';\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"npm-version-range.d.ts","sourceRoot":"","sources":["../../../../src/project-config/npm-version-range.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAyIH;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CAAC,gBAAgB,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAkBrG"}
1
+ {"version":3,"file":"npm-version-range.d.ts","sourceRoot":"","sources":["../../../../src/project-config/npm-version-range.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAiKH;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CAAC,gBAAgB,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAkBrG"}
@@ -57,6 +57,24 @@ function compare(left, right) {
57
57
  }
58
58
  return 0;
59
59
  }
60
+ /**
61
+ * The primitive comparator operators every range desugars to. Caret, tilde, X-range and hyphen ranges are SUGAR:
62
+ * {@link comparatorsOf} expands each into these, so {@link holds} only ever decides one of five comparisons. The
63
+ * values are npm's own spellings, which is what lets a written `<=1.2.3` be read straight into a member.
64
+ */
65
+ var NpmComparatorOperator;
66
+ (function (NpmComparatorOperator) {
67
+ NpmComparatorOperator["LESS_THAN"] = "<";
68
+ NpmComparatorOperator["LESS_THAN_OR_EQUAL"] = "<=";
69
+ NpmComparatorOperator["GREATER_THAN"] = ">";
70
+ NpmComparatorOperator["GREATER_THAN_OR_EQUAL"] = ">=";
71
+ /** Exact match — also what a bare full version (`1.2.3`, no operator) means. */
72
+ NpmComparatorOperator["EQUAL"] = "=";
73
+ })(NpmComparatorOperator || (NpmComparatorOperator = {}));
74
+ /** The member a written primitive operator names, or `undefined` for sugar (`^`, `~`) and anything else. */
75
+ function primitiveOperatorOf(text) {
76
+ return Object.values(NpmComparatorOperator).includes(text) ? text : undefined;
77
+ }
60
78
  const isWildcard = (part) => part === undefined || part === 'x' || part === 'X' || part === '*';
61
79
  /** A partial `major.minor.patch` with its wildcards, or `undefined` when the text is not one. */
62
80
  function parsePartial(text) {
@@ -80,44 +98,49 @@ function comparatorsOf(token) {
80
98
  return undefined;
81
99
  const { major, minor, patch, prerelease } = partial;
82
100
  if (major === undefined)
83
- return operator === '<' || operator === '>' ? [{ operator: '<', version: version(0, 0, 0, ['0']) }] : [];
101
+ return operator === NpmComparatorOperator.LESS_THAN || operator === NpmComparatorOperator.GREATER_THAN
102
+ ? [{ operator: NpmComparatorOperator.LESS_THAN, version: version(0, 0, 0, ['0']) }]
103
+ : [];
84
104
  if (operator === '^') {
85
105
  const lower = version(major, minor ?? 0, patch ?? 0, prerelease);
86
106
  const upper = major > 0 || minor === undefined ? version(major + 1, 0, 0, ['0'])
87
107
  : minor > 0 || patch === undefined ? version(0, minor + 1, 0, ['0'])
88
108
  : version(0, 0, patch + 1, ['0']);
89
- return [{ operator: '>=', version: lower }, { operator: '<', version: upper }];
109
+ return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }, { operator: NpmComparatorOperator.LESS_THAN, version: upper }];
90
110
  }
91
111
  if (operator === '~' || operator === '~>') {
92
112
  const lower = version(major, minor ?? 0, patch ?? 0, prerelease);
93
113
  const upper = minor === undefined ? version(major + 1, 0, 0, ['0']) : version(major, minor + 1, 0, ['0']);
94
- return [{ operator: '>=', version: lower }, { operator: '<', version: upper }];
114
+ return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }, { operator: NpmComparatorOperator.LESS_THAN, version: upper }];
95
115
  }
96
116
  // An X-range: the wildcard positions widen the comparator to the whole span they cover.
97
117
  if (minor === undefined || patch === undefined) {
98
118
  const lower = version(major, minor ?? 0, 0);
99
119
  const upper = minor === undefined ? version(major + 1, 0, 0, ['0']) : version(major, minor + 1, 0, ['0']);
100
- switch (operator) {
101
- case '':
102
- case '=': return [{ operator: '>=', version: lower }, { operator: '<', version: upper }];
103
- case '>=': return [{ operator: '>=', version: lower }];
104
- case '<': return [{ operator: '<', version: lower }];
120
+ // A bare X-range (no operator) means the whole span, exactly as `=` does.
121
+ switch (operator === '' ? NpmComparatorOperator.EQUAL : primitiveOperatorOf(operator)) {
122
+ case NpmComparatorOperator.EQUAL:
123
+ return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }, { operator: NpmComparatorOperator.LESS_THAN, version: upper }];
124
+ case NpmComparatorOperator.GREATER_THAN_OR_EQUAL: return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }];
125
+ case NpmComparatorOperator.LESS_THAN: return [{ operator: NpmComparatorOperator.LESS_THAN, version: lower }];
105
126
  // No `-0` here, unlike the upper bounds: node-semver reads `>1.2` as `>=1.3.0`, which admits no 1.3.0 prerelease.
106
- case '>': return [{ operator: '>=', version: version(upper.major, upper.minor, upper.patch) }];
107
- case '<=': return [{ operator: '<', version: upper }];
127
+ case NpmComparatorOperator.GREATER_THAN:
128
+ return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: version(upper.major, upper.minor, upper.patch) }];
129
+ case NpmComparatorOperator.LESS_THAN_OR_EQUAL: return [{ operator: NpmComparatorOperator.LESS_THAN, version: upper }];
108
130
  default: return undefined;
109
131
  }
110
132
  }
111
- return [{ operator: (operator === '' ? '=' : operator), version: version(major, minor, patch, prerelease) }];
133
+ const primitive = operator === '' ? NpmComparatorOperator.EQUAL : primitiveOperatorOf(operator);
134
+ return primitive === undefined ? undefined : [{ operator: primitive, version: version(major, minor, patch, prerelease) }];
112
135
  }
113
136
  function holds(installed, comparator) {
114
137
  const order = compare(installed, comparator.version);
115
138
  switch (comparator.operator) {
116
- case '<': return order < 0;
117
- case '<=': return order <= 0;
118
- case '>': return order > 0;
119
- case '>=': return order >= 0;
120
- case '=': return order === 0;
139
+ case NpmComparatorOperator.LESS_THAN: return order < 0;
140
+ case NpmComparatorOperator.LESS_THAN_OR_EQUAL: return order <= 0;
141
+ case NpmComparatorOperator.GREATER_THAN: return order > 0;
142
+ case NpmComparatorOperator.GREATER_THAN_OR_EQUAL: return order >= 0;
143
+ case NpmComparatorOperator.EQUAL: return order === 0;
121
144
  }
122
145
  }
123
146
  /** One `||` alternative: its comparators, or `undefined` when a token is unreadable. */
@@ -1 +1 @@
1
- {"version":3,"file":"npm-version-range.js","sourceRoot":"","sources":["../../../../src/project-config/npm-version-range.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AASH,sGAAsG;AACtG,MAAM,MAAM,GAAG,eAAe,CAAC;AAC/B,MAAM,eAAe,GAAG,IAAI,MAAM,CAAC,MAAM,MAAM,MAAM,MAAM,MAAM,MAAM,+CAA+C,CAAC,CAAC;AACxH,kFAAkF;AAClF,MAAM,eAAe,GAAG,IAAI,MAAM,CAAC,2HAA2H,CAAC,CAAC;AAEhK,SAAS,YAAY,CAAC,IAAY;IAChC,MAAM,KAAK,GAAG,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;IAChD,IAAI,KAAK,KAAK,IAAI;QAAE,OAAO,SAAS,CAAC;IACrC,OAAO,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,UAAU,EAAE,KAAK,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC;AACtJ,CAAC;AAED,SAAS,kBAAkB,CAAC,IAAY,EAAE,KAAa;IACrD,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,SAAS;QAAE,OAAO,SAAS,CAAC;IAC9C,MAAM,YAAY,GAAG,KAAK,CAAC,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACpE,kHAAkH;IAClH,kHAAkH;IAClH,MAAM,MAAM,GAAG,YAAY,CAAC,GAAG,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,eAAe,CAAC,WAAW,CAAC,CAAC,CAAC;IAC/E,IAAI,MAAM,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,WAAW,KAAK,SAAS,CAAC;QAAE,OAAO,SAAS,CAAC;IAE9E,KAAK,MAAM,WAAW,IAAI,MAAwB,EAAE,CAAC;QACnD,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,KAAK,CAAC,SAAS,EAAE,UAAU,CAAC,CAAC;YAAE,SAAS;QAC/E,IAAI,SAAS,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC;eAC5G,UAAU,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,IAAI,UAAU,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,IAAI,UAAU,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC;YACnJ,SAAS;QACX,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC","sourcesContent":["/**\n * Whether an installed version satisfies an npm version range (#1731) — the one question `wildo config sync` asks of\n * an augmentation's peer range on the package that ships its base provider.\n *\n * Written here rather than taken from the `semver` package because this library has no dependency on it and the\n * question is small; what is implemented is the range grammar npm documents, and anything outside it is UNREAD —\n * `undefined` — never guessed, so the caller refuses a range it cannot read instead of admitting it.\n *\n * spec-cite: https://docs.npmjs.com/cli/v10/using-npm/semver — \"Ranges\": a range set is comparator sets joined by\n * `||`; a comparator set is space-separated comparators, all of which must hold; operators `<`, `<=`, `>`, `>=`, `=`;\n * X-ranges (`*`, `x`, `1.x`, `1.2`), tilde and caret ranges, and hyphen ranges; a prerelease version satisfies a set\n * only when a comparator in it names a prerelease of the same major.minor.patch. Fetched 2026-09-29 (the grammar is\n * the node-semver README's, which that page reproduces).\n */\n\ninterface Version {\n readonly major: number;\n readonly minor: number;\n readonly patch: number;\n readonly prerelease: readonly string[];\n}\n\n/** A numeric identifier: no leading zero (`01` is not a version number, as node-semver also says). */\nconst NUMBER = '(0|[1-9]\\\\d*)';\nconst VERSION_PATTERN = new RegExp(`^v?${NUMBER}\\\\.${NUMBER}\\\\.${NUMBER}(?:-([0-9A-Za-z.-]+))?(?:\\\\+[0-9A-Za-z.-]+)?$`);\n/** A partial version as a range may write it: `1`, `1.2`, `1.x`, `1.2.*`, `*`. */\nconst PARTIAL_PATTERN = new RegExp(`^v?(0|[1-9]\\\\d*|[xX*])(?:\\\\.(0|[1-9]\\\\d*|[xX*]))?(?:\\\\.(0|[1-9]\\\\d*|[xX*]))?(?:-([0-9A-Za-z.-]+))?(?:\\\\+[0-9A-Za-z.-]+)?$`);\n\nfunction parseVersion(text: string): Version | undefined {\n const match = VERSION_PATTERN.exec(text.trim());\n if (match === null) return undefined;\n return { major: Number(match[1]), minor: Number(match[2]), patch: Number(match[3]), prerelease: match[4] === undefined ? [] : match[4].split('.') };\n}\n\nfunction compareIdentifiers(left: string, right: string): number {\n const leftNumeric = /^\\d+$/.test(left);\n const rightNumeric = /^\\d+$/.test(right);\n if (leftNumeric && rightNumeric) return Number(left) - Number(right);\n if (leftNumeric) return -1;\n if (rightNumeric) return 1;\n return left < right ? -1 : left > right ? 1 : 0;\n}\n\nfunction compare(left: Version, right: Version): number {\n if (left.major !== right.major) return left.major - right.major;\n if (left.minor !== right.minor) return left.minor - right.minor;\n if (left.patch !== right.patch) return left.patch - right.patch;\n // A version with a prerelease sorts BEFORE the same version without one.\n if (left.prerelease.length === 0 || right.prerelease.length === 0) return right.prerelease.length - left.prerelease.length;\n for (let index = 0; index < Math.max(left.prerelease.length, right.prerelease.length); index += 1) {\n const l = left.prerelease[index];\n const r = right.prerelease[index];\n if (l === undefined) return -1;\n if (r === undefined) return 1;\n const order = compareIdentifiers(l, r);\n if (order !== 0) return order;\n }\n return 0;\n}\n\ntype Operator = '<' | '<=' | '>' | '>=' | '=';\ninterface Comparator { readonly operator: Operator; readonly version: Version }\n\nconst isWildcard = (part: string | undefined): boolean => part === undefined || part === 'x' || part === 'X' || part === '*';\n\n/** A partial `major.minor.patch` with its wildcards, or `undefined` when the text is not one. */\nfunction parsePartial(text: string): { major?: number; minor?: number; patch?: number; prerelease: readonly string[] } | undefined {\n const match = PARTIAL_PATTERN.exec(text);\n if (match === null) return undefined;\n const major = isWildcard(match[1]) ? undefined : Number(match[1]);\n const minor = major === undefined || isWildcard(match[2]) ? undefined : Number(match[2]);\n const patch = minor === undefined || isWildcard(match[3]) ? undefined : Number(match[3]);\n return { major, minor, patch, prerelease: patch === undefined || match[4] === undefined ? [] : match[4].split('.') };\n}\n\nconst version = (major: number, minor: number, patch: number, prerelease: readonly string[] = []): Version => ({ major, minor, patch, prerelease });\n\n/** The comparators one range token stands for, or `undefined` when the token is not in the grammar. */\nfunction comparatorsOf(token: string): Comparator[] | undefined {\n const operatorMatch = /^(<=|>=|<|>|=|\\^|~>?)?\\s*(.*)$/.exec(token);\n if (operatorMatch === null) return undefined;\n const operator = operatorMatch[1] ?? '';\n const partial = parsePartial(operatorMatch[2]!);\n if (partial === undefined) return undefined;\n const { major, minor, patch, prerelease } = partial;\n\n if (major === undefined) return operator === '<' || operator === '>' ? [{ operator: '<', version: version(0, 0, 0, ['0']) }] : [];\n if (operator === '^') {\n const lower = version(major, minor ?? 0, patch ?? 0, prerelease);\n const upper = major > 0 || minor === undefined ? version(major + 1, 0, 0, ['0'])\n : minor > 0 || patch === undefined ? version(0, minor + 1, 0, ['0'])\n : version(0, 0, patch + 1, ['0']);\n return [{ operator: '>=', version: lower }, { operator: '<', version: upper }];\n }\n if (operator === '~' || operator === '~>') {\n const lower = version(major, minor ?? 0, patch ?? 0, prerelease);\n const upper = minor === undefined ? version(major + 1, 0, 0, ['0']) : version(major, minor + 1, 0, ['0']);\n return [{ operator: '>=', version: lower }, { operator: '<', version: upper }];\n }\n // An X-range: the wildcard positions widen the comparator to the whole span they cover.\n if (minor === undefined || patch === undefined) {\n const lower = version(major, minor ?? 0, 0);\n const upper = minor === undefined ? version(major + 1, 0, 0, ['0']) : version(major, minor + 1, 0, ['0']);\n switch (operator) {\n case '': case '=': return [{ operator: '>=', version: lower }, { operator: '<', version: upper }];\n case '>=': return [{ operator: '>=', version: lower }];\n case '<': return [{ operator: '<', version: lower }];\n // No `-0` here, unlike the upper bounds: node-semver reads `>1.2` as `>=1.3.0`, which admits no 1.3.0 prerelease.\n case '>': return [{ operator: '>=', version: version(upper.major, upper.minor, upper.patch) }];\n case '<=': return [{ operator: '<', version: upper }];\n default: return undefined;\n }\n }\n return [{ operator: (operator === '' ? '=' : operator) as Operator, version: version(major, minor, patch, prerelease) }];\n}\n\nfunction holds(installed: Version, comparator: Comparator): boolean {\n const order = compare(installed, comparator.version);\n switch (comparator.operator) {\n case '<': return order < 0;\n case '<=': return order <= 0;\n case '>': return order > 0;\n case '>=': return order >= 0;\n case '=': return order === 0;\n }\n}\n\n/** One `||` alternative: its comparators, or `undefined` when a token is unreadable. */\nfunction comparatorSetOf(text: string): Comparator[] | undefined {\n const hyphen = /^\\s*(\\S+)\\s+-\\s+(\\S+)\\s*$/.exec(text);\n if (hyphen !== null) {\n const from = comparatorsOf(`>=${hyphen[1]}`);\n const to = parsePartial(hyphen[2]!);\n if (from === undefined || to === undefined) return undefined;\n const upper = to.major === undefined ? [] : to.minor === undefined ? comparatorsOf(`<${to.major + 1}.0.0-0`)\n : to.patch === undefined ? comparatorsOf(`<${to.major}.${to.minor + 1}.0-0`) : comparatorsOf(`<=${hyphen[2]}`);\n return upper === undefined ? undefined : [...from, ...upper];\n }\n // An operator may be written apart from its version (`>= 1.2.3`); join them before splitting on whitespace. Only an\n // operator that starts a token and is followed by a version is joined, so `> = 1.2.3` stays two tokens and is unread.\n const tokens = text.trim().replace(/(^|\\s)(<=|>=|<|>|=|\\^|~>?)\\s+(?=[vV0-9xX*])/g, '$1$2').split(/\\s+/).filter((token) => token.length > 0);\n const comparators: Comparator[] = [];\n for (const token of tokens) {\n const expanded = comparatorsOf(token);\n if (expanded === undefined) return undefined;\n comparators.push(...expanded);\n }\n return comparators;\n}\n\n/**\n * Whether `installedVersion` satisfies `range`: `true`, `false`, or `undefined` when either cannot be read — the range\n * is unread when ANY of its `||` alternatives is.\n *\n * A prerelease version satisfies an alternative only when one of its comparators names a prerelease of the same\n * `major.minor.patch` — npm's rule, so `^1.2.0` does not admit `1.3.0-beta.1`.\n */\nexport function satisfiesNpmVersionRange(installedVersion: string, range: string): boolean | undefined {\n const installed = parseVersion(installedVersion);\n if (installed === undefined) return undefined;\n const alternatives = range.trim() === '' ? [''] : range.split('||');\n // Every alternative is parsed first: a range with ANY unreadable alternative is unread as a whole, whichever side\n // of the `||` it sits on — a satisfied alternative beside one we cannot read is not evidence the author meant it.\n const parsed = alternatives.map((alternative) => comparatorSetOf(alternative));\n if (parsed.some((comparators) => comparators === undefined)) return undefined;\n\n for (const comparators of parsed as Comparator[][]) {\n if (!comparators.every((comparator) => holds(installed, comparator))) continue;\n if (installed.prerelease.length > 0 && !comparators.some((comparator) => comparator.version.prerelease.length > 0\n && comparator.version.major === installed.major && comparator.version.minor === installed.minor && comparator.version.patch === installed.patch)) {\n continue;\n }\n return true;\n }\n return false;\n}\n"]}
1
+ {"version":3,"file":"npm-version-range.js","sourceRoot":"","sources":["../../../../src/project-config/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AI,SAAS,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,MAAM,GAAG,CAAC;eAC5G,UAAU,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,IAAI,UAAU,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,IAAI,UAAU,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC;YACnJ,SAAS;QACX,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC","sourcesContent":["/**\n * Whether an installed version satisfies an npm version range (#1731) — the one question `wildo config sync` asks of\n * an augmentation's peer range on the package that ships its base provider.\n *\n * Written here rather than taken from the `semver` package because this library has no dependency on it and the\n * question is small; what is implemented is the range grammar npm documents, and anything outside it is UNREAD —\n * `undefined` — never guessed, so the caller refuses a range it cannot read instead of admitting it.\n *\n * spec-cite: https://docs.npmjs.com/cli/v10/using-npm/semver — \"Ranges\": a range set is comparator sets joined by\n * `||`; a comparator set is space-separated comparators, all of which must hold; operators `<`, `<=`, `>`, `>=`, `=`;\n * X-ranges (`*`, `x`, `1.x`, `1.2`), tilde and caret ranges, and hyphen ranges; a prerelease version satisfies a set\n * only when a comparator in it names a prerelease of the same major.minor.patch. Fetched 2026-09-29 (the grammar is\n * the node-semver README's, which that page reproduces).\n */\n\ninterface Version {\n readonly major: number;\n readonly minor: number;\n readonly patch: number;\n readonly prerelease: readonly string[];\n}\n\n/** A numeric identifier: no leading zero (`01` is not a version number, as node-semver also says). */\nconst NUMBER = '(0|[1-9]\\\\d*)';\nconst VERSION_PATTERN = new RegExp(`^v?${NUMBER}\\\\.${NUMBER}\\\\.${NUMBER}(?:-([0-9A-Za-z.-]+))?(?:\\\\+[0-9A-Za-z.-]+)?$`);\n/** A partial version as a range may write it: `1`, `1.2`, `1.x`, `1.2.*`, `*`. */\nconst PARTIAL_PATTERN = new RegExp(`^v?(0|[1-9]\\\\d*|[xX*])(?:\\\\.(0|[1-9]\\\\d*|[xX*]))?(?:\\\\.(0|[1-9]\\\\d*|[xX*]))?(?:-([0-9A-Za-z.-]+))?(?:\\\\+[0-9A-Za-z.-]+)?$`);\n\nfunction parseVersion(text: string): Version | undefined {\n const match = VERSION_PATTERN.exec(text.trim());\n if (match === null) return undefined;\n return { major: Number(match[1]), minor: Number(match[2]), patch: Number(match[3]), prerelease: match[4] === undefined ? [] : match[4].split('.') };\n}\n\nfunction compareIdentifiers(left: string, right: string): number {\n const leftNumeric = /^\\d+$/.test(left);\n const rightNumeric = /^\\d+$/.test(right);\n if (leftNumeric && rightNumeric) return Number(left) - Number(right);\n if (leftNumeric) return -1;\n if (rightNumeric) return 1;\n return left < right ? -1 : left > right ? 1 : 0;\n}\n\nfunction compare(left: Version, right: Version): number {\n if (left.major !== right.major) return left.major - right.major;\n if (left.minor !== right.minor) return left.minor - right.minor;\n if (left.patch !== right.patch) return left.patch - right.patch;\n // A version with a prerelease sorts BEFORE the same version without one.\n if (left.prerelease.length === 0 || right.prerelease.length === 0) return right.prerelease.length - left.prerelease.length;\n for (let index = 0; index < Math.max(left.prerelease.length, right.prerelease.length); index += 1) {\n const l = left.prerelease[index];\n const r = right.prerelease[index];\n if (l === undefined) return -1;\n if (r === undefined) return 1;\n const order = compareIdentifiers(l, r);\n if (order !== 0) return order;\n }\n return 0;\n}\n\n/**\n * The primitive comparator operators every range desugars to. Caret, tilde, X-range and hyphen ranges are SUGAR:\n * {@link comparatorsOf} expands each into these, so {@link holds} only ever decides one of five comparisons. The\n * values are npm's own spellings, which is what lets a written `<=1.2.3` be read straight into a member.\n */\nenum NpmComparatorOperator {\n LESS_THAN = '<',\n LESS_THAN_OR_EQUAL = '<=',\n GREATER_THAN = '>',\n GREATER_THAN_OR_EQUAL = '>=',\n /** Exact match — also what a bare full version (`1.2.3`, no operator) means. */\n EQUAL = '=',\n}\n\n/** The member a written primitive operator names, or `undefined` for sugar (`^`, `~`) and anything else. */\nfunction primitiveOperatorOf(text: string): NpmComparatorOperator | undefined {\n return (Object.values(NpmComparatorOperator) as string[]).includes(text) ? (text as NpmComparatorOperator) : undefined;\n}\n\ninterface Comparator { readonly operator: NpmComparatorOperator; readonly version: Version }\n\nconst isWildcard = (part: string | undefined): boolean => part === undefined || part === 'x' || part === 'X' || part === '*';\n\n/** A partial `major.minor.patch` with its wildcards, or `undefined` when the text is not one. */\nfunction parsePartial(text: string): { major?: number; minor?: number; patch?: number; prerelease: readonly string[] } | undefined {\n const match = PARTIAL_PATTERN.exec(text);\n if (match === null) return undefined;\n const major = isWildcard(match[1]) ? undefined : Number(match[1]);\n const minor = major === undefined || isWildcard(match[2]) ? undefined : Number(match[2]);\n const patch = minor === undefined || isWildcard(match[3]) ? undefined : Number(match[3]);\n return { major, minor, patch, prerelease: patch === undefined || match[4] === undefined ? [] : match[4].split('.') };\n}\n\nconst version = (major: number, minor: number, patch: number, prerelease: readonly string[] = []): Version => ({ major, minor, patch, prerelease });\n\n/** The comparators one range token stands for, or `undefined` when the token is not in the grammar. */\nfunction comparatorsOf(token: string): Comparator[] | undefined {\n const operatorMatch = /^(<=|>=|<|>|=|\\^|~>?)?\\s*(.*)$/.exec(token);\n if (operatorMatch === null) return undefined;\n const operator = operatorMatch[1] ?? '';\n const partial = parsePartial(operatorMatch[2]!);\n if (partial === undefined) return undefined;\n const { major, minor, patch, prerelease } = partial;\n\n if (major === undefined) return operator === NpmComparatorOperator.LESS_THAN || operator === NpmComparatorOperator.GREATER_THAN\n ? [{ operator: NpmComparatorOperator.LESS_THAN, version: version(0, 0, 0, ['0']) }]\n : [];\n if (operator === '^') {\n const lower = version(major, minor ?? 0, patch ?? 0, prerelease);\n const upper = major > 0 || minor === undefined ? version(major + 1, 0, 0, ['0'])\n : minor > 0 || patch === undefined ? version(0, minor + 1, 0, ['0'])\n : version(0, 0, patch + 1, ['0']);\n return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }, { operator: NpmComparatorOperator.LESS_THAN, version: upper }];\n }\n if (operator === '~' || operator === '~>') {\n const lower = version(major, minor ?? 0, patch ?? 0, prerelease);\n const upper = minor === undefined ? version(major + 1, 0, 0, ['0']) : version(major, minor + 1, 0, ['0']);\n return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }, { operator: NpmComparatorOperator.LESS_THAN, version: upper }];\n }\n // An X-range: the wildcard positions widen the comparator to the whole span they cover.\n if (minor === undefined || patch === undefined) {\n const lower = version(major, minor ?? 0, 0);\n const upper = minor === undefined ? version(major + 1, 0, 0, ['0']) : version(major, minor + 1, 0, ['0']);\n // A bare X-range (no operator) means the whole span, exactly as `=` does.\n switch (operator === '' ? NpmComparatorOperator.EQUAL : primitiveOperatorOf(operator)) {\n case NpmComparatorOperator.EQUAL:\n return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }, { operator: NpmComparatorOperator.LESS_THAN, version: upper }];\n case NpmComparatorOperator.GREATER_THAN_OR_EQUAL: return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: lower }];\n case NpmComparatorOperator.LESS_THAN: return [{ operator: NpmComparatorOperator.LESS_THAN, version: lower }];\n // No `-0` here, unlike the upper bounds: node-semver reads `>1.2` as `>=1.3.0`, which admits no 1.3.0 prerelease.\n case NpmComparatorOperator.GREATER_THAN:\n return [{ operator: NpmComparatorOperator.GREATER_THAN_OR_EQUAL, version: version(upper.major, upper.minor, upper.patch) }];\n case NpmComparatorOperator.LESS_THAN_OR_EQUAL: return [{ operator: NpmComparatorOperator.LESS_THAN, version: upper }];\n default: return undefined;\n }\n }\n const primitive = operator === '' ? NpmComparatorOperator.EQUAL : primitiveOperatorOf(operator);\n return primitive === undefined ? undefined : [{ operator: primitive, version: version(major, minor, patch, prerelease) }];\n}\n\nfunction holds(installed: Version, comparator: Comparator): boolean {\n const order = compare(installed, comparator.version);\n switch (comparator.operator) {\n case NpmComparatorOperator.LESS_THAN: return order < 0;\n case NpmComparatorOperator.LESS_THAN_OR_EQUAL: return order <= 0;\n case NpmComparatorOperator.GREATER_THAN: return order > 0;\n case NpmComparatorOperator.GREATER_THAN_OR_EQUAL: return order >= 0;\n case NpmComparatorOperator.EQUAL: return order === 0;\n }\n}\n\n/** One `||` alternative: its comparators, or `undefined` when a token is unreadable. */\nfunction comparatorSetOf(text: string): Comparator[] | undefined {\n const hyphen = /^\\s*(\\S+)\\s+-\\s+(\\S+)\\s*$/.exec(text);\n if (hyphen !== null) {\n const from = comparatorsOf(`>=${hyphen[1]}`);\n const to = parsePartial(hyphen[2]!);\n if (from === undefined || to === undefined) return undefined;\n const upper = to.major === undefined ? [] : to.minor === undefined ? comparatorsOf(`<${to.major + 1}.0.0-0`)\n : to.patch === undefined ? comparatorsOf(`<${to.major}.${to.minor + 1}.0-0`) : comparatorsOf(`<=${hyphen[2]}`);\n return upper === undefined ? undefined : [...from, ...upper];\n }\n // An operator may be written apart from its version (`>= 1.2.3`); join them before splitting on whitespace. Only an\n // operator that starts a token and is followed by a version is joined, so `> = 1.2.3` stays two tokens and is unread.\n const tokens = text.trim().replace(/(^|\\s)(<=|>=|<|>|=|\\^|~>?)\\s+(?=[vV0-9xX*])/g, '$1$2').split(/\\s+/).filter((token) => token.length > 0);\n const comparators: Comparator[] = [];\n for (const token of tokens) {\n const expanded = comparatorsOf(token);\n if (expanded === undefined) return undefined;\n comparators.push(...expanded);\n }\n return comparators;\n}\n\n/**\n * Whether `installedVersion` satisfies `range`: `true`, `false`, or `undefined` when either cannot be read — the range\n * is unread when ANY of its `||` alternatives is.\n *\n * A prerelease version satisfies an alternative only when one of its comparators names a prerelease of the same\n * `major.minor.patch` — npm's rule, so `^1.2.0` does not admit `1.3.0-beta.1`.\n */\nexport function satisfiesNpmVersionRange(installedVersion: string, range: string): boolean | undefined {\n const installed = parseVersion(installedVersion);\n if (installed === undefined) return undefined;\n const alternatives = range.trim() === '' ? [''] : range.split('||');\n // Every alternative is parsed first: a range with ANY unreadable alternative is unread as a whole, whichever side\n // of the `||` it sits on — a satisfied alternative beside one we cannot read is not evidence the author meant it.\n const parsed = alternatives.map((alternative) => comparatorSetOf(alternative));\n if (parsed.some((comparators) => comparators === undefined)) return undefined;\n\n for (const comparators of parsed as Comparator[][]) {\n if (!comparators.every((comparator) => holds(installed, comparator))) continue;\n if (installed.prerelease.length > 0 && !comparators.some((comparator) => comparator.version.prerelease.length > 0\n && comparator.version.major === installed.major && comparator.version.minor === installed.minor && comparator.version.patch === installed.patch)) {\n continue;\n }\n return true;\n }\n return false;\n}\n"]}
@@ -0,0 +1,15 @@
1
+ /**
2
+ * The `tsconfig.json` of the package a source file belongs to: found by walking up from the file to the first
3
+ * directory holding a `package.json`. `undefined` when that package has no `tsconfig.json` — never a parent's, which
4
+ * describes a different package.
5
+ *
6
+ * A tool that evaluates an application's own TypeScript in-process (`tsImport`) must compile it with the options of
7
+ * the package it lives in. Left alone, `tsImport` reads the `tsconfig.json` of the current directory, which for a
8
+ * CLI command or the dev companion is the application root, not the website. The difference that bites is JSX: a
9
+ * website compiles with the automatic runtime (`jsx: react-jsx`), and without it esbuild emits classic
10
+ * `React.createElement`, so any JSX evaluated at import time (an icon map, a table of drawings) fails with
11
+ * "React is not defined". `wildo website audit` and the companion's structured-data audit both load website modules,
12
+ * so both resolve the tsconfig here.
13
+ */
14
+ export declare function resolveOwningPackageTsconfigPath(filePath: string): string | undefined;
15
+ //# sourceMappingURL=owning-package-tsconfig.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"owning-package-tsconfig.d.ts","sourceRoot":"","sources":["../../../../src/project-config/owning-package-tsconfig.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;;GAYG;AACH,wBAAgB,gCAAgC,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAWrF"}
@@ -0,0 +1,29 @@
1
+ import { existsSync } from 'node:fs';
2
+ import { dirname, join } from 'node:path';
3
+ /**
4
+ * The `tsconfig.json` of the package a source file belongs to: found by walking up from the file to the first
5
+ * directory holding a `package.json`. `undefined` when that package has no `tsconfig.json` — never a parent's, which
6
+ * describes a different package.
7
+ *
8
+ * A tool that evaluates an application's own TypeScript in-process (`tsImport`) must compile it with the options of
9
+ * the package it lives in. Left alone, `tsImport` reads the `tsconfig.json` of the current directory, which for a
10
+ * CLI command or the dev companion is the application root, not the website. The difference that bites is JSX: a
11
+ * website compiles with the automatic runtime (`jsx: react-jsx`), and without it esbuild emits classic
12
+ * `React.createElement`, so any JSX evaluated at import time (an icon map, a table of drawings) fails with
13
+ * "React is not defined". `wildo website audit` and the companion's structured-data audit both load website modules,
14
+ * so both resolve the tsconfig here.
15
+ */
16
+ export function resolveOwningPackageTsconfigPath(filePath) {
17
+ let directory = dirname(filePath);
18
+ for (;;) {
19
+ if (existsSync(join(directory, 'package.json'))) {
20
+ const tsconfig = join(directory, 'tsconfig.json');
21
+ return existsSync(tsconfig) ? tsconfig : undefined;
22
+ }
23
+ const parent = dirname(directory);
24
+ if (parent === directory)
25
+ return undefined;
26
+ directory = parent;
27
+ }
28
+ }
29
+ //# sourceMappingURL=owning-package-tsconfig.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"owning-package-tsconfig.js","sourceRoot":"","sources":["../../../../src/project-config/owning-package-tsconfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAE1C;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,gCAAgC,CAAC,QAAgB;IAC/D,IAAI,SAAS,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IAClC,SAAS,CAAC;QACR,IAAI,UAAU,CAAC,IAAI,CAAC,SAAS,EAAE,cAAc,CAAC,CAAC,EAAE,CAAC;YAChD,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,EAAE,eAAe,CAAC,CAAC;YAClD,OAAO,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC;QACrD,CAAC;QACD,MAAM,MAAM,GAAG,OAAO,CAAC,SAAS,CAAC,CAAC;QAClC,IAAI,MAAM,KAAK,SAAS;YAAE,OAAO,SAAS,CAAC;QAC3C,SAAS,GAAG,MAAM,CAAC;IACrB,CAAC;AACH,CAAC","sourcesContent":["import { existsSync } from 'node:fs';\nimport { dirname, join } from 'node:path';\n\n/**\n * The `tsconfig.json` of the package a source file belongs to: found by walking up from the file to the first\n * directory holding a `package.json`. `undefined` when that package has no `tsconfig.json` — never a parent's, which\n * describes a different package.\n *\n * A tool that evaluates an application's own TypeScript in-process (`tsImport`) must compile it with the options of\n * the package it lives in. Left alone, `tsImport` reads the `tsconfig.json` of the current directory, which for a\n * CLI command or the dev companion is the application root, not the website. The difference that bites is JSX: a\n * website compiles with the automatic runtime (`jsx: react-jsx`), and without it esbuild emits classic\n * `React.createElement`, so any JSX evaluated at import time (an icon map, a table of drawings) fails with\n * \"React is not defined\". `wildo website audit` and the companion's structured-data audit both load website modules,\n * so both resolve the tsconfig here.\n */\nexport function resolveOwningPackageTsconfigPath(filePath: string): string | undefined {\n let directory = dirname(filePath);\n for (;;) {\n if (existsSync(join(directory, 'package.json'))) {\n const tsconfig = join(directory, 'tsconfig.json');\n return existsSync(tsconfig) ? tsconfig : undefined;\n }\n const parent = dirname(directory);\n if (parent === directory) return undefined;\n directory = parent;\n }\n}\n"]}
@@ -356,10 +356,10 @@ export declare function readPackageVersion(packageRoot: string): string | undefi
356
356
  * The case that motivated it (#2014) was a leftover install of the since-archived catalogue, whose `asana` subpath
357
357
  * sorted first; the same holds for any framework `@wildo-ai/provider-<ref>` package installed beside the copy.
358
358
  *
359
- * Scoped to one runtime on purpose: the same ref legitimately has one path per FACET — `posthog` is
360
- * `@wildo-ai/external-connectors-public/app` for the SaaS frontend and `@wildo-ai/external-connectors-private/backend`
361
- * for the backend. Measured 2026-09-29 over Wonder Todos and Wonder CRM: six refs have several paths, and no ref has
362
- * two for the same runtime.
359
+ * Scoped to one runtime on purpose: the same ref legitimately has one path per FACET — an installed `posthog` is
360
+ * `@<app>/provider-posthog-frontend/app` for the SaaS frontend and `@<app>/provider-posthog/backend` for the backend
361
+ * (#2579). Measured 2026-09-29 over Wonder Todos and Wonder CRM: six refs have several paths, and no ref has two for
362
+ * the same runtime.
363
363
  *
364
364
  * Shared by discovery validation (`wildo config sync`, `wildo lock check`) and the artifact builder, so the two
365
365
  * cannot disagree about what counts as a second claimant.
@@ -1 +1 @@
1
- {"version":3,"file":"provider-companion-discovery.d.ts","sourceRoot":"","sources":["../../../../src/project-config/provider-companion-discovery.ts"],"names":[],"mappings":"AAGA,OAAO,EAKL,KAAK,gCAAgC,EACrC,KAAK,6BAA6B,EAClC,KAAK,yBAAyB,EAGS,MAAM,uBAAuB,CAAC;AAGvE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAG5D;;;;;;;;GAQG;AACH,oBAAY,6BAA6B;IACvC,sGAAsG;IACtG,OAAO,YAAY;IACnB,mDAAmD;IACnD,OAAO,YAAY;IACnB,kDAAkD;IAClD,MAAM,WAAW;IACjB,uDAAuD;IACvD,MAAM,WAAW;IACjB;;;;OAIG;IACH,gBAAgB,oBAAoB;CACrC;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,iCAAiC,wBAAwB,CAAC;AAEvE;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,iCAAiC,0CAA0C,CAAC;AAEzF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,mCAAmC,gCAAgC,CAAC;AAEjF;;;;;GAKG;AACH,oBAAY,4BAA4B;IACtC,uGAAuG;IACvG,QAAQ,aAAa;IACrB,+GAA+G;IAC/G,gBAAgB,qBAAqB;IACrC,uGAAuG;IACvG,aAAa,k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CAAC;IAC1D;;;;;OAKG;IACH,0BAA0B,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CAChD,GAAG,IAAI,CAkJP;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,iCAAiC,CAAC,KAAK,EAAE;IACvD,UAAU,EAAE,IAAI,CAAC,eAAe,EAAE,WAAW,GAAG,iBAAiB,CAAC,CAAC;IACnE,uBAAuB,EAAE,SAAS,uCAAuC,EAAE,CAAC;CAC7E,GAAG;IAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IAAC,UAAU,EAAE,MAAM,EAAE,CAAA;CAAE,CAoF7C;AA6ID;;;;GAIG;AACH,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,uCAAuC,GAAG;IAAE,eAAe,EAAE,MAAM,CAAC;IAAC,kBAAkB,CAAC,EAAE,MAAM,CAAA;CAAE,CAOlJ;AA0YD,kHAAkH;AAClH,wBAAgB,kBAAkB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAW1E;AAsGD;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,iDAAiD,CAC/D,WAAW,EAAE,MAAM,EACnB,YAAY,EAAE,MAAM,EACpB,aAAa,EAAE,SAAS,uCAAuC,EAAE,GAChE,MAAM,GAAG,SAAS,CAgBpB"}
1
+ {"version":3,"file":"provider-companion-discovery.d.ts","sourceRoot":"","sources":["../../../../src/project-config/provider-companion-discovery.ts"],"names":[],"mappings":"AAGA,OAAO,EAKL,KAAK,gCAAgC,EACrC,KAAK,6BAA6B,EAClC,KAAK,yBAAyB,EAGS,MAAM,uBAAuB,CAAC;AAGvE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAG5D;;;;;;;;GAQG;AACH,oBAAY,6BAA6B;IACvC,sGAAsG;IACtG,OAAO,YAAY;IACnB,mDAAmD;IACnD,OAAO,YAAY;IACnB,kDAAkD;IAClD,MAAM,WAAW;IACjB,uDAAuD;IACvD,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const BASE_OWNED_AUGMENTATION_RECORD_KEYS = {
655
655
  secretsContractShape: 'a secrets contract',
656
656
  secretsContract: 'a secrets contract',
657
657
  protocolSecretRefs: 'the secret a protocol binding reads',
658
+ protocolSecretSlots: 'the secrets a protocol binding reads',
658
659
  engineCapabilities: 'an engine capability',
659
660
  providerCapabilities: 'a provider capability',
660
661
  admissibleConnections: 'the connections a provider admits',
@@ -825,11 +826,14 @@ function readPeerDependencyRange(packageRoot, dependencyName) {
825
826
  */
826
827
  function describeUndiscoveredAugmentationPackage(packageName, baseRef) {
827
828
  const scope = packageName.startsWith('@') ? packageName.split('/')[0] : undefined;
828
- const prefix = `providers.augmentations opts "${packageName}" into "${baseRef}", but discovery found no augmentation from that package.`;
829
+ // First the remedy when the package is simply GONE: `wildo registry remove` takes the package and never edits the opt-in,
830
+ // which is the application's (#2022 review F4), so the stale entry is what has to go.
831
+ const prefix = `providers.augmentations opts "${packageName}" into "${baseRef}", but discovery found no augmentation from that package. `
832
+ + `If the package was removed (\`wildo registry remove\`, or by hand), delete "${packageName}" from providers.augmentations."${baseRef}".`;
829
833
  if (scope === undefined || scope === '@wildo-ai') {
830
- return `${prefix} Check that it is a dependency of a runtime owner, is installed, and exports \`providerAugmentations\` from its \`./companion\` door.`;
834
+ return `${prefix} Otherwise check that it is a dependency of a runtime owner, is installed, and exports \`providerAugmentations\` from its \`./companion\` door.`;
831
835
  }
832
- return `${prefix} Discovery walks \`@wildo-ai/provider-*\`, the engine barrel and packages named `
836
+ return `${prefix} Otherwise: discovery walks \`@wildo-ai/provider-*\`, the engine barrel and packages named `
833
837
  + `\`<application-scope>/provider-*\` by themselves; any other package is walked only when \`providers.packages\` lists it. `
834
838
  + `List "${packageName}" there, and make it a dependency of a runtime owner.`;
835
839
  }
@@ -880,7 +884,7 @@ function resolveRuntimeOwnerPackageRoots(saasRoot, saasConfig) {
880
884
  }
881
885
  function resolveContributionTargets(saasRoot, saasConfig) {
882
886
  const shouldIncludeBackendServices = hasAnyProviders(saasConfig.providers.scopes.backend?.providers);
883
- const frontendServiceProviderScopes = Object.entries(saasConfig.providers.scopes.frontendServices ?? {})
887
+ const frontendRelationshipScopes = Object.entries(saasConfig.providers.scopes.frontendServices ?? {})
884
888
  .filter(([, scope]) => hasAnyProviders(scope.providers))
885
889
  .map(([serviceKey]) => serviceKey);
886
890
  const minionProviderScopes = Object.entries(saasConfig.providers.scopes.minions ?? {})
@@ -892,7 +896,7 @@ function resolveContributionTargets(saasRoot, saasConfig) {
892
896
  return [
893
897
  ...Object.entries(saasConfig.services)
894
898
  .filter(([key, definition]) => (definition.frontendType
895
- ? frontendServiceProviderScopes.includes(key)
899
+ ? frontendRelationshipScopes.includes(key)
896
900
  : shouldIncludeBackendServices))
897
901
  .map(([key, definition]) => ({
898
902
  kind: ProviderContributionOwnerKind.SERVICE,
@@ -1207,10 +1211,10 @@ function validateRuntimeScopeAgainstDiscovery(input) {
1207
1211
  * The case that motivated it (#2014) was a leftover install of the since-archived catalogue, whose `asana` subpath
1208
1212
  * sorted first; the same holds for any framework `@wildo-ai/provider-<ref>` package installed beside the copy.
1209
1213
  *
1210
- * Scoped to one runtime on purpose: the same ref legitimately has one path per FACET — `posthog` is
1211
- * `@wildo-ai/external-connectors-public/app` for the SaaS frontend and `@wildo-ai/external-connectors-private/backend`
1212
- * for the backend. Measured 2026-09-29 over Wonder Todos and Wonder CRM: six refs have several paths, and no ref has
1213
- * two for the same runtime.
1214
+ * Scoped to one runtime on purpose: the same ref legitimately has one path per FACET — an installed `posthog` is
1215
+ * `@<app>/provider-posthog-frontend/app` for the SaaS frontend and `@<app>/provider-posthog/backend` for the backend
1216
+ * (#2579). Measured 2026-09-29 over Wonder Todos and Wonder CRM: six refs have several paths, and no ref has two for
1217
+ * the same runtime.
1214
1218
  *
1215
1219
  * Shared by discovery validation (`wildo config sync`, `wildo lock check`) and the artifact builder, so the two
1216
1220
  * cannot disagree about what counts as a second claimant.