Modified ignored filter for node_watcher to avoid common exception #91
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
@amasad
This PR updates
node_watcher
to pass the ignore filters to nodejs_walker so that they can be ignored immediately by nodejs_walker rather than later on in the process.This was done because on macOS Sierra something (probably
fs.lstat
) appears to crash when it is searching too many files/directories.This change will allow a fix in Jest to solve issue jestjs/jest#1767, which should also fix Create-React-App issue facebook/create-react-app#871 and possibly React Native issue facebook/react-native#10028.
I have added a new test, to make sure subdirs are being ignored.
Edit: Updated original commit to improve tests and removed old comments
This may also solve issue #72