Watchify failing with reactify
I'm using browserify, watchify and reactify in a project, browserify runs perfect, but watchify is failing, I think could be a problem of reactify or watchify, I'm reporting the issue here and reactify github, the watcher is initiated by npm start in package.json as follows:
{...
"scripts": {
"start": "watchify -o js/bundle.js -v -d js/app.js",
"build": "browserify . -t [envify --NODE_ENV production] | uglifyjs -cm > js/bundle.min.js",
"test": "jest"
},
"browserify": {
"transform": [
"reactify",
"envify"
],
...}
Terminal output:
events.js:72
throw er; // Unhandled 'error' event
^
Error: watch ENOSPC
at errnoException (fs.js:1019:11)
at FSWatcher.start (fs.js:1051:11)
at Object.fs.watch (fs.js:1076:11)
at createFsWatchInstance (/miranda_frontend/node_modules/watchify/node_modules/chokidar/lib/nodefs-handler.js:37:15)
at setFsWatchListener (/miranda_frontend/node_modules/watchify/node_modules/chokidar/lib/nodefs-handler.js:80:19)
at EventEmitter.NodeFsHandler._watchWithNodeFs (/miranda_frontend/node_modules/watchify/node_modules/chokidar/lib/nodefs-handler.js:228:14)
at EventEmitter.NodeFsHandler._handleFile (/miranda_frontend/node_modules/watchify/node_modules/chokidar/lib/nodefs-handler.js:255:21)
at EventEmitter.<anonymous> (/miranda_frontend/node_modules/watchify/node_modules/chokidar/lib/nodefs-handler.js:468:21)
at Object.oncomplete (fs.js:107:15)
$ man errno | grep ENOSPC
ENOSPC No space left on device (POSIX.1)
Make sure you have enough free space left on your disk?
That's weird because I have a lot of space on my disk.
@eyscode Weird - looks like a pretty vanilla build. Got anything I can test?
Don't worry. Now, it works perfect, and I didn't do anything, just restarted the computer. I think my PC became crazy for a moment. Whatever, thanks for the help! :+1:
Same issue. only solution is to restart .. and i have a lot of space on my disk
Chiming in to say I have run out of disk space multiple times during development. Very odd since I have lots of space on disk. Only noticed this is Yosemite. Also there are a lot of other factors that might be the root cause for me (eg Photoshop, Chrome).
Quitting terminal and killing finder usually brings my disk space back up.
I had the same issue. Seemed that in my case the error was caused by inotify, it used to many handles .
Use
lsof | awk '{ print $2; }' | sort -rn | uniq -c | sort -rn | head
to check which processes are eating up your handles.