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

error running cypress open #859

Closed
uptownhr opened this issue Oct 31, 2017 · 8 comments
Closed

error running cypress open #859

uptownhr opened this issue Oct 31, 2017 · 8 comments

Comments

@uptownhr
Copy link

uptownhr commented Oct 31, 2017

On a fresh install of cypress through npm install cypress, and fresh install of Ubuntu, attempting to launch causes an error after the browser opens.

Another ticket - #842 - that was previously open mentioned that my tmp dir may be full. But,
https://ipfs.io/ipfs/QmZsZxNnBXA3Qpvx1z1Q1fgWfb9J5eQajVLkgfybsuwt2X

Filesystem                   Size  Used Avail Use% Mounted on
udev                         5.8G     0  5.8G   0% /dev
tmpfs                        1.2G   17M  1.2G   2% /run
/dev/mapper/ubuntu--vg-root  446G   15G  409G   4% /
tmpfs                        5.9G  665M  5.2G  12% /dev/shm
tmpfs                        5.0M  4.0K  5.0M   1% /run/lock
tmpfs                        5.9G     0  5.9G   0% /sys/fs/cgroup
/dev/sda2                    473M  125M  324M  28% /boot
/dev/sda1                    511M  3.4M  508M   1% /boot/efi
tmpfs                        1.2G   52K  1.2G   1% /run/user/1000

This is also a ls -lah of my /tmp dir

ls /tmp -lah
total 2.1M
drwxrwxrwt 50 root   root   4.0K Oct 30 19:03 .
drwxr-xr-x 24 root   root   4.0K Oct 30 14:41 ..
drwx------  2 uptown uptown 4.0K Oct 30 15:20 .com.google.Chrome.2oaeZL
drwx------  2 uptown uptown 4.0K Oct 30 16:55 .com.google.Chrome.sJB9e3
-rw-------  1 uptown uptown    0 Oct 30 15:19 config-err-H2fXYA
-rw-------  1 uptown uptown    0 Oct 30 16:41 config-err-K6WKua
drwxrwxr-x  2 uptown uptown 4.0K Oct 30 18:56 cypress

I have also tried changing my tmp directory just to be safe and the issue still occurs.

  • Operating System: Ubuntu
  • Cypress Version: 1.0.3
  • Browser Version: 62.0.3202.75

Is this a Feature or Bug?

Bug

Current behavior:

Fails to launch

Desired behavior:

Should launch and run tests

How to reproduce:

  1. npm install cypress
  2. node_modules/.bin/cypress open

Test code:

describe('My First Test', function() {
    it('Does not do much!', function() {
	expect(true).to.equal(false)
    })
})

Additional Info (images, stack traces, etc)

{ Error: watch /home/uptown/Bambee/dev/cyp/package.json ENOSPC
    at exports._errnoException (util.js:1026:11)
    at FSWatcher.start (fs.js:1439:19)
    at Object.fs.watch (fs.js:1466:11)
    at createFsWatchInstance (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:37:15)
    at setFsWatchListener (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:80:15)
    at FSWatcher.NodeFsHandler._watchWithNodeFs (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:228:14)
    at FSWatcher.NodeFsHandler._handleFile (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:255:21)
    at FSWatcher.<anonymous> (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:473:21)
    at /home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/graceful-fs/polyfills.js:287:18
    at FSReqWrap.oncomplete (fs.js:123:15)

  code: 'ENOSPC',
  errno: 'ENOSPC',
  syscall: 'watch /home/uptown/Bambee/dev/cyp/package.json',
  filename: '/home/uptown/Bambee/dev/cyp/package.json' }
Error: watch /home/uptown/Bambee/dev/cyp/package.json ENOSPC
    at exports._errnoException (util.js:1026:11)
    at FSWatcher.start (fs.js:1439:19)
    at Object.fs.watch (fs.js:1466:11)
    at createFsWatchInstance (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:37:15)
    at setFsWatchListener (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:80:15)
    at FSWatcher.NodeFsHandler._watchWithNodeFs (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:228:14)
    at FSWatcher.NodeFsHandler._handleFile (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:255:21)
    at FSWatcher.<anonymous> (/home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/chokidar/lib/nodefs-handler.js:473:21)
    at /home/uptown/Bambee/dev/cyp/node_modules/cypress/dist/Cypress/resources/app/packages/server/node_modules/graceful-fs/polyfills.js:287:18
    at FSReqWrap.oncomplete (fs.js:123:15)
@bahmutov
Copy link
Contributor

We never had this error in our testing, but maybe you can try some solutions described here: https://stackoverflow.com/questions/22475849/node-js-error-enospc

@brian-mann
Copy link
Member

Duplicate of #842

This is a problem on your end of things - I don't believe there's anything to do on Cypress' end. Would reopen if anyone can suggest if there's anything we could do to prevent this.

@uptownhr
Copy link
Author

I'd recommend adding something into the documentation to aid in addressing and explaining the issue.

As of now, I've tried the solutions on 842 and still experiencing the problem. Unable to proceed with Cypress. As I mentioned, I'm a machine that is fresh install of Ubuntu 16.04. I'm using an lvm volume but other than that, I have done nothing from the standard install.

@bahmutov
Copy link
Contributor

bahmutov commented Oct 31, 2017 via email

@uptownhr
Copy link
Author

uptownhr commented Nov 8, 2017

@bahmutov I have a feeling this is actually related to my environment. I'm using docker and volumizing my app dir. It contains node_modules and since cypress is installed as root inside the container, i think this is probably causing file perm issues when i run cypress outside the container.

I tried running on a completely new project and I'm not seeing this issue.

@bahmutov
Copy link
Contributor

bahmutov commented Nov 8, 2017 via email

@brentkirkland
Copy link

Was getting this on a fresh Ubuntu 16.04 install.

Running the following helps:

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

@suulola
Copy link

suulola commented Dec 6, 2019

i also had this same issue on ubuntu 18.04 when i ran the
./cypress open
from node_modules/.bin folder

Suprisingly, it worked when i backed up to the parent directory and ran
./node_modules/.bin/cypress open

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

No branches or pull requests

6 participants