Using DuckDB with Deno?
nshiab opened this issue · comments
Nael Shiab commented
Hi!
I tried to use duckdb-node with Deno by running this index.ts
.
import duckdb from "npm:duckdb";
const db = new duckdb.Database(":memory:");
But when running deno run -A index.ts
, I get this error:
naelshiab test $ deno run -A index.ts
error: Uncaught (in promise) Error: Cannot find module '/Users/naelshiab/Library/Caches/deno/npm/registry.npmjs.org/duckdb/0.10.1/lib/binding/duckdb.node'
Require stack:
- /Users/naelshiab/Library/Caches/deno/npm/registry.npmjs.org/duckdb/0.10.1/lib/duckdb-binding.js
- /Users/naelshiab/Library/Caches/deno/npm/registry.npmjs.org/duckdb/0.10.1/lib/duckdb.js
- /Users/naelshiab/Library/Caches/deno/npm/registry.npmjs.org/duckdb/0.10.1/lib/duckdb.js
at Function.Module._resolveFilename (node:module:609:15)
at Function.Module._load (node:module:487:27)
at Module.require (node:module:662:19)
at require (node:module:776:16)
at Object.<anonymous> (file:///Users/naelshiab/Library/Caches/deno/npm/registry.npmjs.org/duckdb/0.10.1/lib/duckdb-binding.js:4:15)
at Object.<anonymous> (file:///Users/naelshiab/Library/Caches/deno/npm/registry.npmjs.org/duckdb/0.10.1/lib/duckdb-binding.js:7:4)
at Module._compile (node:module:718:34)
at Object.Module._extensions..js (node:module:732:10)
at Module.load (node:module:643:32)
at Function.Module._load (node:module:524:12)
Is it possible to use DuckDB with Deno?
Thank you very much for your great work.
Nael Shiab commented
It looks like it's a Deno problem, not a DuckDB problem, so closing this issue.
See: denoland/deno#23656