-
-
Notifications
You must be signed in to change notification settings - Fork 814
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
Building sqlite3 for Electron #1163
Comments
I got it working by down grading sqlite3 and Electron till I got a version set that downloaded an accessible binding. This answer lead me to this solution, electron-userland/electron-builder#3643 (comment) "sqlite3": "4.0.6", Which will get you this binding - https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v4.0.6/electron-v3.0-win32-x64.tar.gz I am really not understanding why At the very least if we could have some documentation to show us which versions of |
There does not seem to be a release for electron v4.2 but there is for v4.0 (it should work on v4.2 as well). You should be able to manually use the files of v4.0 and rename them to match v4.2 Generally speaking electron hardly ever makes a release like 4.1 or 4.2 hence they were missed. "I would think that is something that a lot of people would like to have fixed." |
Thanks for your response @kewde
This problem was first noticed when we were using 5.0.0. Do we have a time line of when the new bindings for Electron 5 will be updated? |
Bindings for 5.0.0 are available in release 4.0.8 |
Seems prebuild for electron 5.0.0 not work for electron 5.0.1? |
They did not work for us... We could not get 5.0.0 to work for us either. @linonetwo did 5.0.0 work for you? |
No, I get |
Exactly, The newest version we can get working is, "sqlite3": "^4.0.8", Using those 2 versions will build with the bindings from node-pre-gyp. The issues we are having now are getting encryption working with sqlite3 and sqlcipher. |
@kewde But you said
Why will I install package using: const npm = require('npm')
npm.load({}, (npmErr) => {
if (npmErr) return reject(npmErr)
npm.commands.install(packagePath, packages, (err) => {
if (err) return reject(err)
installStatus.set(name, 'installed').then(resolve)
})
}) Inside an electron v5.0.1 app. |
The automated test suite ran within electron v5 and completed fine for the builds. Please note that electron v5 comes with a lot of changes, including a change in the sandboxing mechanisms. |
Electron 5+ seems to work now.
|
I am trying to use sqlite3 with Electron on Windows but I keep getting an issue when node-gyp appears to be trying to download the correct binding from this URL,
It appears the binding is decalred from here. When I go to this URL in the browser I get this error,
When I check the node_modules/sqlite3 path i can see the folder is there but there is nothing inside the folder.
I am assuming all I am lacking at this point is to get this binding added to my project correctly but I have not been able to find it nor get my npm to download it correctly.
Is the URL to the binding incorrect? If so what is the correct URL that node-gyp should be using? Can I simply download the binding and add it to my project?
Update
I have tested building the sqlite3 module with Electron bindings on,
Vanilla Electron boilerplate using electron-rebuild
Using electron-builder
Using electron-forge
All of these fail with the same issue, the binary does not exist. For some reason it seems that when
node-pre-gyp
tries to download the electron-node binding, it fails.If someone can provide some insight to what the correct binding is and the path to it I would be happy to try and help fix this.
The text was updated successfully, but these errors were encountered: