-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
Cannot import sqlite3 via npm and use it #15611
Comments
We don’t have node API support yet. Once this PR lands it will be possible: #13633 |
I just tried this issue with branch for #13633 and the error is the same. I think this might be related to postinstall script or Node GYP |
|
Thanks for reporting @trgwii, it seems to be a regression that we missed. We'll investigate and fix it. Just to be sure, which OS did you check it on? |
Debian 11 x86_64 |
sqlite3 has If I manuall copied that file to appropriate path, then the example in the first comment worked. |
BTW if I hit the commant |
So it seems a matter of running postinstall script to make it work? |
Looks so to me (technically it's |
FYI an alternative module |
Replacing |
@kt3k Good! I'll try it. |
I've just hit what looks to be the same issue with duckdb where I imported it with an npm specifier. When attempting to use the duckdb library I got:
looking in package.json for the library it has a similar scripts section (
as suggested by @kt3k (👍 thanks) I switched to using So it seems that if a module uses an install script to download required binaries for the current platform it doesn't work with deno. I'm currently running:
|
That's correct, it's tracked in #16164 |
Let's continue to track this in #16164 since this is now a postinstall issue and not Node-API. Closing |
I tried to import sqlite3 via npm. As shown below,
Then I got the following error.
I am not sure if this is an error caused by the deno side or not. If anyone else is facing this problem, I would like to know the solution. Thanks!
The text was updated successfully, but these errors were encountered: