dhis2 / app-platform

DHIS 2 application platform layer with inverted app control
https://platform.dhis2.nu
BSD 3-Clause "New" or "Revised" License
27 stars 16 forks source link

fix(deps): use exact version of workbox to avoid broken 6.6.1 version #843

Closed KaiVandivier closed 7 months ago

KaiVandivier commented 7 months ago

Update: tested this out on alpha, and it's not successful because react-scripts still has a dependency on workbox-webpack-plugin@^6.4.1, which resolves to the broken 6.6.1 upon installation of the CLI


Currently, new installations of cli-app-scripts end up throwing an error on Node 14:

error workbox-webpack-plugin@6.6.1: The engine "node" is incompatible with this module. Expected version ">=16.0.0". Got "14.21.3"

This seems to be due to a broken release of workbox that should have been a major version, but it gets installed because of the ^6 dependency in the platform

The 6.6.1 release is now flagged as deprecated when installed on Node 16, and seems to be removed from the release history, which also shows the next major release as having the exact same breaking change in question (v7: Node 16 is now the minimum version). There is also a reported bug

This will avoid increasing the minimum Node requirement to 16 for app-platform

KaiVandivier commented 7 months ago

Tested on alpha, and this isn't a successful solution because react-scripts still has a dependency on workbox-webpack-plugin@^6.4.1, which resolves to the broken 6.6.1 upon any new installation of cli-app-scripts unfortunately