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

change event fired with wrong files #376

Closed
valaxy opened this issue Oct 24, 2015 · 2 comments
Closed

change event fired with wrong files #376

valaxy opened this issue Oct 24, 2015 · 2 comments

Comments

@valaxy
Copy link

valaxy commented Oct 24, 2015

For example, I have three files: test.js and test.jsx and test.jsxy

chokidar.watch(__dirname)
    .on('change', function (absoluteFilePath) {
        console.log('change', absoluteFilePath)
    })

When I changed test.js and test.js only, chokidar report all the three files are changed:

change C:\Project\chokidar-bug\test.js
change C:\Project\chokidar-bug\test.jsx
change C:\Project\chokidar-bug\test.jsxy

I don't think the behavior is what I expected.

Test in node v4.1.0 & windows 7 64 & chokidar 1.2.0

@valaxy
Copy link
Author

valaxy commented Oct 24, 2015

By the way, when I tried usePolling: false, it did really fix the problem.
I also found a similar situation #296

@es128
Copy link
Contributor

es128 commented Oct 26, 2015

Yes, this is a dupe of #296, and the situation remains the same as when I said that I don't see how to second-guess the system-level events in order to make it better. add and unlink events I can do things to double check what's actually there, but I have less options for validating a change.

If anyone has any ideas, let me know in the linked thread.

Closing this one as a dupe.

@es128 es128 closed this as completed Oct 26, 2015
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

2 participants