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

Upgrade webpack v5 and related modules #2402

Closed
wants to merge 33 commits into from

Conversation

thedavidprice
Copy link
Contributor

@thedavidprice thedavidprice commented Apr 30, 2021

I know, I know... Webpack v5 takes longer to build. I'd argue it's time to upgrade as other packages are deprecating v4. And this will give us impetus to push forward with ESbuild.

https://webpack.js.org/migrate/5/

To Do:

Starting the Webpack Dev Server includes the following error (last line starting with web | [HPM] Error). However, this does not seem to actually affect the Dev Server running and the error is not repeated:

...
api | Running at 'http://localhost:8911'
api | Watching files in '/Users/price/Repos/tdp-redwood-tutorial-test/api/src/functions'
web | ℹ 「wds」: Project is running at http://localhost:8910/
web | ℹ 「wds」: webpack output is served from /
web | ℹ 「wds」: Content not from webpack is served from /Users/price/Repos/tdp-redwood-tutorial-test/web
web | ℹ 「wds」: 404s will fallback to /index.html
...
web | [HPM] Error occurred while trying to proxy request /graphql from localhost:8910 to http://[::1]:8911 (ECONNRESET) (https://nodejs.org/api/errors.html#errors_common_system_errors)
...

Possible improvement:

-[ ] "If you have rules defined for loading assets using raw-loader, url-loader, or file-loader, please use Asset Modules instead as they're going to be deprecated in near future.": https://webpack.js.org/guides/asset-modules/

@github-actions
Copy link

github-actions bot commented Apr 30, 2021

📦 PR Packages

Click to Show Package Download Links

https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/create-redwood-app-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-api-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-api-server-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-auth-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-cli-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-core-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-dev-server-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-eslint-config-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-eslint-plugin-redwood-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-forms-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-internal-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-prerender-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-router-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-structure-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-testing-0.31.2-e32d9ec.tgz
https://rw-pr-redwoodjs-com.s3.amazonaws.com/2402/redwoodjs-web-0.31.2-e32d9ec.tgz

Install this PR by running yarn rw upgrade --pr 2402:0.31.2-e32d9ec

@cypress
Copy link

cypress bot commented Apr 30, 2021



Test summary

11 6 0 0Flakiness 0


Run details

Project RedwoodJS Framework
Status Failed
Commit 324b609 ℹ️
Started Jun 2, 2021 3:38 AM
Ended Jun 2, 2021 3:43 AM
Duration 05:24 💡
OS Linux Ubuntu - 20.04
Browser Chrome 90

View run in Cypress Dashboard ➡️


Failures

02-cli/02-cli-commands.spec.js Failed
1 Check Redwood cli commands against tutorial > Should run build successfully (no prerender)
2 Check Redwood cli commands against tutorial > Should prerender about and homepage
03-storybook/storybook.spec.js Failed
1 Redwood Storybook Integration > 1. Component: BlogPost
2 Redwood Storybook Integration > 2. Cells: BlogPostCell and BlogPostsCell
3 Redwood Storybook Integration > 3. Layouts: BlogLayout
4 Redwood Storybook Integration > 3. Pages: AboutPage, ContactPage, and HomePage

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

packages/core/package.json Outdated Show resolved Hide resolved
packages/core/package.json Outdated Show resolved Hide resolved
@thedavidprice thedavidprice removed this from the next-release milestone May 12, 2021
@thedavidprice thedavidprice self-assigned this May 14, 2021
@jtoar jtoar added this to In progress in Core via automation May 18, 2021
@jtoar jtoar linked an issue May 18, 2021 that may be closed by this pull request
@jtoar jtoar added the topic/config Babel, Webpack, ESLint, Prettier, etc. label May 18, 2021
@jtoar jtoar added this to the v1.0 milestone May 18, 2021
@thedavidprice
Copy link
Contributor Author

FYI: Storybook v6.3 will include stable support for Webpack v5
storybookjs/storybook#14397

@thedavidprice
Copy link
Contributor Author

@peterp I attempted further diagnoses. I believe it's a Webpack config error. I attempted disabling loaders and plugins and ... to no avail — I never could resolve the error or produce a different one. My 🧠 is 🍳

@jtoar jtoar moved this from In progress to In progress (priority) in Current-Release-Sprint Jun 4, 2021
@jtoar jtoar removed this from In progress in Core Jun 4, 2021
@jtoar jtoar removed this from the next-release-candidate milestone Jun 4, 2021
@jtoar jtoar added this to the next-release-priority milestone Jun 8, 2021
@thedavidprice thedavidprice marked this pull request as draft June 24, 2021 01:21
@thedavidprice
Copy link
Contributor Author

thedavidprice commented Jun 24, 2021

this has moved to #2884

Keeping this open for reference in time being

@peterp peterp removed their request for review July 6, 2021 21:43
Current-Release-Sprint automation moved this from In progress (priority) to Done Jul 14, 2021
@redwoodjs-bot redwoodjs-bot bot removed this from the next-release-priority milestone Jul 14, 2021
@redwoodjs-bot redwoodjs-bot bot removed this from Done in Current-Release-Sprint Jul 14, 2021
@thedavidprice thedavidprice deleted the dsp-upgrade-webpack-v5 branch July 27, 2021 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release:breaking This PR is a breaking change topic/config Babel, Webpack, ESLint, Prettier, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade to PostCss 8 so that can use later versions of TailwindCss/UI Upgrade webpack v4 to v5
3 participants