Repository navigation
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes out plan 078 (phases 4–5). The tenant capability gate collapses to pin presence + policy, and the loader's one silent-degrade path is deleted.
host/src/services/tenant-runtime.ts):ssrAllowed = hasSsrPin(effectiveConfig.ui) && binding.allowSsr.allowSsris pure policy — capability travels with the artifact. The three-field strip keeps its job as pin-removal-as-policy, unchanged. No schema change;allowSsrstays on the binding (the bindings endpoint is still unbuilt, Host 500s every request on non-base domains when GET /api/tenants/bindings 404s — no fallback, and no runtime ships the route #665 — its contract note lands in book 11 §7: bindings carry permissions and status, never capability).version-manifest.tsemitsssr: { entry, integrity }only with both; resolution stamps them together) and the tenant draft flow enforces the pair — but a hand-authored config can carry an ssr URL with no digest: the authored schema (types.tsPluginUiConfigSchema) declaresssr/ssrIntegrityindependently and resolution maps them independently (resolution/runtime.ts:ssrUrl: uiIsRemote ? uiConfig.ssr : undefined,ssrIntegrity: uiIsRemote ? uiConfig.ssrIntegrity : undefined). Deleting the clause would have let a policy-allowed tenant SSR from never-verified bytes. The verdict is pinned in the plan doc and ADR 0061.loadRouterModule): a remote source whose SSR entry lacks an integrity digest is refused by name (FederationError → the caller's documented fallback shape) instead of silently skipping verification; a digest present → verification always runs (unchanged). Dev loopback containers stay exempt — the local entry carries no digest by construction, and that path is pinned by a new test. The olduseCacheintegrity term is dead after the refusal and removed.allowSsr= policy, the dev-default flip with the measured +0.59s / <1s tolerance, the loader clause deleted); book 06 gains an "SSR in dev" section, book 11 §7 and book 12 updated to pin+policy semantics; plan 078 + plans README rows marked DONE (phase 0 via docs(plans): 078 phase 0 — SSR dev rebuild measurements #1204; 1 via feat(ssr): pin-presence gate behind isSsrAvailable — behavior-neutral (plan 078 phase 1) #1211; 2 via feat(dev): supervisor-owned SSR intent — always-emit for ui-local dev (plan 078 phase 2) #1221; 3 via feat(dev): SSR by default for ui-local dev — the flip (plan 078 phase 3, #472) #1226; 4–5 via this PR).Evidence
pnpm --filter host test— 62 files, 410/410 green (tenant matrix re-pinned: policy-allowed + pin → SSR; policy-denied → CSR, strip unchanged; pin absent → CSR regardless of policy; ssrUrl-without-digest → CSR even when policy allows — the crux; new ssrEntryUrl-arm pin test; loader refusal test asserts no load + no verification; dev local-container path pinned)BOS_NO_BANNER=1 pnpm run bos typecheck— 15/15pnpm run lint— green (comment budget holds)pnpm run docs:check— green (73 files)Merge danger
host/src/services/federation/loader.ts— a different function (requireSsrEntryUrl's error message vs this PR'sloadRouterModule); rebase on origin/main before merging if it lands first. No other overlap (its docs are skills/AGENTS/README; this PR's docs are book/plans/ADR).ssrIntegrity, so only hand-authored configs can hit the refusal — those were rendering unverifiable bytes before.