-
Notifications
You must be signed in to change notification settings - Fork 62
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
Keep getting ENOTEMPTY error. Unable to delete directories. #34
Comments
I have the same problem. (same system information) |
In addition to this I also tried |
This seems related to isaacs/rimraf#25 |
But @shama we are not creating files are we? That issue was
It works about 20% of the time with no issues. After some investigation, mostly just changed to |
I had the same problem; but it seems it was due to the fact I had an explorer window opened in the directory I was trying to delete. Could it be that you are in the same situation ? |
@mlarcher Nope I tried closing all explore windows. Could be Anti-Virus maybe... |
I confirm that not having an explorer opened on the folder is not always enough to fix the issue. I believe this is due to an issue in rimraf pointed out in isaacs/rimraf#25 which also affects other packages (like Medium/phantomjs#108 for example) |
@Saturate Are you using file watcher ? if yes then can you post your watch task ? |
Yes I am, but I am not watching my dist folder.
|
I was suspecting that you are accidently watching some file in dist. If that's not the case, does you manual compilation(build) and clean(using grunt clean) work all the time ? |
It does not work all the time, but it's extremely rare it doesn't work, so it's not that annoying anymore. It's on a VM machine with no Anti-Virus. |
I had the same problem today. The problem was I listened to the wrong 'end' event (event from the response instead of the pipe). Changed this:
...to this:
...and it worked :) (the callback runs the clean task) Hope it helps anyone. |
I was Dropbox in my case. |
This is working for me:
As long as you don't mind the directories sticking around. |
Also happens when you have a grunt server up. Just stop the server and try to run the test again. (Reproduced on Windows 8) |
HI, i had this error and solve closing all windows explorer window. My task is: |
@KyleMerritt Yeah, it works for me. |
This seems to be related to https://code.google.com/p/tortoisegit/issues/detail?id=623. Ofcause this can be caused by other processes, but it is confirmed that this particular process can be very troublesome when grunt-cleaning: |
I have the same problem and I think the problem was Windows 7. The same gulpfile on Windows 8 works as expected. |
Same problem, my issue was Dropbox. I had to pause syncing before cleaning. |
Thanks a lot mlarcher. I couldn't build my project until reading your comment. ...Windows :( |
In Windows this is related to windows path 255 character limit. When you have node modules that are nested deeply the windows path exceeds its limit. If you were to delete the directory by hand in the explorer window you would see the exception triggered and you get a dialog that says something like "the path is too long do you want to proceed with permanently deleting this". When fired from grunt this exception issues an error and grunt stops. I've been able to somewhat mitigate this issue by identifying problematic node modules and deleting the node_modules directory in those first. clean: { |
I have the same problem on Ubuntu14.04 but following way I have solved it.
|
I've solved issue for cordova plugins and platforms, by changings like this was: platforms: ['platforms'] change to: + platforms: {
+ files:[
+ {
+ dot:true,
+ src:['platforms/**/*.*', 'platforms/*','platforms']
+ }
+ ]
+ } |
To anyone bumping into this - your del task needs to complete before doing other stuff. Your log needs to look similar to this: [23:09:30] Starting 'build'... You can solve the situation with run-sequence module for example:
|
Some files are being using by another program may cause this problem. |
@bolora In my case it was the same as yours. Thank you. |
In my case, unit test was running hence could not delete the files being accessed by karma runner. |
I am having trouble deleting my dirs when running
grunt-contrib-clean
I get this outputThis is my grunt config:
Is there anything that I can do to fix this issue?
System information
The text was updated successfully, but these errors were encountered: