usdigitalresponse / storefront

Platform for online ordering of food for delivery or pickup
https://food-demo.usdigitalresponse.org/
MIT License
12 stars 4 forks source link

CI builds fail when installing node-sass #219

Open bertday opened 2 years ago

bertday commented 2 years ago

The Netlify build for Bexar County's Storefront instance is failing with the error:

7:47:55 PM: error node-sass@6.0.1: The engine "node" is incompatible with this module. Expected version ">=12". Got "10.24.1"
7:47:55 PM: error Found incompatible module.

For a sample failing build see: https://app.netlify.com/sites/bexar-food/deploys/62b1150a446d523ba2d29f5a

Cloning this locally to see if I can reproduce, and will likely upgrade node-sass.

bertday commented 2 years ago

Checked out this repo out locally and ran through the setup notes in README.md. Got an error:

Failed to compile.

./src/index.scss
Node Sass version 6.0.1 is incompatible with ^4.0.0 || ^5.0.0.

Per this SO post, swapped out node-sass in favor of sass. The build script seems to be running now 🎉

Not sure that this is going to resolve the different node-sass error in Netlify CI that spawned this issue, but going to try deploying against the updated package.json and yarn.lock.

bertday commented 2 years ago

Still getting the same Netlify error. It seems to be happening because Netlify is building using Node 10.x and both node-sass and sass expect at least 12.x. Per the Netlify docs, created a .nvmrc file pegging Node to 16.x (current active LTS).

bertday commented 2 years ago

The Node version error seems to be resolved. Now getting a bunch of ESLint errors. See here for a sample failing build.

Disabling all linting for now; most of the errors seem to be minor/style-related. Not sure how this code base was passing previously 🤷