-
Notifications
You must be signed in to change notification settings - Fork 3k
ENOENT and ENOTEMPTY while rolling back failed optional dependencies #6043
Comments
I'm suffering from these errors for several days already trying to install gulp-imagemin |
Is there an ETA on a fix? I see it's in progress. |
+1 on the ETA request |
This will be fixed before |
Please backport the fix to 1.4. |
This ought to nail the ENOENT issues we're seeing in #6043, albeit in a somewhat kludgey way. Needs tests, ideally, but this is a tricky one to test for.
This ought to nail the ENOENT issues we're seeing in #6043, albeit in a somewhat kludgey way. Needs tests, ideally, but this is a tricky one to test for.
This ought to nail the ENOENT issues we're seeing in #6043 by deferring all rollback unbuilds to the end of the install process. This also depends on the upgrade to [email protected]. Includes a test with a very racy optional dependency situation. (*wink*)
This ought to nail the ENOENT issues we're seeing in #6043 by deferring all rollback unbuilds to the end of the install process. This also depends on the upgrade to [email protected]. The test lives on master, but wasn't ported to this branch.
@isaacs and I have addressed this issue two ways:
These changes are included in Because
Please do so, and let us know if you're still having problems with this issue. We are reasonably confident we've put a stake through this one's heart, but if you have evidence otherwise, we want to know about it sooner rather than later. |
Hello, i installed yeoman-webapp today and when i run grunt serve, grunt test or grunt it still displays the error:
npm --version is 1.4.28 I tried all the commands i see on #6043 and imagemin/imagemin#53. |
@Chirica-Mugurel The issue you're running into is actually fixed by the resolution to #5920. To get the fix, you'll need to upgrade to |
@kuhnroyal npm is doing what it's supposed to in this case – the optional dependencies failed to install, it warned you, and then it finished running without crashing. Do you have a C compiler installed? All of imagemin's optional dependencies require developer tools to be installed. Also, pasting a screenshot is the least helpful way to get support. It cuts off useful information and isn't searchable (not to mention being hard to read). |
Right, i'll write it next time. |
@kuhnroyal That's an issue for the |
@othiym23, they don't require anything. Only if the pre-built binary doesn't work. Then it'll try and compile if from source. I'm seeing (but don't experiencing it myself) a lot of issues regarding the optional deps. It comes down (I think) to npm running the postinstall scripts before all the dependencies are actually installed, and therefore errors are happening (see the Is this fixed in 2.1.5? It seems like it's still happening in 2.1.0. |
@kevva If you look at the release notes for 2.1.x release, you'll see that all of include patches for race conditions. I don't believe that we've eliminated all of the race conditions within npm, but I do believe we've fixed the ones most developers are ever likely to hit, including all of the problems that were causing problems with The bugs were due to lock contention, packages being written to and read from the cache non-atomically, and @iarna is also reworking the installer's internals right now to make the installer run in discrete stages, in a way that should be more deterministic and less liable to lead to the kinds of race conditions we've spent so much time on lately. It's our hope that this will help us tackle a whole host of issues at once. |
@othiym23, yo, thanks for your answer. Yeah, I know a lot of work were done to fix this, but it seems to fail so randomly at random versions. A few days ago this happened during Travis builds (using npm 1.4.28) but somehow that magically got fixed. Now I'm seeing issues being created where their logs just say I feel kinda bad for just having to advice people to update npm etc lol, but without any real errors there's really not much else I can do. |
Ok, so we managed to track down the issue to a deeply nested dependency relying on a git remote URL which caused npm to fail because of |
@kevva what version of npm did you encounter that with? I recently landed a change that disabled templates altogether, so if you're seeing issues in you git repos, we should take another look at that. |
To add to @kevva's comments, we're starting to run into an increasing numbers of folks being bitten by this but can't reproduce it reliably. e.g 2.1.5 is working fine for me, but on the issue linked above Paul (and outside of that thread, others) are not seeing that build address the problem. |
My guess is this is a permissions issue caused by running |
npm install grunt-imagemin
fails spectacularly on bothmaster
andv1.4
due to npm sometimes simultaneously trying to install and remove packages when optional dependencies fail to install. That makes me sad.See imagemin/imagemin#53 for more details.
The text was updated successfully, but these errors were encountered: