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

install #40

Closed
aaronzandman opened this issue Jul 19, 2018 · 18 comments
Closed

install #40

aaronzandman opened this issue Jul 19, 2018 · 18 comments

Comments

@aaronzandman
Copy link

I am very new to Raspberry Pi , and I have spent the past few days trying to resolve this via google, However I am having some issues and would appreciate a point in the right direction.

During Install I get this error

`pi@pi:~/Assistant-relay $ npm install

speaker@0.3.1 install /home/pi/Assistant-relay/node_modules/speaker
node-gyp rebuild

make: Entering directory '/home/pi/Assistant-relay/node_modules/speaker/build'
CC(target) Release/obj.target/output/deps/mpg123/src/output/alsa.o
../deps/mpg123/src/output/alsa.c:19:28: fatal error: alsa/asoundlib.h: No such file or directory
#include <alsa/asoundlib.h>
^
compilation terminated.
deps/mpg123/output.target.mk:108: recipe for target 'Release/obj.target/output/deps/mpg123/src/output/alsa.o' failed
make: *** [Release/obj.target/output/deps/mpg123/src/output/alsa.o] Error 1
make: Leaving directory '/home/pi/Assistant-relay/node_modules/speaker/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.14.52-v7+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/pi/Assistant-relay/node_modules/speaker
gyp ERR! node -v v10.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok

grpc@1.8.0 install /home/pi/Assistant-relay/node_modules/grpc
node-pre-gyp install --fallback-to-build --library=static_library

node-pre-gyp ERR! Tried to download(403): https://storage.googleapis.com/grpc-precompiled-binaries/node/grpc/v1.8.0/node-v64-linux-arm-glibc.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for grpc@1.8.0 and node@10.6.0 (node-v64 ABI, glibc) (falling back to source compile with node-gyp)
node-pre-gyp ERR! Tried to download(undefined): https://storage.googleapis.com/grpc-precompiled-binaries/node/grpc/v1.8.0/node-v64-linux-arm-glibc.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for grpc@1.8.0 and node@10.6.0 (node-v64 ABI, glibc) (falling back to source compile with node-gyp)
make: Entering directory '/home/pi/Assistant-relay/node_modules/grpc/build'
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o
make: Entering directory '/home/pi/Assistant-relay/node_modules/grpc/build'
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o
rm: cannot remove './Release/.deps/Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o.d.raw': No such file or directory
grpc.target.mk:384: recipe for target 'Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o' failed
make: *** [Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o] Error 1
make: Leaving directory '/home/pi/Assistant-relay/node_modules/grpc/build'
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/backoff/backoff.o
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.14.52-v7+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc/grpc_node.node" "--module_name=grpc_node" "--module_path=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc"
gyp ERR! cwd /home/pi/Assistant-relay/node_modules/grpc
gyp ERR! node -v v10.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc/grpc_node.node --module_name=grpc_node --module_path=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc' (1)
node-pre-gyp ERR! stack at ChildProcess. (/home/pi/Assistant-relay/node_modules/grpc/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:182:13)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:961:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:248:5)
node-pre-gyp ERR! System Linux 4.14.52-v7+
node-pre-gyp ERR! command "/usr/bin/node" "/home/pi/Assistant-relay/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd /home/pi/Assistant-relay/node_modules/grpc
node-pre-gyp ERR! node -v v10.6.0
node-pre-gyp ERR! node-pre-gyp -v v0.6.39
node-pre-gyp ERR! not ok
Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc/grpc_node.node --module_name=grpc_node --module_path=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc' (1)
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_args.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack.o
In file included from ../deps/grpc/src/core/lib/channel/channel_stack.cc:19:0:
../deps/grpc/src/core/lib/channel/channel_stack.h:38:23: fatal error: grpc/grpc.h: No such file or directory
#include <grpc/grpc.h>
^
compilation terminated.
grpc.target.mk:384: recipe for target 'Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack.o' failed
make: *** [Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack.o] Error 1
make: Leaving directory '/home/pi/Assistant-relay/node_modules/grpc/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.14.52-v7+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc/grpc_node.node" "--module_name=grpc_node" "--module_path=/home/pi/Assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc"
gyp ERR! cwd /home/pi/Assistant-relay/node_modules/grpc
gyp ERR! node -v v10.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN assistant-relay@1.0.1 No repository field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: speaker@0.3.1 (node_modules/speaker):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: speaker@0.3.1 install: node-gyp rebuild
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc@1.8.0 install: node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc@1.8.0 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/2018-07-19T12_43_22_670Z-debug.log
pi@pi:~/Assistant-relay $
`

@aaronzandman
Copy link
Author

running on a RP3
Linux version 4.14.52-v7+ (dc4@dc4-XPS13-9333) (gcc version 4.9.3 (crosstool-NG crosstool-ng-1.22.0-88-g8460611)) #1123 SMP Wed Jun 27 17:35:49 BST 2018

etched from 2018-06-27-raspbian-stretch

@Jpereyra316
Copy link

I'm having the same/similar issue. I've attached the log file.

2018-07-22T22_59_02_885Z-debug.log

@xXCHRSTBLCKXx
Copy link

I was experiencing the same problem, but resolved it by following the exact steps from this installation guide: https://github.com/ryancasler/assistant-relay/wiki/Install-Instructions

@DaveMeade
Copy link

@churstblock I'm not clear on step 8 of the "update other stuff" section. What username is it asking for here? There doesn't appear to be a username contained within my credentials.json file.

@xXCHRSTBLCKXx
Copy link

@DaveMeade It's referring to Step 17 of the Google Cloud Setup section.

@DaveMeade
Copy link

Thanks @churstblock

I seem to have everything setup and the server is running an accepting commands, but there is no resulting broadcasts on my google home speakers.

> assistant-relay@1.0.1 start /home/pi/assistant-relay
> node index.js

Fired up the SSDP Server for network discovery...
Firing up the Web Server for communication on address 192.168.1.74:3000
Assistant Relay is now setup and running for dave
Received command broadcast Assistant Relay is now setup and running for dave
No user specified, using dave
Received command broadcast Hello World
User specified was dave

I didnt hear either of the "Hello World" or the "Assistant Relay is now setup and running for dave"

Any suggestions as to where to look for the problem?

@xXCHRSTBLCKXx
Copy link

@DaveMeade Only thing I could think of would be that your Google Cloud project and OAuth key aren't on the same Google account as your existing Google Home.

@DaveMeade
Copy link

Hmm, they are on the same account. I checked the Google Cloud project dashboard, and it is receiving and processing the calls, but its returning a 499 Error (Canceled by user). I'm not sure what to do what that, but perhaps I'll start a new thread as it doesn't appear to be "install" related anymore. Thanks for your help, @churstblock .

@phvajjha
Copy link

phvajjha commented Aug 9, 2018

@DaveMeade before you start a new thread - endoplasmic/google-assistant#52

Its just not working for some Google users. Its something on Google's end. If you want to make sure your setup is right, just make sure the command shows up here - https://myactivity.google.com/myactivity

If it does, you are good. Just wait (unfortunately) for Google to resolve this.

@DaveMeade
Copy link

@phvajjha thanks for that. interesting thread. I'm not sure if its related to my error, but it seems to be a pretty safe bet. I'll post my observations there.

@phvajjha
Copy link

phvajjha commented Aug 9, 2018

It works (flakily) for me. I always get the 499 Error response on the web console. I guess you can safely ignore it. Many other users reported the same error code on the dashboard, even when it was working fine a few months ago.

@Jpereyra316
Copy link

I followed the steps from https://github.com/ryancasler/assistant-relay/wiki/Install-Instructions.

I still get a fatal error while npm is running make. I've attached a text file with the output as well as the npm log.

2018-08-09T19_09_16_510Z-debug.log
assistan-relay_npm_error.txt

@Jpereyra316
Copy link

Jpereyra316 commented Aug 9, 2018

I noticed it seems to start failing when trying to download from GRPC storage.googleapis.com.
I tried downloading it manually, but wasn't successful:
https://storage.googleapis.com/grpc-precompiled-binaries/node/grpc/v1.8.0/node-v64-linux-arm-glibc.tar.gz

AccessDenied
Access denied.

Anonymous caller does not have storage.objects.get access to grpc-precompiled-binaries/node/grpc/v1.8.0/node-v64-linux-arm-glibc.tar.gz.

@DaveMeade
Copy link

@Jpereyra316 I had the same issue because, like you (judging by the error log), I had been trying to use the latest version of node. Something about that fails. Try uninstalling nodejs and re-installing it according to the install instructions you linked. (Just below "17. Once downloaded...")

@Jpereyra316
Copy link

Yeah, I'm trying to use the latest version.

Thanks for the tip. I'll downgrade and see if that resolves my issue.

@Jpereyra316
Copy link

So I followed step 17 in https://github.com/ryancasler/assistant-relay/wiki/Install-Instructions and was able to install. However, when running node index.js on the RPI through remote desktop connection I get the following error:

pi@raspberrypi:~/assistant-relay $ node index.js
/home/pi/assistant-relay/node_modules/grpc/src/grpc_extension.js:46
throw error;
^

Error: Failed to load gRPC binary module because it was not installed for the current system
Expected directory: node-v64-linux-arm-glibc
Found: [node-v59-linux-arm-glibc]
This problem can often be fixed by running "npm rebuild" on the current system
Original error: Cannot find module '/home/pi/assistant-relay/node_modules/grpc/src/node/extension_binary/node-v64-linux-arm-glibc/grpc_node.node'
at Object. (/home/pi/assistant-relay/node_modules/grpc/src/grpc_extension.js:44:17)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object. (/home/pi/assistant-relay/node_modules/grpc/src/client.js:38:12)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)

Any suggestions?

Thanks for all the help!

@Jpereyra316
Copy link

Never mind.

I restarted the RPI and it worked. I think the node installation wasn't being used for some reason, so it was trying to use the newer one to launch index.js.

I heard "Assistant Relay is now setup and running for ", so I guess it's working. I'll play around with it some more tomorrow.

@red3recon
Copy link

red3recon commented Aug 15, 2018 via email

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

7 participants