Skip to content

Unhandled 'error' event with json-server --watch #361

@theshem

Description

@theshem

I'm having an issue with --watch option, it ends up with an Unhandled 'error' event error and it stops. Any ideas?

json-server -w db.json

I got:

{^_^}/ hi!

Loading db.json
Done

Resources
http://localhost:3000/users

Home
http://localhost:3000

Type s + enter at any time to create a snapshot of the database
Watching...

events.js:160
throw er; // Unhandled 'error' event
^

Error: watch node_modules/custom-event/.travis.yml ENOSPC
at exports._errnoException (util.js:1036:11)
at FSWatcher.start (fs.js:1429:19)
at Object.fs.watch (fs.js:1456:11)
at createFsWatchInstance (/home/hashem/.nvm/versions/node/v6.6.0/lib/node_modules/json-server/node_modules/chokidar/lib/nodefs-handler.js:37:15)
at setFsWatchListener (/home/hashem/.nvm/versions/node/v6.6.0/lib/node_modules/json-server/node_modules/chokidar/lib/nodefs-handler.js:80:15)
at FSWatcher.NodeFsHandler._watchWithNodeFs (/home/hashem/.nvm/versions/node/v6.6.0/lib/node_modules/json-server/node_modules/chokidar/lib/nodefs-handler.js:228:14)
at FSWatcher.NodeFsHandler._handleFile (/home/hashem/.nvm/versions/node/v6.6.0/lib/node_modules/json-server/node_modules/chokidar/lib/nodefs-handler.js:255:21)
at FSWatcher. (/home/hashem/.nvm/versions/node/v6.6.0/lib/node_modules/json-server/node_modules/chokidar/lib/nodefs-handler.js:473:21)
at FSReqWrap.oncomplete (fs.js:123:15)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions