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

Potentially update acorn to match latest webpack #245

Closed
dcousineau opened this issue Jan 24, 2019 · 1 comment
Closed

Potentially update acorn to match latest webpack #245

dcousineau opened this issue Jan 24, 2019 · 1 comment

Comments

@dcousineau
Copy link

Issue description

I recently encountered webpack/webpack#8656 during an upgrade where, due to an NPM bug, the wrong version of acorn "wins" and breaks webpack. Running npm ls acorn shows the "winner" of the hoisting being webpack-bundle-analyzer (which I have in devDeps to make analyzing and testing easier).

The npm update acorn --depth 20 && npm dedupe solution does not work in this case, however manually installing via npm install --save-dev acorn@latest worked.

Since webpack-bundle-analyzer is used rarely (only when manually invoked) I may be moving forward by removing it from my package.json, which is probably best practice anyways. I simply wanted to file the issue to add more info/color if anyone else encounters this when they upgrade their webpack.

Technical info

  • Webpack Bundle Analyzer version: 3.0.3
  • Webpack version: 4.29.0
  • Node.js version: 10.14.1
  • npm/yarn version: npm 6.7.0
  • OS: macOS 10.14.3

Debug info

Actual functionality of the tool is unaffected

@valscion
Copy link
Member

So should we allow the acorn dependency to get the same version as webpack is using? Or should we bump it to the same version?

I.e. would this kind of change suffice, given everything would still work?

   ],
   "dependencies": {
-    "acorn": "^5.7.3",
+    "acorn": "^5.7.3 || ^6.0.5",
     "bfj": "^6.1.1",

realityking added a commit to realityking/webpack-bundle-analyzer that referenced this issue Feb 4, 2019
@th0r th0r closed this as completed in #248 Feb 25, 2019
tigefa4u pushed a commit to tigefa4u/gitlabhq that referenced this issue Jul 23, 2019
This is needed to fix an issue where updating to the latest Webpack
causes an acorn dependency error:
webpack-contrib/webpack-bundle-analyzer#245

Seen while trying to update dependencies for Mermaid in
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/30985
tigefa4u pushed a commit to tigefa4u/gitlabhq that referenced this issue Jul 23, 2019
olearycrew pushed a commit to olearycrew/gitlab-core that referenced this issue Dec 4, 2019
This is needed to fix an issue where updating to the latest Webpack
causes an acorn dependency error:
webpack-contrib/webpack-bundle-analyzer#245

Seen while trying to update dependencies for Mermaid in
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/30985
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants