-
Notifications
You must be signed in to change notification settings - Fork 2
Description
I was getting mxunit to initialize properly but then it would fail the first time I asked it to respond to a change in the watched directory. I would get a node error on the call to test-list.cfm, even though the same call was successful seconds ago. The node error was this:
{ [Error: connect EMFILE] code: 'EMFILE', errno: 'EMFILE', syscall: 'connect' }
There's lots of info about this on stack overflow and it seems to be related to all the files in the watch directory. I learned by running "ulimit -a" that my limit was 256. I then ran "ulimit -n 10000" to bump my limit up to 10k. This fixed the problem, but only for this bash session. You can go here to learn to make the adjustment permanent, at least on mac and linux:
http://stackoverflow.com/questions/34588/how-do-i-change-the-number-of-open-files-limit-in-linux
I've run other watch programs before such as grunt-contrib-watch and not run into this, so I wonder what they do differently. Ultimately it was an OS config setting that caused the issue, but I thought I would post it here because it got in the way of my using mxunit-watch. I'm enjoying using it now, so thanks for creating it.