Sanderhuisman / home-assistant-custom-components

🏡 Custom components for Home-Assistant
https://www.home-assistant.io/
Apache License 2.0
33 stars 12 forks source link

Do not use stream API for stats #23

Closed guillaumelamirand closed 4 years ago

guillaumelamirand commented 4 years ago

As we define a interval and we use a sleep to wait a bit, we don't need to use the stream api to request stats from docker. Also we can directly use the thread.Event() in a while loop to stop the thread directly.