electron-userland / electron-spellchecker

Implement spellchecking, correctly
MIT License
237 stars 83 forks source link

Electron Spell Checker rebuild issue. #97

Closed rharish100193 closed 6 years ago

rharish100193 commented 6 years ago

Hi,

I installed electron-spellchecker package and tried a small demo using your example app. Am getting the below error. I followed this blog and tried electron rebuild. But still, it is throwing the same error. Kindly help me resolve this issue.

I followed this blog

Desktop_App/Electron-Spell-Checker/node_modules/@paulcbetts/spellchecker/build/Release/spellchecker.node' was compiled against a different Node.js version using NODE_MODULE_VERSION 48. This version of Node.js requires NODE_MODULE_VERSION 54. Please try re-compiling or re-installing the module (for instance, usingnpm rebuildornpm install). at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:173:20) at Object.Module._extensions..node (module.js:598:18) at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:173:20) at Module.load (module.js:488:32) at tryModuleLoad (module.js:447:12) at Function.Module._load (module.js:439:3) at Module.require (module.js:498:17) at require (internal/module.js:20:19) at Object.<anonymous>

Anrock commented 6 years ago

NODE_MODULE_VERSION 54

Strange, there is no node.js with NODE_MODULES_VERSION according to https://nodejs.org/en/download/releases/

Anyway, this error means, that your installed node.js version doesn't match version of node.js electron is using. Check out output of process.versions.node in your app, install specified node.js version and recompile modules again.

rharish100193 commented 6 years ago

Hi Anrock,

Thanks for the prompt help. It worked with NODE_MODULER_VERSION=57. Is there any other way to make this work with LTS Version i.e. NODE_MODULE_VERSION=48 ?

Thanks in Advance.

Anrock commented 6 years ago

@rharish100193 the only way i can imagine is to downgrade electron back to version when it used 6.x node. However it would be rather old version, i imagine. You can find list of electron releases here: https://github.com/electron/electron/releases

rharish100193 commented 6 years ago

Thanks it worked.