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

Module did not self-register (Windows Server 2012) #103

Closed
deathgrindfreak opened this issue Feb 28, 2018 · 3 comments
Closed

Module did not self-register (Windows Server 2012) #103

deathgrindfreak opened this issue Feb 28, 2018 · 3 comments

Comments

@deathgrindfreak
Copy link

I'm having a bit of trouble getting better-sqlite3 to run with my electron app. From what I've seen in a few places, they've suggested that the better_sqlite3.node is missing a .dll file somewhere, but after messing around with it a bit, it doesn't seem to help (adding .dlls that is). This is happening when I'm running the mocha tests by the way, so it should be occurring when the module is first required.

Also, I should mention that I've received the "Error: The specified module could not be found." error as well, if that helps at all.

PS E:\omega-electron> yarn run build
yarn run v1.5.1
$ project-core build --outdir=app
[info] clean
[info] assemble:copy
[info] assemble:source
[info] test:run
E:\omega-electron\node_modules\bindings\bindings.js:88
throw e
^

Error: Module did not self-register.
at Object.Module._extensions..node (module.js:672:18)
at Module.load (module.js:556:32)
at tryModuleLoad (module.js:499:12)
at Function.Module._load (module.js:491:3)
at Module.require (module.js:587:17)
at require (internal/module.js:11:18)
at bindings (E:\omega-electron\node_modules\bindings\bindings.js:81:44)
at Object. (E:\omega-electron\node_modules\better-sqlite3\lib\database.js:4:40)
at Module._compile (module.js:643:30)
at Object.Module._extensions..js (module.js:654:10)
at Module.load (module.js:556:32)
at tryModuleLoad (module.js:499:12)
at Function.Module._load (module.js:491:3)
at Module.require (module.js:587:17)
at require (internal/module.js:11:18)
at Object. (E:\omega-electron\node_modules\better-sqlite3\index.js:2:18)
at Module._compile (module.js:643:30)
at Object.Module._extensions..js (module.js:654:10)

@JoshuaWise
Copy link
Member

JoshuaWise commented Mar 1, 2018

Electron is quite the beast. Almost all issues that come up with installing better-sqlite3 are with people using Electron on Windows, and each time it seems to be something different. Personally I don't use Electron so I've relied on the community to resolve those issues as they come up, which has been productive so far. I haven't seen this particular issue, but it appears to be saying that something went wrong during the compilation process, so my advice is to rm -rf node_modules and rm package-lock.json (or any other lock files you have) and try reinstalling.

If you or someone else is able to resolve the issue please post it here so others with the same problem can be helped.

@deathgrindfreak
Copy link
Author

Sounds good, I appreciate the reply. Personally I'm not a fan of electron, but have to use it for work unfortunately :(

@JoshuaWise
Copy link
Member

closed in favor of #126

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

No branches or pull requests

2 participants