duckdb 0.3.5-dev8.0 → 0.3.5-dev960.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/configure CHANGED
@@ -10,5 +10,5 @@ if [ ! -f "../../scripts/amalgamation.py" ]; then
10
10
  exit 1
11
11
  fi
12
12
 
13
- (cd ../.. && python scripts/amalgamation.py --extended --source=tools/nodejs/src/duckdb.cpp --header=tools/nodejs/src/duckdb.hpp)
14
- (cd ../.. && python scripts/parquet_amalgamation.py && cp src/amalgamation/parquet-amalgamation* tools/nodejs/src/)
13
+ (cd ../.. && python3 scripts/amalgamation.py --extended --source=tools/nodejs/src/duckdb.cpp --header=tools/nodejs/src/duckdb.hpp)
14
+ (cd ../.. && python3 scripts/parquet_amalgamation.py && cp src/amalgamation/parquet-amalgamation* tools/nodejs/src/)
@@ -1,8 +1,6 @@
1
- var os = require('os');
2
1
  var binary = require('@mapbox/node-pre-gyp');
3
2
  var path = require('path');
4
3
  var binding_path = binary.find(path.resolve(path.join(__dirname,'../package.json')));
4
+ var binding = require(binding_path);
5
5
 
6
- // // dlopen is used because we need to specify the RTLD_GLOBAL flag to be able to resolve duckdb symbols
7
- // on linux where RTLD_LOCAL is the default.
8
- process.dlopen(module, binding_path, os.constants.dlopen.RTLD_NOW | os.constants.dlopen.RTLD_GLOBAL)
6
+ module.exports = exports = binding;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "duckdb",
3
3
  "main": "./lib/duckdb.js",
4
- "version": "0.3.5-dev8.0",
4
+ "version": "0.3.5-dev960.0",
5
5
  "description": "DuckDB node.js API",
6
6
  "gypfile": true,
7
7
  "dependencies": {
@@ -363,6 +363,13 @@ struct ExecTask : public Task {
363
363
  }
364
364
  }
365
365
  }
366
+
367
+ void Callback() override {
368
+ auto env = object.Env();
369
+ Napi::HandleScope scope(env);
370
+ callback.Value().MakeCallback(object.Value(), {success ? env.Null() : Napi::String::New(env, error)});
371
+ };
372
+
366
373
  std::string sql;
367
374
  bool success;
368
375
  std::string error;