tagyoureit / nodejs-poolController-webClient

Web app for nodejs-poolController 6.0 and above.
GNU Affero General Public License v3.0
9 stars 4 forks source link

Trouble with install #8

Closed sparment closed 4 years ago

sparment commented 4 years ago

@tagyoureit I'm having issues installing and running the poolController-webClient. I'm getting the following warnings following the install command. Any suggestions?

npm WARN react-rangeslider@2.2.0 requires a peer of react@^0.14.0 || ^15.0.0 but none is installed. You must install peer dependencies yourself. npm WARN recompose@0.22.0 requires a peer of react@^0.14.0 || ^15.0.0 but none is installed. You must install peer dependencies yourself. npm WARN nodejs-poolcontroller-webclient@1.0.0 No repository field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})

tagyoureit commented 4 years ago

Those warnings are ok. What happens when you try to start the app and load it in the browser?

sparment commented 4 years ago

Thanks for the response @tagyoureit . I was also having issues with the nodejs-poolcontroller; so I installed an earlier version of node (8.9.1) and npm (5.5.1). Nodejs-poolcontroller appears to be running without errors, but I'm now getting the following errors when I run nodes-poolcontroller-webclient:

Error: Could not locate the bindings file. Tried: ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build/Debug/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build/Release/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/out/Debug/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/Debug/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/out/Release/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/Release/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build/default/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/compiled/8.9.1/linux/arm/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/addon-build/release/install-root/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/addon-build/debug/install-root/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/addon-build/default/install-root/deasync.node ? /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/lib/binding/node-v57-linux-arm/deasync.node at bindings (/home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/bindings/bindings.js:126:9) at Object. (/home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/index.js:30:31) at Module._compile (module.js:635:30) at Object.Module._extensions..js (module.js:646:10) at Module.load (module.js:554:32) at tryModuleLoad (module.js:497:12) at Function.Module._load (module.js:489:3) at Module.require (module.js:579:17) at require (internal/module.js:11:18) at Object. (/home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/parcel-bundler/src/utils/syncPromise.js:1:79) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! nodejs-poolcontroller-webclient@1.0.0 start:cached: env NODE_ENV=production node dist/Server.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the nodejs-poolcontroller-webclient@1.0.0 start:cached 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! /home/pi/.npm/_logs/2020-06-13T13_46_38_463Z-debug.log npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! nodejs-poolcontroller-webclient@1.0.0 start: npm run cleanup && npm run build && npm run start:cached npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the nodejs-poolcontroller-webclient@1.0.0 start 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! /home/pi/.npm/_logs/2020-06-13T13_46_38_531Z-debug.log

When I navigate to the browser, I get:

Cannot GET /

sparment commented 4 years ago

I tried removing and reinstalling the nodejs-poolcontroller-webclient and got errors with the installation. I'm thinking this is the issue, but am not sure how to fix. Any help would be appreciated - I'm a novice at best.

make: *** [deasync.target.mk:91: Release/obj.target/deasync/src/deasync.o] Error 1 make: Leaving directory '/home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build' gyp ERR! build error gyp ERR! stack Error: make failed with exit code: 2 gyp ERR! stack at ChildProcess.onExit (/home/pi/.config/nvm/versions/node/v8.9.1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23) gyp ERR! stack at emitTwo (events.js:126:13) gyp ERR! stack at ChildProcess.emit (events.js:214:7) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12) gyp ERR! System Linux 4.19.118-v7+ gyp ERR! command "/home/pi/.config/nvm/versions/node/v8.9.1/bin/node" "/home/pi/.config/nvm/versions/node/v8.9.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" gyp ERR! cwd /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync gyp ERR! node -v v8.9.1 gyp ERR! node-gyp -v v3.6.2 gyp ERR! not ok Build failed npm WARN nodejs-poolcontroller-webclient@1.0.0 No repository field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! deasync@0.1.20 install: node ./build.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the deasync@0.1.20 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:

tagyoureit commented 4 years ago

I'm not able to replicate this. Make sure you aren't using npm i and then changing node versions. That doesn't work. Always reinstall the dependencies after switching node versions.

sparment commented 4 years ago

Thanks for the response and I apologize in advance for some basic questions... again I’m a novice when it comes to node and npm... I originally installed the latest versions of node and npm, but was having problems with the pool-controller nodejs install. So I uninstalled node and npm, then installed nvm and then node 8.9.1. That did the trick for installing and running pool controller nodejs. I then deleted the directory that had the pool controller web client installed and tried reinstalling. I’m thinking the issue has to do with changing node versions like you mentioned. How do I go about reinstalling dependencies? I guess I wrongfully assumed that a complete reinstall of the pool-controller webclient after the reinstall of node and npm via nvm would have taken care of everything. Thanks again for your help!

tagyoureit commented 4 years ago

you should remove the node_modules directory (although probably not strictly necessary) with rm -rf node_modules and then npm i again. That should do it.

sparment commented 4 years ago

Thanks, I ran the commands above. I'm still getting errors:

deasync@0.1.20 install /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync node ./build.js

make: Entering directory '/home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build' CXX(target) Release/obj.target/deasync/src/deasync.o In file included from ../src/deasync.cc:2: /home/pi/.node-gyp/8.9.1/include/node/v8.h: In static member function ?static void v8::V8::SetAllowCodeGenerationFromStringsCallback(v8::DeprecatedAllowCodeGenerationFromStringsCallback)?: /home/pi/.node-gyp/8.9.1/include/node/v8.h:10177:19: warning: cast between incompatible function types from ?v8::DeprecatedAllowCodeGenerationFromStringsCallback? {aka ?bool ()(v8::Local)?} to ?v8::FreshNewAllowCodeGenerationFromStringsCallback? {aka ?bool ()(v8::Local, v8::Local)?} [-Wcast-function-type] callback)); ^ /home/pi/.node-gyp/8.9.1/include/node/v8.h: In static member function ?static void v8::V8::RemoveGCPrologueCallback(v8::GCCallback)?: /home/pi/.node-gyp/8.9.1/include/node/v8.h:10222:53: warning: cast between incompatible function types from ?v8::GCCallback? {aka ?void ()(v8::GCType, v8::GCCallbackFlags)?} to ?v8::Isolate::GCCallback? {aka ?void ()(v8::Isolate, v8::GCType, v8::GCCallbackFlags)?} [-Wcast-function-type] reinterpret_cast(callback)); ^ /home/pi/.node-gyp/8.9.1/include/node/v8.h: In static member function ?static void v8::V8::RemoveGCEpilogueCallback(v8::GCCallback)?: /home/pi/.node-gyp/8.9.1/include/node/v8.h:10229:53: warning: cast between incompatible function types from ?v8::GCCallback? {aka ?void ()(v8::GCType, v8::GCCallbackFlags)?} to ?v8::Isolate::GCCallback? {aka ?void ()(v8::Isolate, v8::GCType, v8::GCCallbackFlags)?} [-Wcast-function-type] reinterpret_cast(callback)); ^ ../src/deasync.cc: In function ?Napi::Value Run(const Napi::CallbackInfo&)?: ../src/deasync.cc:10:16: error: ?GetCurrentEventLoop? is not a member of ?node? uv_run(node::GetCurrentEventLoop(v8::Isolate::GetCurrent()), UV_RUN_ONCE); ^~~~~~~ make: *** [deasync.target.mk:91: Release/obj.target/deasync/src/deasync.o] Error 1 make: Leaving directory '/home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync/build' gyp ERR! build error gyp ERR! stack Error: make failed with exit code: 2 gyp ERR! stack at ChildProcess.onExit (/home/pi/.config/nvm/versions/node/v8.9.1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23) gyp ERR! stack at emitTwo (events.js:126:13) gyp ERR! stack at ChildProcess.emit (events.js:214:7) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12) gyp ERR! System Linux 4.19.118-v7+ gyp ERR! command "/home/pi/.config/nvm/versions/node/v8.9.1/bin/node" "/home/pi/.config/nvm/versions/node/v8.9.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" gyp ERR! cwd /home/pi/nodejs-poolController-webClient-master/nodejs-poolController-webClient-master/node_modules/deasync gyp ERR! node -v v8.9.1 gyp ERR! node-gyp -v v3.6.2 gyp ERR! not ok Build failed npm WARN react-rangeslider@2.2.0 requires a peer of react@^0.14.0 || ^15.0.0 but none is installed. You must install peer dependencies yourself. npm WARN recompose@0.22.0 requires a peer of react@^0.14.0 || ^15.0.0 but none is installed. You must install peer dependencies yourself. npm WARN nodejs-poolcontroller-webclient@1.0.0 No repository field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! deasync@0.1.20 install: node ./build.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the deasync@0.1.20 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! /home/pi/.npm/_logs/2020-06-14T00_35_37_208Z-debug.log

tagyoureit commented 4 years ago

What OS are you on? Mac? Which version?

sparment commented 4 years ago

Raspberry Pi

tagyoureit commented 4 years ago

npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})

Somehow the setup scripts are looking for Darwin which is Mac OS. You have something strange going on with your OS or Node install possibly.

sparment commented 4 years ago

I tried rebuilding the Pi this morning starting with a clean install of nvm and then node 8.9.1. I got the same errors. So then I installed node 10.21.0 and reinstalled the webclient. That seemed to work for the install!

I then successfully started the pool-controller and started the pool-controller-webclient. The webclient gets hung up at the "building index.js" phase. The Pi then becomes unresponsive...

I'm thinking it is because I have an Intellicenter - I just reread the pool-controller readme file and am going to give the dash panel web client a go instead.

Bottom line - my install issue was fixed by changing the node to 10.21.0.

Thanks.

jgaro commented 3 years ago

I see this as well running on Windows: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}), which ends up throwing this error: env NODE_ENV=production node dist/Server.js 'env' is not recognized as an internal or external command,. I'm assuming this is related to how nodejs is building for the environment? Is there any way to either force it to use windows, or check out what dependencies might be throwing this?