rspack icon indicating copy to clipboard operation
rspack copied to clipboard

[Bug]: Upgrade from 1.5.8 to 1.6.0 breaks module federation.

Open skearney414 opened this issue 1 month ago • 2 comments

System Info

System: OS: Windows 11 10.0.22631 CPU: (20) x64 13th Gen Intel(R) Core(TM) i7-1370P Memory: 1.99 GB / 31.66 GB Binaries: Node: 24.4.1 - C:\Program Files\nodejs\node.EXE Yarn: 1.22.21 - C:\Users\Sean.Kearney\AppData\Roaming\npm\yarn.CMD npm: 11.4.2 - C:\Program Files\nodejs\npm.CMD pnpm: 9.12.2 - C:\Users\Sean.Kearney\AppData\Local\pnpm\pnpm.EXE bun: 1.3.1 - C:\Users\Sean.Kearney.bun\bin\bun.EXE Browsers: Chrome: 141.0.7390.123 Edge: Chromium (140.0.3485.54) Firefox: 139.0.4 - C:\Program Files\Mozilla Firefox\firefox.exe Internet Explorer: 11.0.22621.3527

Details

Update to 1.6.0 causes module federation build to fail ● ━━━━━━━━━━━━━━━━━━━━━━━━━ (10%) building container entry (default) [["./AppShell",{"name":null,"import":["./microfrontendEntries/appShell.tsx"]}]error: script "build-serve" exited with code 5

Reproduce link

No response

Reproduce Steps

Add a baseline build with module federation. serve and it no longer works.

skearney414 avatar Nov 04 '25 10:11 skearney414

This is my config

new rspack.container.ModuleFederationPlugin({ name: 'Financials.Shell', library: { type: 'var', name: 'Financials_Shell' }, filename: 'remoteEntry.js', exposes: { './AppShell': './microfrontendEntries/appShell.tsx', './ExportHandler': './microfrontendEntries/exportHandler.tsx', './IntercomButton': './microfrontendEntries/intercomButton.tsx', './ModuleFederationInitHandler': './microfrontendEntries/moduleFederationInitHandler.tsx', './CookieHandler': './microfrontendEntries/cookieHandler.tsx', }, shared: { react: { singleton: true, requiredVersion: '18.3.1' }, 'react-dom': { singleton: true, requiredVersion: '18.3.1' }, '@access-erp/common': { singleton: true }, '@access-erp/ui-components': { singleton: true }, '@financials/graphql-api': { singleton: true }, 'styled-components': { singleton: true }, 'react-hook-form': { singleton: true }, '@financials/common': { singleton: true }, '@financials-core/transactions': { singleton: true }, '@apollo/client': { singleton: true }, 'launchdarkly-react-client-sdk': { singleton: true }, graphql: { singleton: true }, 'react-router': { singleton: true }, zod: { singleton: true }, yup: { singleton: true }, }, }),

skearney414 avatar Nov 04 '25 11:11 skearney414

Hello @skearney414, sorry we can't investigate the problem further without reproduction demo, please provide a repro demo by forking rspack-repro, or provide a minimal GitHub repository by yourself. Issues labeled by need reproduction will be closed if no activities in 14 days.

github-actions[bot] avatar Nov 04 '25 12:11 github-actions[bot]

Since the issue was labeled with need reproduction, but no response in 14 days. This issue will be closed. Feel free to comment and reopen it if you have any further questions.

github-actions[bot] avatar Nov 19 '25 00:11 github-actions[bot]