-
Notifications
You must be signed in to change notification settings - Fork 294
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
Error: Error watching file for changes: EMFILE #76
Comments
Hrm, that's worrying, that's coming Jest directly - could you not have watchman installed? |
@orta yep, installing |
👍 interesting, I would have thought watchman was an optional dep |
Have also come across this issue. Care to explain what's causing it? Not familiar with watchman... |
@tinovyatkin & @orta, remember what's up with this one? |
watchman is what powers the jest file watcher, it's not optional - https://github.com/facebook/watchman Someone could send a PR that adds a verification for it being installed |
I see a similar error (but not exactly the same). When run in vscode with this extension, the tests run (and pass), and then it fails to enter watch mode with
I did not have I used the debug option to log the command being run, it's Everything used to work in this repo with the vscode extension; the problems started when I deleted my node_modules directory and reinstalled everything. No idea what might have changed there. |
FWIW, if I set "path to jest" to |
Looks like I've solved this for myself, for now, after reading many of the conflicting reports that Anyways, I had tried removing Next I thought that Jest was trying to watch all the files in Side Note: I believe Thus I tried adding Yup, this now works for me, consistently, with this not set Jest fails to start in watch mode, setting this Jest will start and restart in watch mode successfully "jest": {
"watchPathIgnorePatterns": [
"/node_modules/"
]
} The above is in my There's a few Jest issues that state the above works as a workaround but not the ideal solution, it was supposedly fixed in Jest 24.8.0, but not for everyone and the above workaround is still required So whilst the above works, the consensus appears to be that this is not the "right" solution, if you've complex projects this wouldn't be ideal, so for now, this will work for me and I'll keep an eye on the above linked Jest issue |
The easiest thing would be to install Watchman:
If you don't have brew, do this first:
|
Running `npx jest --watch` threw EMFILE errors in the console, for which [ignoring `node_modules` is a workaround](jest-community/vscode-jest#76 (comment)).
Hello,
Extension shows error at output:
pure
node --harmony
project, no babel anywhere,npm test
=node --harmony node_modules/.bin/jest
The text was updated successfully, but these errors were encountered: