-
Notifications
You must be signed in to change notification settings - Fork 56
Open
Description
Description:
Some (maybe all?) MFEs have issues with ErrorPages and i18n.
The ErrorPage is invoked before either the Locale is set or Intl is initialized as a whole.
This should likely later be remediated in any MFEs that have this issue.
Repro Steps
- Up devstack (im from REV so, we tend to grab
lms+redis+ecommerce) - Once up, start Payment MFE (we dont use docker for this as there is an issue with the image we have yet to fix, its alo not germaine)
npm ci && npm start - Stop LMS
- Open Payment MFE in a Browser http://localhost:1998/
Technical/Additional Details
Specific Error: getLocale called before configuring i18n. Call configure with messages first.
Stack Trace:
Call Stack
getLocale
node_modules/@edx/frontend-platform/i18n/lib.js:273:11
ErrorPage
node_modules/@edx/frontend-platform/react/ErrorPage.js:82:115
renderWithHooks
node_modules/react-dom/cjs/react-dom.development.js:14803:18
mountIndeterminateComponent
node_modules/react-dom/cjs/react-dom.development.js:17482:13
beginWork
node_modules/react-dom/cjs/react-dom.development.js:18596:16
HTMLUnknownElement.callCallback
node_modules/react-dom/cjs/react-dom.development.js:188:14
Object.invokeGuardedCallbackDev
node_modules/react-dom/cjs/react-dom.development.js:237:16
invokeGuardedCallback
node_modules/react-dom/cjs/react-dom.development.js:292:31
beginWork$1
node_modules/react-dom/cjs/react-dom.development.js:23203:7
performUnitOfWork
node_modules/react-dom/cjs/react-dom.development.js:22154:12
Code Ptr (ErrorPage initialization point): https://github.com/openedx/frontend-template-application/blob/master/src/index.jsx#L28
Community Example (learner MFE): https://discuss.openedx.org/t/when-attempting-to-enter-a-courses-home-on-learning-mfe-error-getlocale-called-before-configuring-i18n/9756/1
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
To Do
Status
Todo
