Skip to content

Instantly share code, notes, and snippets.

@tjfontaine
Last active December 28, 2015 19:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tjfontaine/7552600 to your computer and use it in GitHub Desktop.
Save tjfontaine/7552600 to your computer and use it in GitHub Desktop.
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
=== release test-fs-watch-recursive ===
Path: simple/test-fs-watch-recursive
assert.js:98
throw new assert.AssertionError({
^
AssertionError: "testsubdir/watch.txt" == "testsubdir"
at FSWatcher.<anonymous> (/Users/tjfontaine/Development/node/test/simple/test-fs-watch-recursive.js:53:14)
at FSWatcher.EventEmitter.emit (events.js:101:17)
at FSEvent.FSWatcher._handle.onchange (fs.js:1016:12)
Command: out/Release/node /Users/tjfontaine/Development/node/test/simple/test-fs-watch-recursive.js
[00:00|% 100|+ 0|- 1]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
=== release test-fs-watch-recursive ===
Path: simple/test-fs-watch-recursive
assert.js:98
throw new assert.AssertionError({
^
AssertionError: "testsubdir/watch.txt" == "testsubdir"
at FSWatcher.<anonymous> (/Users/tjfontaine/Development/node/test/simple/test-fs-watch-recursive.js:53:14)
at FSWatcher.EventEmitter.emit (events.js:101:17)
at FSEvent.FSWatcher._handle.onchange (fs.js:1016:12)
Command: out/Release/node /Users/tjfontaine/Development/node/test/simple/test-fs-watch-recursive.js
[00:00|% 100|+ 0|- 1]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
=== release test-fs-watch-recursive ===
Path: simple/test-fs-watch-recursive
assert.js:98
throw new assert.AssertionError({
^
AssertionError: "testsubdir/watch.txt" == "testsubdir"
at FSWatcher.<anonymous> (/Users/tjfontaine/Development/node/test/simple/test-fs-watch-recursive.js:53:14)
at FSWatcher.EventEmitter.emit (events.js:101:17)
at FSEvent.FSWatcher._handle.onchange (fs.js:1016:12)
Command: out/Release/node /Users/tjfontaine/Development/node/test/simple/test-fs-watch-recursive.js
[00:00|% 100|+ 0|- 1]: Done
Macintosh-2:node tjfontaine$ python tools/test.py simple/test-fs-watch-recursive
[00:00|% 100|+ 1|- 0]: Done
Macintosh-2:node tjfontaine$
@indutny
Copy link

indutny commented Nov 21, 2013

Will this make it work for you:

diff --git a/deps/uv/src/unix/fsevents.c b/deps/uv/src/unix/fsevents.c
index 3618f46..b780b37 100644
--- a/deps/uv/src/unix/fsevents.c
+++ b/deps/uv/src/unix/fsevents.c
@@ -330,7 +330,7 @@ static int uv__fsevents_create_stream(uv_loop_t* loop, CFArrayRef paths) {
    * 2. FileEvents - fire callback for file changes too (by default it is firing
    *    it only for directory changes).
    */
-  flags = kFSEventStreamCreateFlagNoDefer | kFSEventStreamCreateFlagFileEvents;
+  flags = kFSEventStreamCreateFlagFileEvents;

   /*
    * NOTE: It might sound like a good idea to remember last seen StreamEventId,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment