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

node 12.13: error: too few arguments to function call, single argument 'context' was not specified #54

Open
loretoparisi opened this issue Nov 19, 2019 · 0 comments

Comments

@loretoparisi
Copy link

loretoparisi commented Nov 19, 2019

I'm installing with

$ node --version
v12.13.0
$ npm --version
6.13.1

npm complains that

In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:256:59: error: too few arguments to function call, single argument 'context' was not specified

full logging

> [email protected] install /Users/loretoparisi/Documents/Projects/node-sdk/node_modules/node-svm
> node-gyp rebuild

  CXX(target) Release/obj.target/addon/src/libsvm/svm.o
  CXX(target) Release/obj.target/addon/src/addon.o
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:88:96: error: too few arguments to function call, single argument 'context' was not specified
            svm_params->svm_type = Nan::Get(obj, svm_type_name).ToLocalChecked()->IntegerValue();
                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:101:84: error: too few arguments to function call, single argument 'context' was not specified
                svm_params->C = Nan::Get(obj, str_c).ToLocalChecked()->NumberValue();
                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:110:86: error: too few arguments to function call, single argument 'context' was not specified
                svm_params->nu = Nan::Get(obj, str_nu).ToLocalChecked()->NumberValue();
                                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:118:90: error: too few arguments to function call, single argument 'context' was not specified
                svm_params->p = Nan::Get(obj, str_epsilon).ToLocalChecked()->NumberValue();
                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:125:101: error: too few arguments to function call, single argument 'context' was not specified
            svm_params->kernel_type = Nan::Get(obj, str_kernel_type).ToLocalChecked()->IntegerValue();
                                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:137:95: error: too few arguments to function call, single argument 'context' was not specified
                svm_params->degree = Nan::Get(obj, str_degree).ToLocalChecked()->IntegerValue();
                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:147:92: error: too few arguments to function call, single argument 'context' was not specified
                svm_params->gamma = Nan::Get(obj, str_gamma).ToLocalChecked()->NumberValue();
                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:156:88: error: too few arguments to function call, single argument 'context' was not specified
                svm_params->coef0 = Nan::Get(obj, str_r).ToLocalChecked()->NumberValue();
                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:162:77: error: too few arguments to function call, single argument 'context' was not specified
                Nan::Get(obj, str_cache_size).ToLocalChecked()->NumberValue() :
                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:168:70: error: too few arguments to function call, single argument 'context' was not specified
                Nan::Get(obj, str_eps).ToLocalChecked()->NumberValue() :
                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:175:65: error: no matching member function for call to 'BooleanValue'
                !Nan::Get(obj, str_shrinking).ToLocalChecked()->BooleanValue() ? 0 : 1;
                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2603:8: note: candidate function not viable: requires single argument 'isolate', but no arguments
      were provided
  bool BooleanValue(Isolate* isolate) const;
       ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2606:51: note: candidate function not viable: requires single argument 'context', but no
      arguments were provided
                V8_WARN_UNUSED_RESULT Maybe<bool> BooleanValue(
                                                  ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:181:66: error: no matching member function for call to 'BooleanValue'
                Nan::Get(obj, str_probability).ToLocalChecked()->BooleanValue() ? 1 : 0;
                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2603:8: note: candidate function not viable: requires single argument 'isolate', but no arguments
      were provided
  bool BooleanValue(Isolate* isolate) const;
       ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2606:51: note: candidate function not viable: requires single argument 'context', but no
      arguments were provided
                V8_WARN_UNUSED_RESULT Maybe<bool> BooleanValue(
                                                  ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:196:71: error: no matching member function for call to 'ToObject'
            setParameters(Nan::Get(obj, str_params).ToLocalChecked()->ToObject());
                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2576:44: note: candidate function not viable: requires single argument 'context', but no
      arguments were provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Object> ToObject(
                                           ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2590:31: note: candidate function not viable: requires single argument 'isolate', but no
      arguments were provided
                Local<Object> ToObject(Isolate* isolate) const);
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:212:80: error: too few arguments to function call, single argument 'context' was not specified
            new_model->l = Nan::Get(obj, str_l).ToLocalChecked()->IntegerValue();
                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:216:94: error: too few arguments to function call, single argument 'context' was not specified
            new_model->nr_class = Nan::Get(obj, str_nr_class).ToLocalChecked()->IntegerValue();
                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:228:41: warning: 'Get' is deprecated: Use maybe version [-Wdeprecated-declarations]
                Local<Value> elt = rho->Get(i);
                                        ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:3461:3: note: 'Get' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version", Local<Value> Get(uint32_t index));
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:230:54: error: too few arguments to function call, single argument 'context' was not specified
                new_model->rho[i] = elt->NumberValue();
                                    ~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:241:48: warning: 'Get' is deprecated: Use maybe version [-Wdeprecated-declarations]
                    Local<Value> elt = labels->Get(i);
                                               ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:3461:3: note: 'Get' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version", Local<Value> Get(uint32_t index));
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:243:61: error: too few arguments to function call, single argument 'context' was not specified
                    new_model->label[i] = elt->IntegerValue();
                                          ~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:254:58: warning: 'Get' is deprecated: Use maybe version [-Wdeprecated-declarations]
                    Local<Value> elt = nbSupportVectors->Get(i);
                                                         ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:3461:3: note: 'Get' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version", Local<Value> Get(uint32_t index));
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:256:59: error: too few arguments to function call, single argument 'context' was not specified
                    new_model->nSV[i] = elt->IntegerValue();
                                        ~~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2609:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:268:47: warning: 'Get' is deprecated: Use maybe version [-Wdeprecated-declarations]
                    Local<Value> elt = probA->Get(i);
                                              ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:3461:3: note: 'Get' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version", Local<Value> Get(uint32_t index));
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:270:60: error: too few arguments to function call, single argument 'context' was not specified
                    new_model->probA[i] = elt->NumberValue();
                                          ~~~~~~~~~~~~~~~~ ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:2608:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/addon.cc:3:
../src/node-svm/node-svm.h:282:47: warning: 'Get' is deprecated: Use maybe version [-Wdeprecated-declarations]
                    Local<Value> elt = probB->Get(i);
                                              ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8.h:3461:3: note: 'Get' has been explicitly marked deprecated here
  V8_DEPRECATED("Use maybe version", Local<Value> Get(uint32_t index));
  ^
/Users/loretoparisi/Library/Caches/node-gyp/12.13.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
5 warnings and 20 errors generated.
make: *** [Release/obj.target/addon/src/addon.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:210:5)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Darwin 18.6.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/loretoparisi/Documents/Projects/node-sdk/node_modules/node-svm
gyp ERR! node -v v12.13.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok 
@loretoparisi loretoparisi changed the title node 12: error: too few arguments to function call, single argument 'context' was not specified node 12.13: error: too few arguments to function call, single argument 'context' was not specified Nov 19, 2019
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

No branches or pull requests

1 participant