TheThingsArchive / nodered-app-node

Node-RED Library for TTN Applications
https://www.thethingsnetwork.org/docs/node-red/
MIT License
20 stars 14 forks source link

ttn app: NoappId, accessKey or discovery address #50

Closed dicktonyboy closed 5 years ago

dicktonyboy commented 5 years ago

Brand new Stretch Pi install on Pi 3, then run the install script bash <(curl -sL https://raw.githubusercontent.com/node-red/raspbian-deb-package/master/resources/update-nodejs-and-nodered) Node v11.1.0 npm V 6.4.1 So far so good. The ttn- install using the GUI install fails or on the second attempt loads the three node BUT when trying to configure Node Properties there is no edit/add option in the App option box. Using the text install option in ~/.node-red and the installation completes providing the add/edit (little pen icon) option. The who thing appears to function correctly (using the gui) BUT the log complains that no appId, accessKey or discovery address has been recorded.. Nothing therefore functions. Any ideas folks?

johanstokking commented 5 years ago

Thanks for reporting, we'll look into this.

Octoate commented 5 years ago

Hi, I have the same problem, however I am using Docker on my Raspberry Pi and the official Docker image for it (Node-Red Docker Image. I tried to install the TTN nodes via GUI, command line and the node-red remote administration tool, but always with the same result: the ttn-app node is not working. On my desktop system I am using the same setup - but on a x86 machine and the TTN nodes were installed and working as expected.

As you can see in the screenshot below, the "ttn-app" is disabled and there is a warning sign with an JavaScript object (not much to see here...): ttn-app-notworking

I have also attached the output of the Node-Red start to this message. Node-Red-TTN-Nodes-Problem.txt

johanstokking commented 5 years ago

That looks like an older version of the TTN nodes for Node-RED; ttn app is gone now.

Octoate commented 5 years ago

Strange. It tells me that I am using the latest version: v2.0.4.

johanstokking commented 5 years ago

@Octoate the ttn app is a configuration node, hence it's grayed out. So contrary to what I said above, it is still being used, but not supposed to be placed on your flows as a node.

@dicktonyboy I cannot reproduce this. This sounds like an installation issue, by a mixup of GUI and CLI installs. I need a clean set of steps to reproduce from a known state, instead of a list of things that have been tried with a certain result.

dicktonyboy commented 5 years ago

Wenner World of Weirdness continues. Made a clean Stretch install and applied the update script from the Node Red site. Installed ttn and had the same error - ie no blue 'connected' circle. Moved the Pi to another network (forcing static IP - no other change) and the blue connected indicators appear!!! (Aside- using older firefox 24.5.0). Reverted back to original physical network (and dhcp) and connected lights do not appear. Thought it may be the Ad-blocker so used IE Tor Edge Firefox Opera and Chrome but no - all browsers act consistently. Baffled - but can't move back to 2nd network due to access issues for the next week.

johanstokking commented 5 years ago

That's weird. Please also keep a close look at the browser's JavaScript/console output.

RvRijsselt commented 5 years ago

I probably had the same initial issue:

I was able to fix my installation by running the following in the .node-red path: npm rebuild --build-from-source=grpc

Note however that I am running Raspbian GNU/Linux 8 (jessie). Oh and the network issues indeed sound very weird and probably not related to this. Do you have any startup warnings or errors from node-red? You can also increase the log level of node-red.

johanstokking commented 5 years ago

@RvRijsselt great, that sounds as a sensible solution indeed. Could you make a PR for the README?

johanstokking commented 5 years ago

Closed by #53

Octoate commented 5 years ago

I was able to fix my installation by running the following in the .node-red path: npm rebuild --build-from-source=grpc

Finally, that fixed the issue. Thanks a lot. Everything is working now!