Stripes webpack broken on folio-release-core and folio-release builds

Description

The UI is broken in the latest iteration of the Q2 release of the core modules and complete set of FOLIO modules with some sort of low-level react or webpack error.

https://github.com/folio-org/platform-core . (master) --> https://folio-release-core.aws.indexdata.com

https://github.com/folio-org/platform-complete (master) --> https://folio-release.aws.indexdata.com

CSP Request Details

None

CSP Rejection Details

None

Potential Workaround

None

Attachments

1

Checklist

hide

TestRail: Results

Activity

Show:

Zak Burke July 1, 2019 at 7:27 PM
Edited

Most of the troubleshooting around this focused on platform-complete, rather than platform-core, and that's where we discovered the bad interaction between withRoot() and hot() in ui-eholdings with react-hot-loader > 4.8.8. IIRC, we only observed this issue in platform-core with NODE_ENV="" which is really a valid value an invalid value; it should be either production or development.

My take-away is that this behavior is caused by two or more independent things with react-hot-loader > 4.8.8:

  1. setting NODE_ENV=""

  2. calling export default hot(module)(withRoot($MODULE)) in react-hot-loader > 4.8.8, which we only happen to do in ui-eholdings

It is unclear to me whether eHoldings or withRoot is the actual source; we have not started that investigation.

Matt Jones July 1, 2019 at 4:09 PM

It could. I don't know what the root cause is. It may have been a regression in react-hot-loader, or some existing misconfiguration on our part that wasn't surfaced until a newer version of react-hot-loader was released.

If it's the latter, then eHoldings seems suspect given and found that removing eHoldings from platform-complete also solved the problem. Further, from a cursory glance, eHolding's export differs slightly from other apps. As notes, changing the eHoldings export appears to resolve it.

Then again, as points out, this issue was observed on platform-core which doesn't contain eHoldings. Seems like this issue could use some further analysis.

Sobha Duvvuri July 1, 2019 at 3:22 PM

Ah, got it. Thanks . So, does this issue have anything to do specifically with eHoldings?

Matt Jones July 1, 2019 at 2:45 PM

NODE_ENV=production is a precondition to observing this issue. Based on 's comments, snapshot is using NODE_ENV=development and therefore the issue is not present.

Sobha Duvvuri July 1, 2019 at 2:32 PM
Edited

Hey , , and : We recently got bit by this issue while building similar versions of modules as folio-snapshot and pinning the specific version of react-hot-loader helped us get around this, but since eHoldings was mentioned above, is it really true that eHoldings is the problem-creator? Because, if yes, I can ask our team to look at this issue. Please let us know. Thanks!
Also curious, how did this fix make it into master branch of platform-complete but not snapshot and it still builds fine? Thanks!

Done

Details

Assignee

Reporter

Labels

Priority

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs
Created June 13, 2019 at 2:37 PM
Updated October 16, 2020 at 5:43 PM
Resolved June 13, 2019 at 7:52 PM
TestRail: Cases
TestRail: Runs