sahilchaddha / homebridge-magichome-platform

Homebridge Plugin for MagicHome LED Strips with Preset Scene Automation Support (Cycle Color/Fade/Strobe)
MIT License
47 stars 12 forks source link

Add timeout of 60s for exec-ed commands as a safeguard. #13

Open valentinvarbanov opened 5 years ago

valentinvarbanov commented 5 years ago

The python would sometimes get stuck on executing command like: python /usr/local/lib/node_modules/homebridge-magichome-platform/src/flux_led.py 10.0.x.x -i. This python process would stuck on near 100% cpu usage and the raspberry pi would have increased cpu temperature by 20-30 degrees.

This change should not have any negative side effects, as in normal use cases 60s should be enough for a command to execute.

valentinvarbanov commented 4 years ago

@sahilchaddha Do you plan to merge this?