Cannot find module './lib/fs' on node 6 #2533
-
🐛 bug reportRunning the 'hello world' example on the website with parcel 1.11.0, I get the following error:
Digging into this a bit more, the issue appears to be in This appears to work correctly with parcel 1.10.0. 💁 Possible SolutionHas someone forgotten to include the lib directory in the npm package? 🌍 Your Environment
|
Beta Was this translation helpful? Give feedback.
Replies: 14 comments
-
Are you using any parcel plugins? Some Parcel plugins are using internal Parcel files and the Parcel update kinda broke those as fs and some other things got split into their own package now |
Beta Was this translation helpful? Give feedback.
-
No I literally just added the 'hello' world example and did |
Beta Was this translation helpful? Give feedback.
-
Try |
Beta Was this translation helpful? Give feedback.
-
Same issue. The problem is with the |
Beta Was this translation helpful? Give feedback.
-
Ah damn than it’s a publishing issue. Sent with GitHawk |
Beta Was this translation helpful? Give feedback.
-
Upgrade your npm version to 8 or above. This fixed my issue. |
Beta Was this translation helpful? Give feedback.
-
Parcel 2 no longer supports Node 6. |
Beta Was this translation helpful? Give feedback.
-
This fixed my issue, too. Can we add this solved result to the "getting started" page? I'm one of who just follow the "hello world" example ,get the error, and find here! Put this solved result in the page and notice next user like "if got this error, update your node to higher than v8!" maybe a good idea. |
Beta Was this translation helpful? Give feedback.
-
Or we could just make sure it gets published with the compiled versions and then it will work for everyone... |
Beta Was this translation helpful? Give feedback.
-
Any chances to have it fixed soon? |
Beta Was this translation helpful? Give feedback.
-
@kjeske Parcel 2 will drop Node 6 support and Parcel 1 has been feature locked for now and only bug fixes get published so I doubt this will get fixed. |
Beta Was this translation helpful? Give feedback.
-
I'm using Parcel and everything is fine when running locally, but I have my site running on Netlify, and when a build is triggered on Netlify it runs on Node 6 and then I get "(node:1198) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: Cannot find module './lib/fs'" ... any ideas to how I can get Nellify to use a new version of Node? |
Beta Was this translation helpful? Give feedback.
-
I am using Node 10.16.0 and issue still pops up for me. |
Beta Was this translation helpful? Give feedback.
-
Hi Guys, I would like to add my two pennies in here. I reinstalled Node and that upgraded it from 6+ to 10+. That appears to have resolved the issue I was experiencing. Installing Node again should help you out if you have an older version of it at the moment: https://nodejs.org/en/download/ Check your version using this command: node -v |
Beta Was this translation helpful? Give feedback.
Parcel 2 no longer supports Node 6.
We recommend updating to Node 10 or newer regardless of which Parcel version you're running to have the best experience.