{"action":"created","issue":{"url":"https://api.github.com/repos/nodejs/node/issues/3984","labels_url":"https://api.github.com/repos/nodejs/node/issues/3984/labels{/name}","comments_url":"https://api.github.com/repos/nodejs/node/issues/3984/comments","events_url":"https://api.github.com/repos/nodejs/node/issues/3984/events","html_url":"https://github.com/nodejs/node/issues/3984","id":118376352,"number":3984,"title":"EMFILE error appears in iojs v1.2.0 on Windows","user":{"login":"miklen","id":471576,"avatar_url":"https://avatars.githubusercontent.com/u/471576?v=3","gravatar_id":"","url":"https://api.github.com/users/miklen","html_url":"https://github.com/miklen","followers_url":"https://api.github.com/users/miklen/followers","following_url":"https://api.github.com/users/miklen/following{/other_user}","gists_url":"https://api.github.com/users/miklen/gists{/gist_id}","starred_url":"https://api.github.com/users/miklen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miklen/subscriptions","organizations_url":"https://api.github.com/users/miklen/orgs","repos_url":"https://api.github.com/users/miklen/repos","events_url":"https://api.github.com/users/miklen/events{/privacy}","received_events_url":"https://api.github.com/users/miklen/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/nodejs/node/labels/fs","name":"fs","color":"0052cc"},{"url":"https://api.github.com/repos/nodejs/node/labels/module","name":"module","color":"fbca04"},{"url":"https://api.github.com/repos/nodejs/node/labels/windows","name":"windows","color":"9944dd"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-11-23T13:03:17Z","updated_at":"2015-11-23T19:25:07Z","closed_at":null,"body":"In our Windows build environment we are opening a lot of files through the use of browserify and debowerify. Our build stopped working when we upgraded to the latest NodeJS, with an EMFILE error.\r\n\r\nI reverted back to NodeJS 0.12.7 and the build works again. I started testing the different versions and found that the error started happning on iojs v.1.2.0 (iojs 1.1.0 runs our build with no errors).\r\n\r\nThe error I'm getting is this:\r\n```\r\n{ [Error: EMFILE: too many open files, open 'c:\\Projekter\\GitProjects\\POS\\bower_components\\jqueryui\\.bower.json']\r\n  errno: -4066,\r\n  code: 'EMFILE',\r\n  syscall: 'open',\r\n  path: 'c:\\\\Projekter\\\\GitProjects\\\\POS\\\\bower_components\\\\jquery-ui\\\\.bower.js\r\non',\r\n  details: 'EMFILE: too many open files, open \\'c:\\\\Projekter\\\\GitProjects\\\\POS\\\\bower_components\\\\jquery-ui\\\\.bower.json\\'' }\r\n```\r\n\r\nIn the versions of iojs and nodejs which are throwing the errors, I found that limiting the number of `require` calls in our app made it work again. Leaving out parts of the app is not really an option, so I hope someone can shed some light on this for me here."},"comment":{"url":"https://api.github.com/repos/nodejs/node/issues/comments/159036173","html_url":"https://github.com/nodejs/node/issues/3984#issuecomment-159036173","issue_url":"https://api.github.com/repos/nodejs/node/issues/3984","id":159036173,"user":{"login":"miklen","id":471576,"avatar_url":"https://avatars.githubusercontent.com/u/471576?v=3","gravatar_id":"","url":"https://api.github.com/users/miklen","html_url":"https://github.com/miklen","followers_url":"https://api.github.com/users/miklen/followers","following_url":"https://api.github.com/users/miklen/following{/other_user}","gists_url":"https://api.github.com/users/miklen/gists{/gist_id}","starred_url":"https://api.github.com/users/miklen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miklen/subscriptions","organizations_url":"https://api.github.com/users/miklen/orgs","repos_url":"https://api.github.com/users/miklen/repos","events_url":"https://api.github.com/users/miklen/events{/privacy}","received_events_url":"https://api.github.com/users/miklen/received_events","type":"User","site_admin":false},"created_at":"2015-11-23T19:25:07Z","updated_at":"2015-11-23T19:25:07Z","body":"Thanks - I got it working. And to my surprise, it looks like the issue has been resolved in the current HEAD commit on the master branch. I installed 5.1.0 again to recheck that I get the error in that version, and I do.\r\n\r\nI will try and investigate which commit since 5.1.0 and the HEAD on master fixed the issue."}}