You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Error while Installing react-scripts with create a new project #1200
I get an error after creating new react app. It's say about Error at spawn ENOTDIR
Expected behavior
Project should created and add list of files inside a package. For me it's a first time i'm using it (begginer with ReactJS), so mb something wrong with my settings or anything else related with it.
Actual behavior
Its just fall with an error. CRA can't install react scripts.
Environment
MBP
Run these commands in the project folder and fill in their results:
One thing that looks a bit weird is you're running the command from inside the Trash folder. Is this intentional? I don't know if there's anything preventing that but just curious if you tried creating a project outside of it.
Activity
gaearon commentedon Dec 8, 2016
One thing that looks a bit weird is you're running the command from inside the Trash folder. Is this intentional? I don't know if there's anything preventing that but just curious if you tried creating a project outside of it.
HrudakovSerhii commentedon Dec 8, 2016
Yes, really weird... Now i try to create in non-Trash folder. And again same result:
gaearon commentedon Dec 8, 2016
@fson Looks like Yarn detection code needs a try catch?
gaearon commentedon Dec 8, 2016
I don’t understand why this happens.
Can you give me the output of:
echo $PATHwhich yarncreate-react-app --versionThen could you try to run
npm i -g create-react-app@0.6.0and try again. This way we can tell if it’s a new regression or not.HrudakovSerhii commentedon Dec 8, 2016
Ohh, yes! I forget instal yarn.. Sorry guys, it was my mistake. Now it's okay.
Should i close issue?
gaearon commentedon Dec 8, 2016
Hmm, it still shouldn't fail without Yarn. Yarn is not required for CRA.
I'm going to put
try/catcharound this code and release an update.HrudakovSerhii commentedon Dec 8, 2016
Great! Thank you.
gaearon commentedon Dec 8, 2016
@SerhiiHrudakov Could you still share the output of commands in #1200 (comment)?
HrudakovSerhii commentedon Dec 8, 2016
Then list of files and next:
Is it what you ask?
gaearon commentedon Dec 8, 2016
Sorry, could you run these commands in the terminal:
HrudakovSerhii commentedon Dec 8, 2016
Ohh, sorry. Here it is:
gaearon commentedon Dec 8, 2016
Thanks!
As a matter of experiment, could you remove Yarn and try again with
create-react-app@1.0.1I just released?I just want to make sure the issue is fixed. Feel free to install Yarn again afterwards (it's faster) :-)
HrudakovSerhii commentedon Dec 8, 2016
This is deleting yarn:

Then create new CRA:

And result:

gaearon commentedon Dec 8, 2016
There is a typo in uninstall command so it didn't get uninstalled.
You typed
usinstal, notuninstall.Could you try this again please?
Sorry for bugging you.
HrudakovSerhii commentedon Dec 8, 2016
Ooo...really... Wait a minute please.
HrudakovSerhii commentedon Dec 8, 2016
gaearon commentedon Dec 8, 2016
Hmm, you still have Yarn. Maybe you didn't install it via npm?
Anyway, don't worry, it's not super important. I'm glad it works for you now.