Closed calzoneman closed 6 years ago
DeprecationWarning comes from mysql
: https://github.com/mysqljs/mysql/issues/2003
https://github.com/calzoneman/sync/commit/125a781cc7a1127d9da92d88b265050a52f97bfa makes the necessary dependency changes for it to build and run (disregarding the deprecation warning).
Does not build for me on Node.js 10, though I'm not sure if it's supposed to or not. Judging from your latest comment, it should build and run, but I don't know if it's still a WIP or not.
Downgrading node to node-v8.11.3
build and runs fine.
root@server:/home/user/sync# node --version
v10.4.1
root@server:/home/user/sync# npm --version
6.1.0
CXX(target) Release/obj.target/cytubefilters/src/jsfilterlist.o
In file included from ../../nan/nan.h:190:0,
from ../src/jsfilterlist.cc:2:
../../nan/nan_maybe_43_inl.h: In function ‘Nan::Maybe<bool> Nan::ForceSet(v8::Local<v8::Object>, v8::Local<v8::Value>, v8::Local<v8::Value>, v8::PropertyAttribute)’:
../../nan/nan_maybe_43_inl.h:88:15: error: ‘class v8::Object’ has no member named ‘ForceSet’
return obj->ForceSet(GetCurrentContext(), key, value, attribs);
^~~~~~~~
In file included from ../src/jsfilterlist.cc:2:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:817:60: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, func, argc, argv);
^
In file included from ../src/jsfilterlist.cc:1:0:
/root/.node-gyp/10.4.1/include/node/node.h:172:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.1/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/jsfilterlist.cc:2:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::String>, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:831:62: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::String>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, symbol, argc, argv);
^
In file included from ../src/jsfilterlist.cc:1:0:
/root/.node-gyp/10.4.1/include/node/node.h:165:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.1/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/jsfilterlist.cc:2:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, const char*, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:845:62: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, const char*, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, method, argc, argv);
^
In file included from ../src/jsfilterlist.cc:1:0:
/root/.node-gyp/10.4.1/include/node/node.h:158:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.1/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/jsfilterlist.cc:2:0:
../../nan/nan.h: In member function ‘v8::Local<v8::Value> Nan::Callback::Call_(v8::Isolate*, v8::Local<v8::Object>, int, v8::Local<v8::Value>*) const’:
../../nan/nan.h:1463:5: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
));
^
In file included from ../src/jsfilterlist.cc:1:0:
/root/.node-gyp/10.4.1/include/node/node.h:172:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.1/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
cytubefilters.target.mk:105: recipe for target 'Release/obj.target/cytubefilters/src/jsfilterlist.o' failed
make: *** [Release/obj.target/cytubefilters/src/jsfilterlist.o] Error 1
make: Leaving directory '/home/user/sync/node_modules/cytubefilters/build'
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:258:23)
gyp ERR! stack at ChildProcess.emit (events.js:182:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:237:12)
gyp ERR! System Linux 4.10.0-42-generic
gyp ERR! command "/usr/local/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/user/sync/node_modules/cytubefilters
gyp ERR! node -v v10.4.1
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! cytubefilters@git://github.com/calzoneman/cytubefilters.git#67c7c69a684a546fc6dc5d22d654ead96b6d7fe0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the cytubefilters@git://github.com/calzoneman/cytubefilters.git#67c7c69a684a546fc6dc5d22d654ead96b6d7fe0 install 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/2018-06-21T01_13_34_584Z-debug.log
Firstly, please refer to the documentation and note that I explicitly do not support installation as root.
Yes, CyTube builds successfully on node.js 10. The error message from the above log appears to be coming from nan
, a wrapper layer that CyTube's C++ module uses as an abstraction/wrapper for the v8 API.
Once you have switched to a non-root user, can you please try a clean install with rm -rf node_modules && rm package-lock.json && npm install
to ensure that all modules are up to date and are not being locked to an incompatible version?
Yes, it builds and runs if you don't run it as root.
I didn't realize I used the wrong cert when SSH'ing.
Closing since the MySQL warning is just a warning and the project already has an active pull request to fix it going forward: https://github.com/mysqljs/mysql/pull/2026
Not to be confused with v0.10...
Looks like this does require changes to get it to build:
bcrypt
needs to be updated to v2. This is backwards compatible for existing hashes, but reportedly hashes created with v2 cannot be correctly compared using v1 of the library.v8-profiler
needs to be removed. It does not build in node.js 10.(node:11282) [DEP0096] DeprecationWarning: timers.unenroll() is deprecated. Please use clearTimeout instead.
Unsure which dependency is responsible for this.