Skip to content
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

Tracing causes commands to hang when serialized on 4.1.0 #1253

Open
jaredkrinke opened this issue Nov 19, 2019 · 1 comment
Open

Tracing causes commands to hang when serialized on 4.1.0 #1253

jaredkrinke opened this issue Nov 19, 2019 · 1 comment
Labels

Comments

@jaredkrinke
Copy link

If I enable tracing ("db.on('trace', …)") while a database is serialized ("db.serialize()"), the first command I try to execute appears hangs indefinitely. If either tracing or serialization is off, I don't see this issue.

For example, in the following code, the callback is never called:

var sqlite3 = require('sqlite3');
var db = new sqlite3.Database(":memory:");
db.serialize();
db.on("trace", console.log);
db.run("CREATE TABLE Test (Id INTEGER)", function (err) {
    console.log(`Callback: ${err}`);
});
@daniellockyer
Copy link
Member

Huh - odd! I just ran into the same whilst working on #1267

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants