bug(ui): child core UIs that don't import the i18n runtime ship no @lingui/* share-scope entries — host auth plugin fails SSR composition with RUNTIME-012
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- react, typescript
- Ambito
- devtools, frontend, internationalization
Direzione di ricerca
Start by reading the shared-deps spec at every-plugin/shared-deps-spec and the platform UI's ui/src/i18n/catalogs.ts, ui/src/i18n/runtime.tsx, and __root.tsx pattern. Compare those with the generated stubs and child UI build manifests described in the report to choose where the missing provider should be supplied. Done means a child core UI without its own i18n imports can compose the auth plugin during SSR without RUNTIME-012; the issue leaves the implementation choice open.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Summary
A child app that overrides app.ui with its own core UI replaces the platform's UI as the core-ui provider in its federation graph — but it only emits shared-scope entries for UI deps it actually imports. The platform's auth plugin (pinned child-side via the extends chain) consumes shared @lingui/core, @lingui/react, and everything-dev/ui/i18n with import: false (consumer role per every-plugin/shared-deps-spec UI_SHARED_DEPS). A child UI authored before the i18n adoption never imports everything-dev/ui/i18n at runtime (e.g. appLocale is only read via type imports / passed to createServerRouterModule, which uses it for cookie/Accept-Language negotiation only) — so the child's bundles ship no @lingui/* share-scope entries, and boot fails:
Boot SSR composition FAILED — health stays degraded: UnknownError
(cause: Error: The getter for the shared module is not a function. This may be
caused by setting "shared.import: false" without the host providing the
corresponding lib. #RUNTIME-012
args: {"shareKey":"@lingui/core"})
The failure only surfaces at runtime, on every boot, and pins the child's health to degraded even when the api and all other plugins load.
Evidence (manifests fetched from the CDN)
- Parent platform's own UI (gitSha
b63f0b5, the canonical core-ui provider) shares the full UI dep set:@lingui/core 5.9.0,@lingui/react 5.9.0,everything-dev/ui/i18n 2.0.0-rc.12, plus react/react-dom/@tanstack/@orpc. - Child UI built with every-plugin 3.0.0-rc.8 + everything-dev 2.0.0-rc.12 shares
react,react-dom,@tanstack/*,@orpc/*,everything-dev/ui/auth— no@lingui/*, noeverything-dev/ui/i18n(web and ssr manifests identical). - The pinned auth bundle's chunks request
shareKey: "@lingui/core"/"@lingui/react"; the parent's host bundle's mf-manifest lists only the core shared deps (no UI deps), so nothing else in the graph can satisfy the request.
The parent's own app wires the canonical seam: app-owned ui/src/i18n/catalogs.ts + ui/src/i18n/runtime.tsx (createLocaleRuntime → AppI18nProvider), mounted in the root route (__root.tsx imports @/i18n/runtime). Child apps scaffolded before that pattern existed don't have it, and neither init/sync nor the build flags the gap.
Fix options (maintainer's pick)
- Scaffold the seam in
init/sync: writeui/src/i18n/{catalogs,runtime}.tsx(derived from the app'sappLocalebootstrap export) and mountAppI18nProviderin the root route — matches the canonical pattern, keeps the strict-singleton version checks meaningful. - Emit the full UI_SHARED_DEPS in the core-ui build regardless of imports, so the share scope is always complete — and/or fail the build when a UI_SHARED_DEPS entry has no provider in the graph (build-time failure instead of runtime boot failure).
- Wire the provider in the generated stubs (
entry.gen.ts/router.server.gen.tsxalready readappLocale), so the framework owns the mount.
Local mitigation
The affected child app added an i18n-seam check + maintenance step to its scripts/v2-upgrade/ (pnpm i18n-seam): detects "appLocale declared but no runtime everything-dev/ui/i18n import / provider unmounted", scaffolds the canonical seam, and mounts the provider.
- Lingua principale
- TypeScript
- Stelle
- 5
- Fork
- 3
- Merge medio
- 9h 55m
- PR unite (30g)
- 108
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di NEARBuilders/everything-dev
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
NEARBuilders/everything-dev#400 ·
I maintainer di solito rispondono entro 1 giorno
-
Parent runtime republished with react 19.2.9 shared deps breaks rc.16-pinned children (SSR composition fails)Forse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
NEARBuilders/everything-dev#546 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 54/100
NEARBuilders/everything-dev#545 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
NEARBuilders/everything-dev#531 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
NEARBuilders/everything-dev#526 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di NEARBuilders/everything-dev
Issue simili
-
bug skills
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
equinor/fusion-framework#5846 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 74/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
Eyevinn/open-videocore#1256 ·
I maintainer di solito rispondono entro 1 giorno
-
Frontend build fails with Frappe version-16: DataImport is no longer exported by @framework/uiApertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
[Bug]: Theme preset geist points at undefined --font-geistForse già presa @claude l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
I maintainer di solito rispondono entro 1 giorno