jrlucier / eero_tracker

Eero Device Tracker for Home Assistant (HA, HASS.IO, HASS OS, HASSIO)
Other
64 stars 11 forks source link

Add config flow to onboard eero tracker integration #31

Closed cogwirrel closed 3 years ago

cogwirrel commented 3 years ago

Hey!

Hopefully this is useful :)

This PR adds a very basic config flow to set up the Eero integration - accepting an email or phone number, then a verification code, and writing the eero.session file. This allows users to create the session file via the UI rather than running a python script :)

Note that I copied most of the relevant parts from the eero_tracker_instantiate.py file into eero.py within the custom component, so that the eero client can be used in the config flow and other parts of the custom component. It should be possible to refactor away some of the duplication between this and device_tracker.py but I don't want this PR to have too big a blast-radius!

Cheers, Jack

jrlucier commented 3 years ago

Thanks for the pull request! I'll be testing it out locally this weekend and then merge it if it all looks good :)

cogwirrel commented 3 years ago

Thanks for the pull request! I'll be testing it out locally this weekend and then merge it if it all looks good :)

No worries! Awesome, thanks for taking a look! :)