robotjs: Does not work with Electron 3.0.0 please help!

Robotjs worked with the previous version of Electron but not the new version.

Current Behavior

After install when running the app I get this error.

dyld: lazy symbol binding failed: Symbol not found: __ZN2v816FunctionTemplate3NewEPNS_7IsolateEPFvRKNS_20FunctionCallbackInfoINS_5ValueEEEENS_5LocalIS4_EENSA_INS_9SignatureEEEiNS_19ConstructorBehaviorENS_14SideEffectTypeE
  Referenced from: /Users/qashto/Documents/dev/apps/qodemate/node_modules/robotjs/build/Release/robotjs.node
  Expected in: flat namespace

dyld: Symbol not found: __ZN2v816FunctionTemplate3NewEPNS_7IsolateEPFvRKNS_20FunctionCallbackInfoINS_5ValueEEEENS_5LocalIS4_EENSA_INS_9SignatureEEEiNS_19ConstructorBehaviorENS_14SideEffectTypeE
  Referenced from: /Users/qashto/Documents/dev/apps/qodemate/node_modules/robotjs/build/Release/robotjs.node
  Expected in: flat namespace

Context

Trying to use robotjs in my electron based app, Qodemate. Robotjs is the most important module of the app.

Your Environment

  • RobotJS version: 0.5.1
  • Electron version: 3.0.2
  • Node.js version: 10.10.0
  • npm version: 6.4.1
  • Operating System: macOS 10.14 Mojave

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 3
  • Comments: 17

Most upvoted comments

yea it would be great if someone can fix this, i need 3.0.0 for its later version of chromium

Don’t use electron v1.8.6. Update to the node LTS and the latest version of electron and use this: npm rebuild --runtime=electron --target=3.0.8 --disturl=https://atom.io/download/atom-shell --abi=64

@mnakkara ah I was not aware of that documentation, or rather I must’ve been aware of it before but I forgot haha, thank you!

@quinton-ashley did you rebuild robotjs after npm install ? I run npm rebuild --runtime=electron --target=3.0.0 --disturl=https://atom.io/download/atom-shell --abi=64

Robotjs mouse and keyboard are working in MacOS Mojave. You have to provide accessibility permission for the app to control your Mac. If electron Dev builds are running from vscode, you have to give permission to vscode. Usually an alert pops up asking you to give permission. I missed it the first time due to my multiple monitor seup.