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

Update sqlite3 so it builds on recent node. #351

Merged
merged 1 commit into from
May 12, 2023
Merged

Conversation

tdaede
Copy link
Collaborator

@tdaede tdaede commented May 3, 2023

This also updates the package-lock.json and version.

@tdaede tdaede requested a review from vibhoothi May 3, 2023 06:03
@tdaede tdaede force-pushed the update_sqlite3 branch from d90c7ef to ccba9e5 Compare May 3, 2023 06:51
Copy link
Collaborator

@vibhoothi vibhoothi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uh-huh,

This is giving me build-time failures when trying on top of #349 [as that would be the case so i tested like that, yet to try standalone]

Debug trace


 ---> f4cc42053396
Step 30/38 : RUN 	cd ${APP_DIR} && 	export PYTHON=python2.7 && 	alias python=python2.7 && 	rm -rf node_modules && 	npm install && 	npm run tsc
 ---> Running in 295c0a2263ae
npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but package-lock.json was generated for lockfileVersion@3. I'll try to do my best with it!
npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated @types/[email protected]: This is a stub types definition. form-data provides its own type definitions, so you do not need this installed.
npm WARN deprecated [email protected]: this library is no longer supported
npm WARN deprecated [email protected]: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated [email protected]: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated @npmcli/[email protected]: This functionality has been moved to @npmcli/fs

> [email protected] install /opt/app/node_modules/iconv
> node-gyp rebuild

make: Entering directory '/opt/app/node_modules/iconv/build'
  CXX(target) Release/obj.target/iconv/src/binding.o
../src/binding.cc:35:11: error: ‘v8::Handle’ has not been declared
   35 | using v8::Handle;
      |           ^~~~~~
../src/binding.cc:65:26: error: ‘Handle’ has not been declared
   65 |   static void Initialize(Handle<Object> obj)
      |                          ^~~~~~
../src/binding.cc:65:32: error: expected ‘,’ or ‘...’ before ‘<’ token
   65 |   static void Initialize(Handle<Object> obj)
      |                                ^
../src/binding.cc: In static member function ‘static void {anonymous}::Iconv::Initialize(int)’:
../src/binding.cc:70:5: error: ‘obj’ was not declared in this scope
   70 |     obj->Set(Nan::New<String>("make").ToLocalChecked(),
      |     ^~~
../src/binding.cc:71:60: error: no matching function for call to ‘v8::FunctionTemplate::GetFunction()’
   71 |              Nan::New<FunctionTemplate>(Make)->GetFunction());
      |                                                            ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6126:46: note: candidate: ‘v8::MaybeLocal<v8::Function> v8::FunctionTemplate::GetFunction(v8::Local<v8::Context>)’
 6126 |   V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
      |                                              ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6126:46: note:   candidate expects 1 argument, 0 provided
../src/binding.cc:73:63: error: no matching function for call to ‘v8::FunctionTemplate::GetFunction()’
   73 |              Nan::New<FunctionTemplate>(Convert)->GetFunction());
      |                                                               ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6126:46: note: candidate: ‘v8::MaybeLocal<v8::Function> v8::FunctionTemplate::GetFunction(v8::Local<v8::Context>)’
 6126 |   V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
      |                                              ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6126:46: note:   candidate expects 1 argument, 0 provided
../src/binding.cc: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE {anonymous}::Iconv::Make(Nan::NAN_METHOD_ARGS_TYPE)’:
../src/binding.cc:84:44: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)’
   84 |     String::Utf8Value from_encoding(info[0]);
      |                                            ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:3135:5: note: candidate: ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::Value>)’
 3135 |     Utf8Value(Isolate* isolate, Local<v8::Value> obj);
      |     ^~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:3135:5: note:   candidate expects 2 arguments, 1 provided
../src/binding.cc:85:42: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)’
   85 |     String::Utf8Value to_encoding(info[1]);
      |                                          ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:3135:5: note: candidate: ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::Value>)’
 3135 |     Utf8Value(Isolate* isolate, Local<v8::Value> obj);
      |     ^~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:3135:5: note:   candidate expects 2 arguments, 1 provided
../src/binding.cc:92:64: error: no matching function for call to ‘v8::ObjectTemplate::NewInstance()’
   92 |         Nan::New<ObjectTemplate>(object_template)->NewInstance();
      |                                                                ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6423:44: note: candidate: ‘v8::MaybeLocal<v8::Object> v8::ObjectTemplate::NewInstance(v8::Local<v8::Context>)’
 6423 |   V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance(Local<Context> context);
      |                                            ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6423:44: note:   candidate expects 1 argument, 0 provided
../src/binding.cc: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE {anonymous}::Iconv::Convert(Nan::NAN_METHOD_ARGS_TYPE)’:
../src/binding.cc:103:49: error: no matching function for call to ‘v8::Value::BooleanValue()’
  103 |     const bool is_flush = info[8]->BooleanValue();
      |                                                 ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2699:8: note: candidate: ‘bool v8::Value::BooleanValue(v8::Isolate*) const’
 2699 |   bool BooleanValue(Isolate* isolate) const;
      |        ^~~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2699:8: note:   candidate expects 1 argument, 0 provided
In file included from /root/.cache/node-gyp/12.16.1/include/node/v8-internal.h:14,
                 from /root/.cache/node-gyp/12.16.1/include/node/v8.h:27,
                 from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2702:51: note: candidate: ‘v8::Maybe<bool> v8::Value::BooleanValue(v8::Local<v8::Context>) const’
 2702 |                 V8_WARN_UNUSED_RESULT Maybe<bool> BooleanValue(
      |                                                   ^~~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8config.h:328:3: note: in definition of macro ‘V8_DEPRECATED’
  328 |   declarator __attribute__((deprecated(message)))
      |   ^~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2702:51: note:   candidate expects 1 argument, 0 provided
 2702 |                 V8_WARN_UNUSED_RESULT Maybe<bool> BooleanValue(
      |                                                   ^~~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8config.h:328:3: note: in definition of macro ‘V8_DEPRECATED’
  328 |   declarator __attribute__((deprecated(message)))
      |   ^~~~~~~~~~
../src/binding.cc:106:47: error: no matching function for call to ‘v8::Value::Uint32Value()’
  106 |     size_t input_start = info[2]->Uint32Value();
      |                                               ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note: candidate: ‘v8::Maybe<unsigned int> v8::Value::Uint32Value(v8::Local<v8::Context>) const’
 2707 |   V8_WARN_UNUSED_RESULT Maybe<uint32_t> Uint32Value(
      |                                         ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note:   candidate expects 1 argument, 0 provided
../src/binding.cc:107:46: error: no matching function for call to ‘v8::Value::Uint32Value()’
  107 |     size_t input_size = info[3]->Uint32Value();
      |                                              ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note: candidate: ‘v8::Maybe<unsigned int> v8::Value::Uint32Value(v8::Local<v8::Context>) const’
 2707 |   V8_WARN_UNUSED_RESULT Maybe<uint32_t> Uint32Value(
      |                                         ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note:   candidate expects 1 argument, 0 provided
../src/binding.cc:109:48: error: no matching function for call to ‘v8::Value::Uint32Value()’
  109 |     size_t output_start = info[5]->Uint32Value();
      |                                                ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note: candidate: ‘v8::Maybe<unsigned int> v8::Value::Uint32Value(v8::Local<v8::Context>) const’
 2707 |   V8_WARN_UNUSED_RESULT Maybe<uint32_t> Uint32Value(
      |                                         ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note:   candidate expects 1 argument, 0 provided
../src/binding.cc:110:47: error: no matching function for call to ‘v8::Value::Uint32Value()’
  110 |     size_t output_size = info[6]->Uint32Value();
      |                                               ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note: candidate: ‘v8::Maybe<unsigned int> v8::Value::Uint32Value(v8::Local<v8::Context>) const’
 2707 |   V8_WARN_UNUSED_RESULT Maybe<uint32_t> Uint32Value(
      |                                         ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2707:41: note:   candidate expects 1 argument, 0 provided
../src/binding.cc:127:72: warning: ‘bool v8::Object::Set(uint32_t, v8::Local<v8::Value>)’ is deprecated: Use maybe version [-Wdeprecated-declarations]
  127 |     rc->Set(0, Nan::New<Integer>(static_cast<uint32_t>(input_consumed)));
      |                                                                        ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/v8-internal.h:14,
                 from /root/.cache/node-gyp/12.16.1/include/node/v8.h:27,
                 from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:3508:22: note: declared here
 3508 |                 bool Set(uint32_t index, Local<Value> value));
      |                      ^~~
/root/.cache/node-gyp/12.16.1/include/node/v8config.h:328:3: note: in definition of macro ‘V8_DEPRECATED’
  328 |   declarator __attribute__((deprecated(message)))
      |   ^~~~~~~~~~
../src/binding.cc:128:73: warning: ‘bool v8::Object::Set(uint32_t, v8::Local<v8::Value>)’ is deprecated: Use maybe version [-Wdeprecated-declarations]
  128 |     rc->Set(1, Nan::New<Integer>(static_cast<uint32_t>(output_consumed)));
      |                                                                         ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/v8-internal.h:14,
                 from /root/.cache/node-gyp/12.16.1/include/node/v8.h:27,
                 from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../../nan/nan.h:60,
                 from ../src/binding.cc:18:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:3508:22: note: declared here
 3508 |                 bool Set(uint32_t index, Local<Value> value));
      |                      ^~~
/root/.cache/node-gyp/12.16.1/include/node/v8config.h:328:3: note: in definition of macro ‘V8_DEPRECATED’
  328 |   declarator __attribute__((deprecated(message)))
      |   ^~~~~~~~~~
make: Leaving directory '/opt/app/node_modules/iconv/build'
make: *** [iconv.target.mk:118: Release/obj.target/iconv/src/binding.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:311:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Linux 4.15.0-158-generic
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /opt/app/node_modules/iconv
gyp ERR! node -v v12.16.1
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok

> [email protected] install /opt/app/node_modules/node-icu-charset-detector
> node-gyp rebuild

make: Entering directory '/opt/app/node_modules/node-icu-charset-detector/build'
  CXX(target) Release/obj.target/node-icu-charset-detector/node-icu-charset-detector.o
../node-icu-charset-detector.cpp:17:29: error: ‘Handle’ in namespace ‘v8’ does not name a template type
   17 |     RegisterClass(const v8::Handle<v8::Object> target) {
      |                             ^~~~~~
../node-icu-charset-detector.cpp:17:35: error: expected ‘,’ or ‘...’ before ‘<’ token
   17 |     RegisterClass(const v8::Handle<v8::Object> target) {
      |                                   ^
../node-icu-charset-detector.cpp:60:5: error: expected ‘;’ at end of member declaration
   60 |     FromBuffer(v8::Handle<v8::Object> bufferObject) {
      |     ^~~~~~~~~~
      |               ;
../node-icu-charset-detector.cpp:60:26: error: expected ‘)’ before ‘<’ token
   60 |     FromBuffer(v8::Handle<v8::Object> bufferObject) {
      |               ~          ^
      |                          )
../node-icu-charset-detector.cpp: In static member function ‘static void CharsetMatch::RegisterClass(int)’:
../node-icu-charset-detector.cpp:33:9: error: ‘target’ was not declared in this scope
   33 |         target->Set(Nan::New(ClassName).ToLocalChecked(), constructorTemplate->GetFunction());
      |         ^~~~~~
../node-icu-charset-detector.cpp:33:92: error: no matching function for call to ‘v8::FunctionTemplate::GetFunction()’
   33 |         target->Set(Nan::New(ClassName).ToLocalChecked(), constructorTemplate->GetFunction());
      |                                                                                            ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../node-icu-charset-detector.cpp:1:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6126:46: note: candidate: ‘v8::MaybeLocal<v8::Function> v8::FunctionTemplate::GetFunction(v8::Local<v8::Context>)’
 6126 |   V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
      |                                              ^~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:6126:46: note:   candidate expects 1 argument, 0 provided
../node-icu-charset-detector.cpp: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE CharsetMatch::New(Nan::NAN_METHOD_ARGS_TYPE)’:
../node-icu-charset-detector.cpp:72:13: error: ‘Handle’ is not a member of ‘v8’
   72 |         v8::Handle<v8::Object> buffer = info[0]->ToObject();
      |             ^~~~~~
../node-icu-charset-detector.cpp:72:30: error: expected primary-expression before ‘>’ token
   72 |         v8::Handle<v8::Object> buffer = info[0]->ToObject();
      |                              ^
../node-icu-charset-detector.cpp:72:32: error: ‘buffer’ was not declared in this scope; did you mean ‘setbuffer’?
   72 |         v8::Handle<v8::Object> buffer = info[0]->ToObject();
      |                                ^~~~~~
      |                                setbuffer
../node-icu-charset-detector.cpp:72:59: error: no matching function for call to ‘v8::Value::ToObject()’
   72 |         v8::Handle<v8::Object> buffer = info[0]->ToObject();
      |                                                           ^
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../node-icu-charset-detector.cpp:1:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2672:44: note: candidate: ‘v8::MaybeLocal<v8::Object> v8::Value::ToObject(v8::Local<v8::Context>) const’
 2672 |   V8_WARN_UNUSED_RESULT MaybeLocal<Object> ToObject(
      |                                            ^~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2672:44: note:   candidate expects 1 argument, 0 provided
In file included from /root/.cache/node-gyp/12.16.1/include/node/v8-internal.h:14,
                 from /root/.cache/node-gyp/12.16.1/include/node/v8.h:27,
                 from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../node-icu-charset-detector.cpp:1:
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2686:31: note: candidate: ‘v8::Local<v8::Object> v8::Value::ToObject(v8::Isolate*) const’
 2686 |                 Local<Object> ToObject(Isolate* isolate) const);
      |                               ^~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8config.h:328:3: note: in definition of macro ‘V8_DEPRECATED’
  328 |   declarator __attribute__((deprecated(message)))
      |   ^~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h:2686:31: note:   candidate expects 1 argument, 0 provided
 2686 |                 Local<Object> ToObject(Isolate* isolate) const);
      |                               ^~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8config.h:328:3: note: in definition of macro ‘V8_DEPRECATED’
  328 |   declarator __attribute__((deprecated(message)))
      |   ^~~~~~~~~~
../node-icu-charset-detector.cpp:78:44: error: ‘CharsetMatch::FromBuffer’ cannot be used as a function
   78 |             CharsetMatch::FromBuffer(buffer)->Wrap(info.This()); // under GC
      |                                            ^
../node-icu-charset-detector.cpp: In function ‘void RegisterModule(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE)’:
../node-icu-charset-detector.cpp:125:33: error: cannot convert ‘Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE’ {aka ‘v8::Local<v8::Object>’} to ‘int’
  125 |     CharsetMatch::RegisterClass(target);
      |                                 ^~~~~~
      |                                 |
      |                                 Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE {aka v8::Local<v8::Object>}
../node-icu-charset-detector.cpp:17:19: note:   initializing argument 1 of ‘static void CharsetMatch::RegisterClass(int)’
   17 |     RegisterClass(const v8::Handle<v8::Object> target) {
      |                   ^~~~~~~~~~~~~~~~
In file included from ../node-icu-charset-detector.cpp:1:
../node-icu-charset-detector.cpp: At global scope:
/root/.cache/node-gyp/12.16.1/include/node/node.h:601:43: warning: cast between incompatible function types from ‘void (*)(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE)’ {aka ‘void (*)(v8::Local<v8::Object>)’} to ‘node::addon_register_func’ {aka ‘void (*)(v8::Local<v8::Object>, v8::Local<v8::Value>, void*)’} [-Wcast-function-type]
  601 |       (node::addon_register_func) (regfunc),                          \
      |                                           ^
/root/.cache/node-gyp/12.16.1/include/node/node.h:635:3: note: in expansion of macro ‘NODE_MODULE_X’
  635 |   NODE_MODULE_X(modname, regfunc, NULL, 0)  // NOLINT (readability/null_usage)
      |   ^~~~~~~~~~~~~
../node-icu-charset-detector.cpp:128:1: note: in expansion of macro ‘NODE_MODULE’
  128 | NODE_MODULE(node_icu_charset_detector, RegisterModule);
      | ^~~~~~~~~~~
In file included from /root/.cache/node-gyp/12.16.1/include/node/node.h:63,
                 from ../node-icu-charset-detector.cpp:1:
/root/.cache/node-gyp/12.16.1/include/node/v8.h: In instantiation of ‘void v8::PersistentBase<T>::SetWeak(P*, typename v8::WeakCallbackInfo<P>::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo<P>::Callback = void (*)(const v8::WeakCallbackInfo<node::ObjectWrap>&)]’:
/root/.cache/node-gyp/12.16.1/include/node/node_object_wrap.h:85:78:   required from here
/root/.cache/node-gyp/12.16.1/include/node/v8.h:10226:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo<node::ObjectWrap>::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<node::ObjectWrap>&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<void>&)’} [-Wcast-function-type]
10226 |                reinterpret_cast<Callback>(callback), type);
      |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/.cache/node-gyp/12.16.1/include/node/v8.h: In instantiation of ‘void v8::PersistentBase<T>::SetWeak(P*, typename v8::WeakCallbackInfo<P>::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo<P>::Callback = void (*)(const v8::WeakCallbackInfo<Nan::ObjectWrap>&)]’:
../../nan/nan_object_wrap.h:65:61:   required from here
/root/.cache/node-gyp/12.16.1/include/node/v8.h:10226:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo<Nan::ObjectWrap>::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<Nan::ObjectWrap>&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<void>&)’} [-Wcast-function-type]
make: Leaving directory '/opt/app/node_modules/node-icu-charset-detector/build'
make: *** [node-icu-charset-detector.target.mk:109: Release/obj.target/node-icu-charset-detector/node-icu-charset-detector.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:311:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Linux 4.15.0-158-generic
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /opt/app/node_modules/node-icu-charset-detector
gyp ERR! node -v v12.16.1
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok

> [email protected] install /opt/app/node_modules/sqlite3
> node-pre-gyp install --fallback-to-build

[sqlite3] Success: "/opt/app/node_modules/sqlite3/lib/binding/napi-v3-linux-glibc-x64/node_sqlite3.node" is installed via remote
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/iconv):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/node-icu-charset-detector):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1

added 298 packages from 366 contributors and audited 304 packages in 10.717s

19 packages are looking for funding
  run `npm fund` for details

found 1 moderate severity vulnerability
  run `npm audit fix` to fix them, or `npm audit` for details

> [email protected] tsc /opt/app
> tsc

node_modules/@types/express-serve-static-core/index.d.ts(104,68): error TS1110: Type expected.
node_modules/@types/express-serve-static-core/index.d.ts(104,77): error TS1005: '}' expected.
node_modules/@types/express-serve-static-core/index.d.ts(104,78): error TS1128: Declaration or statement expected.
node_modules/@types/express-serve-static-core/index.d.ts(104,80): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(106,33): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(106,48): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(107,8): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(113,22): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(113,23): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(113,33): error TS1005: ')' expected.
node_modules/@types/express-serve-static-core/index.d.ts(115,26): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(115,27): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(115,35): error TS1128: Declaration or statement expected.
node_modules/@types/express-serve-static-core/index.d.ts(115,37): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(115,44): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(119,52): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(119,53): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(119,60): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(119,70): error TS1128: Declaration or statement expected.
node_modules/@types/express-serve-static-core/index.d.ts(123,28): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(123,29): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(123,53): error TS1005: '(' expected.
node_modules/@types/express-serve-static-core/index.d.ts(123,55): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(123,62): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(239,41): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(248,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(274,62): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(370,49): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(371,59): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(372,5): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(372,25): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(372,44): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(373,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(378,84): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(393,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(394,14): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(394,29): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(407,20): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(416,28): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(417,45): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(420,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(494,56): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(498,48): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(517,35): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(517,58): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(523,36): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(525,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(531,53): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(571,26): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(577,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(600,24): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(680,76): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(691,20): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(696,46): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(709,46): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(757,40): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(760,22): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(761,51): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(767,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(767,68): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(768,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(769,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(770,13): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(770,68): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(772,43): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(776,48): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(777,44): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(778,47): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(817,40): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(819,54): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(820,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(822,35): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(827,26): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(834,49): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(834,64): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(835,66): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(848,49): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(848,64): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(849,66): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(862,52): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(865,26): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(873,54): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(874,12): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(874,39): error TS1109: Expression expected.
node_modules/@types/express-serve-static-core/index.d.ts(907,38): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(908,36): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(916,72): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(921,20): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(921,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(930,20): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(941,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(944,23): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(948,20): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(948,30): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(948,52): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(952,14): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(952,63): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(953,14): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(954,14): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(969,36): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(971,19): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(983,46): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(997,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(997,60): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1000,23): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1000,46): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1002,9): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1019,16): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1019,38): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1019,70): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1025,12): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1026,12): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1096,53): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1097,12): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1099,25): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1114,52): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1129,16): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1129,29): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1129,46): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1165,18): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1177,18): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1188,17): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1191,18): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1195,31): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1195,48): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1211,16): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1212,33): error TS1005: ';' expected.
node_modules/@types/express-serve-static-core/index.d.ts(1280,1): error TS1160: Unterminated template literal.
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! [email protected] tsc: `tsc`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the [email protected] tsc script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2023-05-03T23_39_01_927Z-debug.log
The command '/bin/sh -c cd ${APP_DIR} && 	export PYTHON=python2.7 && 	alias python=python2.7 && 	rm -rf node_modules && 	npm install && 	npm run tsc' returned a non-zero code: 2

@tdaede
Copy link
Collaborator Author

tdaede commented May 3, 2023

can you try again after running "npm install"

@vibhoothi
Copy link
Collaborator

@tdaede : This is running via Docker Build without Cache, with the upstream Dockerfile
https://github.com/xiph/awcy/blob/master/Dockerfile

The only thing I am suspecting now is the Node version. What is there,

Also update Dockerfile node to v18.

This also updates the package-lock.json and version.

Also updates typescript and removes no-longer-necessary
es6-promises types.
@tdaede tdaede force-pushed the update_sqlite3 branch from ccba9e5 to 12cba20 Compare May 4, 2023 06:29
Copy link
Collaborator

@vibhoothi vibhoothi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now it works,
Amazing, thanks.

@vibhoothi
Copy link
Collaborator

vibhoothi commented May 4, 2023

Packages deprecations warnings on build

For the main server

> cd ${APP_DIR} && 	export PYTHON=python2.7 && 	alias python=python2.7 && 	rm -rf node_modules && 	npm install && 	npm run tsc
npm WARN deprecated [email protected]: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated [email protected]: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated [email protected]: this library is no longer supported
npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated @types/[email protected]: This is a stub types definition. form-data provides its own type definitions, so you do not need this installed.
npm WARN deprecated @npmcli/[email protected]: This functionality has been moved to @npmcli/fs
npm WARN deprecated [email protected]: This version of 'buffer' is out-of-date. You must update to v4.9.2 or newer

For www/*

> cd ${APP_DIR}/www && 	npm install && 	npm run build
npm WARN deprecated @types/[email protected]: This is a stub types definition for Facebook's Immutable (https://github.com/facebook/immutable-js). Facebook's Immutable provides its own type definitions, so you don't need @types/immutable installed!
npm WARN deprecated [email protected]: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
npm WARN deprecated [email protected]: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.

Webpack build warnings

> webpack --mode=development --config config/webpack.config.js

(node:40) [DEP_WEBPACK_DEPRECATION_ARRAY_TO_SET] DeprecationWarning: Compilation.modules was changed from Array to Set (using Array method 'reduce' is deprecated)
(Use `node --trace-deprecation ...` to show where the warning was created)
(node:40) [DEP_WEBPACK_MODULE_ERRORS] DeprecationWarning: Module.errors was removed (use getErrors instead)

Edit: Maybe we should create separate issue to track this.?

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

Successfully merging this pull request may close these issues.

2 participants