Comments (10)
Next release will have support for older GLIBC versions (to an extent), otherwise this issue seems pretty stale so I'll close it for now.
from sqlite3.
Try running with deno run -A --unstable index.ts
, as described here:
Since this library depends on the unstable FFI API, you must pass --allow-env, --allow-ffi and --unstable flags. Network and FS permissions are also needed on macOS and Linux to download and cache prebuilt library. It's recommended to just use --allow-all/-A flag since FFI basically gives full access.
from sqlite3.
deno run -A --allow-ffi --unstable index.ts
OK 了
from sqlite3.
If you pass -A, --allow-ffi isn't needed separately.
Apart from that, is it working for you now?
from sqlite3.
At that time, I ran deno run -A --unstable index.ts and also reported an error. I don’t know if it is a cache problem or a problem with our Chinese firewall. So adding --allow-ffi found that the operation was successful.
from sqlite3.
That is quite weird. Try upgrading to Deno 1.30.0 and Deno SQLite3 0.7.3 and run with deno run -A --unstable index.ts
from sqlite3.
Thanks first of all for all the hard work on this! I am unfortunately also experiencing a similar issue.
Testing on WSL on Windows 10, Description: Ubuntu 20.04.5 LTS
deno 1.30.2 (release, x86_64-unknown-linux-gnu)
v8 10.9.194.5
typescript 4.9.4
Running the same code as OP, I get:
$ deno run -A --unstable testsqlite.ts
Download https://github.com/denodrivers/sqlite3/releases/download/0.7.3/libsqlite3.so
error: Uncaught Error: Failed to load SQLite3 Dynamic Library
const error = new Error("Failed to load SQLite3 Dynamic Library");
^
at https://deno.land/x/[email protected]/src/ffi.ts:566:17
Caused by: Error: Could not open library: Could not open library: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (required by /home/johan/.cache/deno/plug/https/github.com/72de3c3884468e55e916274372759c9b1c01127577737e7dfaa5b56718dcdb40.so)
at new DynamicLibrary (deno:ext/ffi/00_ffi.js:368:48)
at Object.dlopen (deno:ext/ffi/00_ffi.js:500:12)
at prepare (https://deno.land/x/[email protected]/plug.ts:117:15)
at async https://deno.land/x/[email protected]/src/ffi.ts:549:12
Where is GLIBC_2.33 coming from and how to install?
from sqlite3.
So upgrading to WSL Ubuntu 22.04.1 LTS solved the problem with that library on 20.04 being an unsupported version.
from sqlite3.
@johanbove yeah, since the libsqlite3.so
file is built on a ubuntu-20.04 runner, that means it's only compatible on computers with a glibc version of 2.33
or higher.
@DjDeveloperr would you accept a PR that changes the GH action workflow to use ubuntu-20.04
instead of ubuntu-latest
, so the libsqlite3.so
is compatible with more servers? Currently ubuntu-latest
points to ubuntu-22.04
, and GLIBC version 2.33
is pretty high and doesn't run in a lot of places. Another option is the ubuntu-18.04
runner, but that's gonna be deprecated in a few months
from sqlite3.
PR would be welcome @asg017 :)
I'll make a new release 0.7.4 later once the patch lands
from sqlite3.
Related Issues (20)
- Bug in Reading Integers HOT 1
- `Failed to load SQLite3 Dynamic Library` – example code not working HOT 6
- SQL statement not support chinese ? HOT 1
- Running in a Web Worker HOT 6
- Different API to node-sqlite3 HOT 5
- Error: Failed to load SQLite3 Dynamic Library HOT 3
- Permission denied when trying to only allow access to a certain ffi path HOT 1
- Error: no such table: fsdir HOT 3
- Compiled binary throws zlib dependency error HOT 10
- SQLITE_ENABLE_UPDATE_DELETE_LIMIT does not work on Linux HOT 2
- Allow configuring libsqlite location HOT 2
- bump sqlite bundled version to 3.45 HOT 1
- Extensions and Callbacks prevent using this library with macOS bundled dylib HOT 6
- "TypeError: Invalid ArrayBuffer pointer, pointer is null" while reading blob column HOT 8
- Standardize SQL database interface for TS/JS HOT 1
- `new Database()` in Web Worker freezing HOT 4
- How to do WHERE col in (:array) ?
- How do I update the database? HOT 9
- Question: How to use array parameters, OR alternative? HOT 2
- jsr can avoid native binary downloads HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sqlite3.