question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

fails with the same error with every version of npm that I have tried

See original GitHub issue

If you are reporting a bug, please fill in below. Otherwise feel free to remove this template entirely.

Can you reproduce the problem with latest npm?

Yes Many errors, especially related to “missing modules”, are due to npm bugs.

If you’re using Windows, follow these instructions to update npm.

If you’re using OS X or Linux, run this to update npm:

npm install -g npm@latest

cd your_project_directory
rm -rf node_modules
npm install

Then try to reproduce the issue again.

Can you still reproduce it?

Description

Expected behaviorreact:create-react-app my-app

Creating a new React app in E:\react\my-app.

Installing packages. This might take a couple minutes. Installing react, react-dom, and react-scripts…

yarn add v0.23.2 info No lockfile found. [1/4] Resolving packages… [2/4] Fetching packages… warning fsevents@1.0.17: The platform “win32” is incompatible with this module. info “fsevents@1.0.17” is an optional dependency and failed compatibility check. Excluding it from installation. [3/4] Linking dependencies… error An unexpected error occurred: “EINVAL: invalid argument, utime ‘E:\react\my-app\node_modules\uglify-js\LICENS E’”. info If you think this is a bug, please open a bug report with the information provided in “E:\react\my-app\yarn-erro r.log”. info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

Aborting installation. yarnpkg add --exact react react-dom react-scripts has failed.

Deleting generated file… package.json Deleting generated file… node_modules Deleting generated file… yarn-error.log Deleting my-app / from E:\react Done.

Tell us what you think should happen. create my-app

Actual behavior

errors out Tell us what actually happens. fails

Environment

Run these commands in the project folder and fill in their results:

  1. npm ls react-scripts (if you haven’t ejected): E:\react `-- (empty)
  2. node -v: react:node -v v8.0.0
  3. npm -v: 5.0.3 react:

Then, specify:

  1. Operating system: Windows 10 x64
  2. Browser and version: Chrome Version 59.0.3071.86 (Official Build) beta (64-bit)

Reproducible Demo

Please take the time to create a new app that reproduces the issue.

Alternatively, you could copy your app that experiences the problem and start removing things until you’re left with the minimal reproducible demo.

(Accidentally, you might get to the root of your problem during that process.)

Push to GitHub and paste the link here.

By doing this, you’re helping the Create React App contributors a big time! Demonstrable issues gets fixed faster. installed latest yarn react:yarn -v yarn install v0.23.2 [1/4] Resolving packages… [2/4] Fetching packages… [3/4] Linking dependencies… [4/4] Building fresh packages…

success Saved lockfile. Done in 0.13s. got the same error. When I booted to Linux Mint it worked perfectly. No luck at all with Windows.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
gaearoncommented, Jun 8, 2017

Create React App is a tiny shell that just calls npm or yarn so it’s not something we can possibly fix. As you can see from the log, something about your drive seems to confuse yarn:

error An unexpected error occurred: "EINVAL: invalid argument, utime 'E:\react\my-app\node_modules\uglify-js\LICENS
E'".

EINVAL is an OS error code, and it looks like the drive somehow caused the filename to contain a newline.

0reactions
jdmallencommented, Mar 14, 2018

Yup, I too ran into this issue. I was trying to run yarn and npm i on an exFAT-formatted drive with an abnormally large cluster size of 2MiB, which caused this issue to occur with regularity (and usually on different packages). Reformatting the drive to NTFS with a 4KiB cluster fixed the problem entirely.

I’m guessing having a node_modules directory that’s taking up several times the space it should on the disk didn’t play nice with npm or yarn.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Common errors | npm Docs
It's most likely a temporary npm registry glitch. Check npm server status and try again later. · If the error persists, perhaps the...
Read more >
How to solve npm install error “npm ERR! code 1”
If your Node.js version is very recent, try downgrading. The stable version 14.16.1 worked.
Read more >
Solved: CLD200 - Manual Deployment keeps erroring out
Solved: I am going through the CLD200 documentation stepwise and building the sample application. It has been working properly, until I get to...
Read more >
NPM install error - Material Design for Bootstrap
Trying to install MDB pro 4.19.2 just downloaded and ran npm install but getting this error of sha512 not matching. Can someone tell...
Read more >
Npm install error(fails) - M220JS - MongoDB
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 ... Hi @SourabhBagrecha, actually I'm facing same issue, tried all ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found