jdeath / Hubspace-Homeassistant

Hubspace Integration for Home Assistant
MIT License
187 stars 35 forks source link

Refactor discovery #83

Closed Expl0dingBanana closed 2 months ago

Expl0dingBanana commented 2 months ago

The goal of this PR is to make discovery more unit-testable outside of HASS. There will be a follow-up PR the begins to merge manual discovery and auto discovery into a single pipeline to reduce the amount of duplicate code.

After the code has been merged, a separate PR will be created for linting and will be added to a git-ignore list. The github action will be updated to ensure linting and tests passes.

jdeath commented 2 months ago

Do you plan on expanding the auto discovery? I do not support, so would be good if you can take requests to add support as well. All the external actions are way beyond my skill, so I will not be able to support them in the future

Expl0dingBanana commented 2 months ago

I plan on reducing the amount of code between the two discoveries. I am working on another branch locally where manual and auto more or less work the same way. The logic is as follows:

jdeath commented 2 months ago

PS - This fan was not worth the hassle 😂

I know. I created this whole project for a single light I bought!

I merged your stuff. But I will wait on a new release till everything is done