Add config option to use zigpy-ota beta channel#617
Add config option to use zigpy-ota beta channel#617TheJulianJES wants to merge 3 commits intozigpy:devfrom
zigpy-ota beta channel#617Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #617 +/- ##
=======================================
Coverage 97.01% 97.02%
=======================================
Files 63 63
Lines 10569 10579 +10
=======================================
+ Hits 10254 10264 +10
Misses 315 315 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Hmmm, this is definitely a gap in how we tie ZHA and zigpy together 🤔. With users being able to override OTA providers via YAML, I wonder: maybe we can simplify this by assigning |
|
Yeah, that makes sense. An even simpler idea I had before was passing a generic (and For the OTA channel stuff, I'm also good with your ID idea, so we can go that route. |
|
Passing |
WIP - see "questions" at the bottom
Proposed change
This adds an
OTAConfigurationdataclass to allow Home Assistant Core to provide a config option that enables beta updates for the zigpy-ota provider.ZHA passes this option to zigpy by adding another zigpy-ota provider with the
betachannel andoverride_previousoptions set (to remove the defaultstableOTA provider added in zigpy).If any zigpy-ota provider is specified in YAML config, that takes precedence and this code doesn't add the overriding beta channel OTA provider.
Additional information
To show this option in Home Assistant Core, some changes will be needed there: home-assistant/core@dev...TheJulianJES:core:tjj/zha_zigpy_ota_beta_channel_config
There's also a
devzigpy-ota provider channel that's updated with new images, as soon as a new update/PR is merged, but I don't want to expose that in the UI. It can still be enabled via HA's YAMLconfiguration.yaml, as described here.Questions
I've only added a
use_beta_channelflag toOTAConfiguration. If we make this an enum/str with channels, we could have ZHA pass through more options for zigpy-ota. If we do that, we could always override the default zigpy-ota provider enabled in zigpy. But since we wouldn't allow enablingdevchannel support via the ZHA UI, we'd still have to check fordevextra_providersto allow that via YAML. Or should we disable the zigpy-ota provider by default in zigpy and only enable it through ZHA here?Not sure if I'm fully happy with this, yet..