Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Replaced deprecated neutrino config with updated webpack config #540

Open
wants to merge 16 commits into
base: master
Choose a base branch
from

Conversation

Carla-Moz
Copy link

@Carla-Moz Carla-Moz commented Jan 9, 2025

The best way to reduce the number of critical dependency errors was to remove the deprecated neutrino config and replace it with a normal webpack config. Other changes included changing the jest and eslint config since they also used neutrino. Will continue to work on both in this PR to get the dashboards closer to something more modern and stable. For now, the app runs locally at the port 5000 and the netlify deploy is fixed.

Updates:

  • Relaxed the eslint rules
  • updated the config.yaml and netlify.toml to update node engine to 18.18.0; added .nvmrc with node version as well
  • squash commits figuring out config.yaml setup to update node engine in circle ci
  • fix the jest config
  • fix eslintrc
  • fix node version w netlify
  • simplify the webpack config

@Carla-Moz Carla-Moz requested review from davehunt and 92kns January 9, 2025 03:00
Copy link

netlify bot commented Jan 9, 2025

Deploy Preview for firefox-performance-dashboard failed. Why did it fail? →

Name Link
🔨 Latest commit 8411a7d
🔍 Latest deploy log https://app.netlify.com/sites/firefox-performance-dashboard/deploys/6789b7f8113259000879f9a0

@davehunt
Copy link
Collaborator

davehunt commented Jan 9, 2025

Great to see progress here. It looks like the deploy is failing with:

error [email protected]: The engine "node" is incompatible with this module. Expected version "^12.22.0 || ^14.17.0 || >=16.0.0". Got "10.24.1"

Is the idea to keep this PR open until tests/deploy are passing? If so, perhaps we should convert it to a draft until it's ready to land? I'll also remove myself from the reviewers as I don't feel qualified to review these changes.

@davehunt davehunt removed their request for review January 9, 2025 12:18
@Carla-Moz Carla-Moz added the WIP label Jan 9, 2025
@Carla-Moz Carla-Moz changed the title Replaced deprecated neutrino config with updated webpack config [WIP] Replaced deprecated neutrino config with updated webpack config Jan 9, 2025
@Carla-Moz
Copy link
Author

Carla-Moz commented Jan 9, 2025

Great to see progress here. It looks like the deploy is failing with:

error [email protected]: The engine "node" is incompatible with this module. Expected version "^12.22.0 || ^14.17.0 || >=16.0.0". Got "10.24.1"

Is the idea to keep this PR open until tests/deploy are passing? If so, perhaps we should convert it to a draft until it's ready to land? I'll also remove myself from the reviewers as I don't feel qualified to review these changes.

@davehunt Yes! It's a WIP so I'll be handling the rest of the errors. Once, it's in a good place, I'll remove the WIP flag. I wanted to put it up now to give visibility to work I'm doing on it.

@Carla-Moz Carla-Moz requested review from julienw and removed request for 92kns January 10, 2025 00:40
Copy link

@julienw julienw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for these updates!

I pointed out some suggestions and problems. The biggest problems is that the tests don't run :-) and when run they are failing.

But IMO it's fine to have tests failing for now, while you're working on fixing things.

Before landing, I think this should be done:

  • simplify the webpack configuration by having just one file and use process.env.NODE_ENV, and get the configuration right
  • get tests running (but failing)
  • figure out which of .nvmrc or the node_version in netlify.toml is needed and keep one of them if both work (I don't mind which one, I'll let you decide)

The other suggestions can be done in follow-ups IMO.

webpack/webpack.common.js Outdated Show resolved Hide resolved
jest.config.js Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
webpack/webpack.development.js Outdated Show resolved Hide resolved
jest.config.js Show resolved Hide resolved
jest.config.js Outdated Show resolved Hide resolved
@@ -2,3 +2,6 @@
from = "/*"
to = "/"
status = 200
[build]
node_version = "18.18.0"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this needed with the `.nvmrc? My understanding is that one or the other is needed but not both, and I'm afraid of seeing them different in the future :-)

"eslint-plugin-jest": "27.0.0",
"eslint-plugin-jest-dom": "^5.5.0",
"eslint-plugin-react": "^7.37.3",
"eslint-plugin-testing-library": "^7.1.1",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note that you're not loading the eslint plugin for testing-libary atm (but that's OK, you can always enable it later)

package.json Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants