testdotai / appium-classifier-plugin

Apache License 2.0
259 stars 78 forks source link

Error: Cannot find module '../build/Release/canvas.node' #18

Open nishant-shah-social opened 5 years ago

nishant-shah-social commented 5 years ago

when I try to execute my script having driver.FindElement("-custom","ai:plus"); I receive this error:- { Error: Cannot find module '../build/Release/canvas.node' at require (internal/modules/cjs/helpers.js:22:18) at Module.require (internal/modules/cjs/loader.js:637:17) at Function.Module._load (internal/modules/cjs/loader.js:508:25) at Function.Module._resolveFilename (internal/modules/cjs/loader.js:582:15) code: 'MODULE_NOT_FOUND' }

Somewhere I read to upgrade node.js to latest version to get rid of this issue. But, even after upgrading to 10.15.3, getting same error. Any idea why this might be occurring?

Thanks, Nishant Shah

jlipps commented 5 years ago

how did you install the plugin and opencv4nodejs?

NavdeepSingh09 commented 4 years ago

any update on this issue?

NavdeepSingh09 commented 4 years ago

I have the same issue and got below error org.openqa.selenium.WebDriverException: An unknown server-side error occurred while processing the command. Original error: Could not load your custom find module 'ai'. Did you put it somewhere Appium can 'require' it? Original error: Error: The module 'MODULE_PATH/test-ai-classifier/node_modules/canvas/build/Release/canvas.node' was compiled against a different Node.js version using NODE_MODULE_VERSION 72. This version of Node.js requires NODE_MODULE_VERSION 64. Please try re-compiling or re-installing

jlipps commented 4 years ago

did you also uninstall and reinstall the plugin?

NavdeepSingh09 commented 4 years ago

Yes I tried @jlipps