Open jingpengju391 opened 2 months ago
The same issue on linux
Just stumbled over this on linux. Here's a quick workaronud (comment in #1782 helped to find this):
node_modules/sqlite3/package.json
(wherever you have it installed) "binary": {
"napi_versions": [
3,
6
]
},
As a result it will reference "v6" and the prebuilt binary is downloaded just fine.
So I'm not sure what exactly is going on, but looks like (for some reason) this napi_verions
array is concatenated to get to "36", which leads to the "v36" in the link, which breaks the prebuilt binary download.
Just stumbled over this on linux. Here's a quick workaronud (comment in #1782 helped to find this):
- locate
node_modules/sqlite3/package.json
(wherever you have it installed)- locate this part:
"binary": { "napi_versions": [ 3, 6 ] },
- remove the line with "3" in it
As a result it will reference "v6" and the prebuilt binary is downloaded just fine.
So I'm not sure what exactly is going on, but looks like (for some reason) this
napi_verions
array is concatenated to get to "36", which leads to the "v36" in the link, which breaks the prebuilt binary download.
i had the same problem and this seems to fix it for me, i only had it in windows, didn't have it in my linux laptop.
The same issue on linux
when you use npm (>=5) or yarn, patch-package created by the patch package will automatically and elegantly resolve the issue
pnpm can be used with patch & patch-commit resolve the issue
according to @isozar46 patch package
Issue Summary
prebuild-install http request GET https://github.com/TryGhost/node-sqlite3/releases/download/v5.1.7/sqlite3-v5.1.7-napi-v36-win32-x64.tar.gz
Steps to Reproduce
where is sqlite3-v5.1.7-napi-v36-win32-x64.tar.gz!!!
Version
v5.1.7
Node.js Version
v20.15.1
How did you install the library?
pnpm