stephenkeep / node-red-contrib-chromecast

Node-RED nodes for Chromecast
4 stars 28 forks source link

Connection error to cast device crashes complete node-red #4

Closed Hypnos3 closed 5 years ago

Hypnos3 commented 6 years ago

If connection to google case device is lost, complete node red is crashing

Jul  7 10:13:48 node-red: 7 Jul 10:13:48 - [red] Uncaught Exception:
Jul  7 10:13:48 node-red: 7 Jul 10:13:48 - Error: connect ETIMEDOUT 192.168.178.35:8009
Jul  7 10:13:48 node-red:     at Object._errnoException (util.js:992:11)
Jul  7 10:13:48 node-red:     at _exceptionWithHostPort (util.js:1014:20)
Jul  7 10:13:48 node-red:     at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1186:14)

After that node-red is no longer working and must be started on the command-line.

The IP 192.168.178.35 is my cast device and the node-red-contrib-chromecast is the only who uses this.

My cast device is a google home mini. Normally all is working fine and the input will be given to the device.

Can you please make it more error tolerant?

Hypnos3 commented 5 years ago

I have fixed this in my fork. https://github.com/Hypnos3/node-red-contrib-cast