Skip to content
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

Windows 7 almost everytime on change file - ENOTEMPTY, directory not empty ' #232

Closed
denieler opened this issue Feb 5, 2015 · 18 comments
Closed

Comments

@denieler
Copy link

denieler commented Feb 5, 2015

Hi!
I'm trying to work with Ember-CLI and when I execute

"ember server"

in my console using "Run As Administrator". It execute correct, but when I change any file, during watch operation it throws error:

"file changed templates\application.hbs
ENOTEMPTY, directory not empty '{path}\tmp\funnel-dest_T8wFIP.tmp'
Error: ENOTEMPTY, directory not empty '{path}\tmp\funnel-dest_T8wFIP.tmp'
at Object.fs.rmdirSync (fs.js:612:18)
at rmkidsSync ({path}\node_modules\ember-cli\node_modules\rimraf\rimraf.js:247:11)
at rmdirSync ({path}\node_modules\ember-cli\node_modules\rimraf\rimraf.js:237:7)
at fixWinEPERMSync ({path}\node_modules\ember-cli\node_modules\rimraf\rimraf.js:150:5)
at Function.rimrafSync [as sync]({path}node_modulesember-clinode_modulesrimrafrimraf.js:216
:26)
at Funnel.cleanup ({path}\node_modules\ember-cli\node_modules\broccoli-funnel\index.js:96:19)
at $$$internal$$tryCatch ({path}\node_modules\ember-cli\node_modules\rsvp\dist\rsvp.js:490:16)
at $$$internal$$invokeCallback ({path}\node_modules\ember-cli\node_modules\rsvp\dist\rsvp.js:502:
17)
at {path}\node_modules\ember-cli\node_modules\rsvp\dist\rsvp.js:1096:13
at Object.$$rsvp$asap$$flush [as _onImmediate]({path}node_modulesember-clinode_modulesrsvpd
istrsvp.js:1581:9)"

I've turned off Index Options, Windows Defender and nothing changed. What could happened?

Thank you!

P.S. I'm using last ember-cli package version - 0.1.7

@stefanpenner
Copy link
Contributor

is your text-editor observing tmp ? (there is a plan to move tmp to the system tmp, which hopefully will help mitigate)

@denieler
Copy link
Author

denieler commented Feb 5, 2015

I'm using WebStorm 9 and Bracer, and in both IDEs same problem

@stefanpenner
Copy link
Contributor

I'm using WebStorm 9 and Bracer, and in both IDEs same problem

i believe both of these watch the whole project tree by default. WebStorm has a way to disable watching tmp. I suspect the other does as well. If you do this you will likely no longer have any issues.

We can blame poor FS choices of windows. Luckily the final solution of moving to system tmp dir will mitigate most of these issues :)

@denieler
Copy link
Author

denieler commented Feb 5, 2015

Yes, I've tried to disable tmp folder in WebStorm, but it seems that has no effect. But I'll try to do it more carefully. Write if it will take effect.

@denieler
Copy link
Author

denieler commented Feb 6, 2015

Hi, guys! I've tried to exclude tmp folder from my WebStorm project, make some experiments without using WebStorm. Just execute "ember server" in cmd, that run as administrator and tried to change file using just Notepad. But still problem reproduсeable. What can be reason for that? Antivirus is not causing problems, Index Options were changed, like recommended in Ember-CLI documentation. Thank you for help!

@martinthogersen
Copy link

I'm having the same problem. I'm using SublimeText 2, and I've excluded the tmp dir.
I've also made changes for Microsoft Security Essentials and disabled Windows search index for the tmp directory. Any more suggestions?

The problem appears very often (maybe every third time I'm saving a file).

@johnnyshields
Copy link

Symptom-wise this looks the same as this issue from Ember Browserify ef4/ember-browserify#17, which was fixed in the most recent version.

@martinthogersen
Copy link

Any updates on this issue?

@joliss
Copy link
Member

joliss commented Mar 21, 2015

I opened a new issue on rimraf: isaacs/rimraf#72

@martinthogersen
Copy link

Thank you! 👍

@denieler
Copy link
Author

Thank you for analysis!
On Mar 21, 2015 11:59 PM, "Martin Thøgersen" notifications@github.com
wrote:

Thank you! [image: 👍]


Reply to this email directly or view it on GitHub
#232 (comment).

@timohermans
Copy link

I just want to comment the fix that worked for our entire team. It was actually proposed here npm/npm#7552 by miguelmota. Just perform the following commands:

rm -rf node_modules bower_components dist tmp
npm install ember-cli --save-dev
npm install
bower install

Make sure that the first command is repeated until the entire tmp folder is gone. After this, enjoy your fast, not breaking build

@blisst
Copy link

blisst commented Jun 18, 2015

The above @temo44 solution did not work for me....

@timohermans
Copy link

I forgot one step actually. It's that you should move your project to a different partition than the c: Drive. Somehow our windows defender exclusion trick didn't work for c: Drive folders

@blisst
Copy link

blisst commented Jul 3, 2015

I have found an interesting issue however, which might be related. I am wondering if somehow some npm module related to Broccoli does not have symlinking permissions?

I am on Windows 7.

I installed npm can-symlink and it told me that I did not have permissions to create symlinks DESPITE the fact that mklink works fine in an Admin command window.

@flucivja
Copy link

flucivja commented Sep 4, 2015

Hi guys, I am also having the ENOTEMPTY errors and long time builds (60+s) with simple Ember CLI app running on Windows 7 and I can't turn off antivirus scanning nor to run command line as admin due to company security policy. Do you have some solution to those guys who can't just simply setup their machines as they want (mainly security staff like admin rights and antiviruses)?

@stefanpenner
Copy link
Contributor

@flucivja actually. Yes, we have been hard at work at more performant internals. We should have something to show in the next few weeks.

Also in the interim, be sure to following the windows instructions on the website closely.

@stefanpenner
Copy link
Contributor

We have done quite a-bit of windows work. Especially with 1.0.

If the problem still arises, please provide a concise runnable example and we reopen and debug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants