-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
yarn stops with an error and removes ALL files recursively in the current directory #1057
Comments
I can't replicate this on Windows:
Having said that, this looks pretty bad. I don't have a Mac to test the behaviour on Mac OS. |
Just tried replicating this on linux and couldn't:
Yarn version is v0.15.1, node and linux version below:
As with Daniel15 I also don't have a mac machine to test this on, but figured I would add that this seems to be working correctly on linux. |
Can't replicate on macOS Sierra + node 6.8.0 + yarn 0.15.1 either. |
Hmmm... @GrigoryPtashko, can you still replicate the problem if you create a fresh checkout of your repo (https://github.com/GrigoryPtashko/yarn-removes-all-recursively)? I'm very sorry you encountered this bug and would really like to fix it ASAP, but it's pretty hard to find the root cause since we're having difficulty replicating it 😢 What version of Mac OS are you on? |
Yes. Look
I think it is somehow possible to emulate the error and see how can that happen. If I were an author I guess I could understand how can that be possible. And second - no one tried on the OS X El Capitan so far and with the node version as I have.. |
Could not repro on El Capitan with Node 6.7. @GrigoryPtashko can you try It looks like one of the packages that you build removes all the files, which is weird (Ideally of course, packages are built in a sandbox, Nixpkgs has a great setup for that). So if that second mv fixes it, try copying it back and eliminating each package. |
Non of what you proposed did not work. I've removed the deps from the {
"devDependencies": {
"react": "15.3.1"
}
} And here's what happens:
You see that I |
I guess that only leaves the Node version, very weird… Next step is adding On Sat, Oct 15, 2016 at 7:14 PM Grigory Ptashko [email protected]
|
@GrigoryPtashko Have you modified your home directory (e.g. setting $HOME to a different location)? I don't have an OSX machine but the output seems strange. Your terminal shows Could you send the output of the following two commands?
|
@jiripospisil yes, you've noticed that I really made a symlink of ~/Documents/work to ~/work. This is what you see in the output. But nothing changes if I do the same in my $HOME directory without any intermediate directories. I've added the output of two commands as you asked:
|
Can you run |
|
Just to add one more data point;
I wonder, is there any custom setup on this disk? Case sensitive filesystem or something like that? I had all kinds of weird stuff going on due to filesystem case sensitivity with one of my older osx installations. |
Interestingly, it seems as if the file removal is not done by yarn, since, On Sun, Oct 16, 2016 at 12:13 AM Ekin Koc [email protected] wrote:
|
Might have been fixed by #1441 - did you have a .bowerrc somewhere?
|
Fixed, according to last comment. |
Do you want to request a feature or report a bug?
Bug.
What is the current behavior?
That was really unexpected. I've issued
yarn
and and after it stopped with an error I see that all the files in the current directory are removed recursively.Here's the error with which
yarn
stopped and removed all the files:Here's the exact same repo I use for the repro. I was lucky that I tried
yarn
on a newly created project that I was going to turn into a library.Clone the repo https://github.com/GrigoryPtashko/yarn-removes-all-recursively
yarn
and you will find that it deletes all the files.If the current behavior is a bug, please provide the steps to reproduce.
What is the expected behavior?
Please mention your node.js, yarn and operating system version.
The text was updated successfully, but these errors were encountered: