denodrivers / sqlite3

The fastest and correct SQLite3 module for Deno runtime
https://jsr.io/@db/sqlite
Apache License 2.0
265 stars 22 forks source link

Unsafe pointer create exception #100

Closed 6rube closed 1 year ago

6rube commented 1 year ago

Hi, i tried to use the newest version of sqlite3 and get this error:

image

my code looks like this:

import { Database } from "https://deno.land/x/sqlite3@0.9.1/mod.ts";

const db = new Database("test.db");

db.close();

my runtime args looks like this: deno run -A --unstable test.ts

Did i miss something ?

DjDeveloperr commented 1 year ago

That's weird.. are you on latest deno version? Run deno upgrade just to make sure.

6rube commented 1 year ago

Version is up to date. image

Seems to be a problem with vscode launch.json.

{
    "version": "0.2.0",
    "configurations": [

        {
            "request": "launch",
            "name": "Deno",
            "type": "node",
            "program": "${workspaceFolder}/test.ts",
            "cwd": "${workspaceFolder}",
            "runtimeExecutable": "C:\\Users\\6rube\\.deno\\bin\\deno.EXE",
            "runtimeArgs": [
                "run",
                "-A",
                "--unstable"
            ],
            "attachSimplePort": 9229
        }
    ]
}

It works by running it by hand now.

DjDeveloperr commented 1 year ago

I suspect the --unstable argument is not getting passed correctly, as this error is only reproducible when --unstable is not passed. Either way, seems like it's not a problem in sqlite3 module.

6rube commented 1 year ago

Yes there seems to be an issue with the parsing of the deno extension im using. Thank you again for your Help!