-
-
Notifications
You must be signed in to change notification settings - Fork 144
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
Segmentation Fault on macOS when trying to send keyboard events #98
Comments
Hi @AdrianoFerrari, sorry to see you're running into errors. I do not yet have a particular clue what might have happened, but I'll try to investigate on these issues and report back. |
Thanks. That's what I suspected, though it seems odd that both Travis CI and GitHub Actions run into same error. Another theory I had is that some dependency has been updated since the build had passed, and it's now pulling in a different version of it than it did before. (my impression was that having a "package-lock.json" file, and using |
Hello, this happens for this project and for RobotJS (which is a similar project) starting from Node 12.13 So something has changed in node 12.13 that affects both projects. The solution for anyone who comes to this thread is to use node 12.12 or earlier |
I did spent some time investigating on this issue yesterday evening. The issue persists up until node v13.7.0. I traced the changelog and identified the update to libuv v1.34.1 to solve the issue. Rebuilding node v12.16.0 (lts/erbium) after an update from libuv v1.34.0 to v1.34.1 solves the issue. In summary, node versions which are not yet including libuv |
Update: https://github.com/nodejs/node/tree/v12.16.2-proposal comes with libuv |
Version: 1.3.1
Whenever Travis CI or GitHub Actions on macOS hit the first test that uses nut.js keyboard, I get a segmentation fault:
/Users/travis/.travis/functions: line 113: 6934 Segmentation fault: 11 npm run test
(full Travis log here)
Even going back to my last passing build and re-running it, the same build now fails with a Segmentation fault. Same is true with GitHub actions (see e.g. here).
I played around with moving nut.js calls to keyboard, and each time my tests would fail with a seg fault whenever it hit the first call.
I've been busting my head about this for two days! Any ideas?
For context, all I really want to do is to be able to send keyboard events like "Cmd+S" and "Alt+Cmd+Shift+Y" on macOS from my node.js integration tests. Other libraries have worked for Linux & Windows, but none has worked consistently on macOS.
The text was updated successfully, but these errors were encountered: