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

Error: Error watching file for changes: EMFILE when running test on new Create React App #872

Closed
robbie-hinman opened this issue Mar 14, 2018 · 1 comment

Comments

@robbie-hinman
Copy link

Firstly, thank you for such a great tool!

Posting this because we are getting the following error when running either yarn test or npm test:

2018-03-14 16:23 node[5933] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2018-03-14 16:23 node[5933] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
events.js:183
throw er; // Unhandled 'error' event
^

Error: Error watching file for changes: EMFILE
at _errnoException (util.js:1022:11)
at FSEvent.FSWatcher._handle.onchange (fs.js:1351:9)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

The steps to reproduce are:

  1. Using node version 8.9.4... (also seen in 8.8.1, and 7.7.1)
  2. create a brand new Create-react-app (currently this means installing react-scripts 1.1.1)
  3. run yarn test (observe no issues)
  4. run yarn add react-styleguidist
  5. run yarn test (observe above error)

I have a demo repo setup with state after step 4 here. This does not fork the example repo since the issue is using styleguidist with CRA, which the demo repo does not include.

I am on mac (10.12.6) and my yarn version is 1.3.2.

@robbie-hinman
Copy link
Author

This looks like a Jest issue according to: facebook/create-react-app#871

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

1 participant