[DNM] Gree Integration rewrite#373
Conversation
- Change config flow to: be multi step and allow setting the device features; allow to reconfigure an entry - Separate HA and Device API logic: device API is now declarative and handles device behaviour. HA entities expose the device - Implement a coordinator - Async device communication - More error handling
- Move consts around - Proper error report on config_flow - Proper translations on config_flow - Configuration of timeout - Fetch device info during binding
|
@RobHofmann I was adding the temperature step back, but I'm not sure of its utility. |
|
@p-monteiro |
|
Hi @domialex, that's fine. I'm more interested in the real use case for it. Should it be locked to integers? I don't think any device supports half degrees or even 0.1 steps, as is the lower limit for the current slider... |
Adds a binary sensor that shows if there is a fault reported by the device
|
@RobHofmann I'm down to get this merged into a different branch and published as an alpha/beta version. Fixes can then be made against that. I'll let you decide whatever you deem fit for the project. Remember, this is a breaking update. Refer to the original PR message (#373 (comment)) |
This workflow uses the version from the manifest to automatically create a tag and a release. Also prevents two consecutive releases with the same version
Use proper types V2 decrypt and verify combined Debug trimmed garbage (may be useful)
|
Hey! Im unable to discover my devices through this integration. I've created a fix for this on my own version yesterday: Can you please include this in your setup too? As for your comment on YAML: I'm not sure. I'm not using it anymore. But theres a big reason why I could see people wanting to use this: Configuration as Code --> Easier to save in a repository. Same with Infrastructure as Code. This also means you can version your configuration. Reason why i'm currently not using it anymore is because I need to test the config flow for the ingration, but for other components I use YAML as long as I can :). But tbh i'm not sure how other people look at this. PS. I've started testing your release just now. |
|
@RobHofmann Hi, thanks for the notes. Keep testing and let me know whatever you need. As for the YAML, that's a good and valid point, though HA backups should address the issue. I'm just more comfortable following the official guidelines. But your call. |
You need to brief me on the validation part here. No hurry, let me know when you get it in :).
Backups would be nice, but for a docker setup this is not a feature. I do have backups in place, but its all "self managed". I trust more in plain code "backups" to a repository where I can also use things like branching (and test on my dev machine etc). So in short: i assume powerusers have more benefit from the YAML than "regular" users. Normally i'd absolutely go "home assistant native", but so far I'm not really seeing solutions accros the board. This is why I want to keep the options open. For us it's easy to maintain YAML for now. If these challenges get solved in the future we can always drop it. |
It's just HACS and Hassfest validation to ensure integration quality.
I also have backups configured for my Docker instance, and they are automatic through the Backups page inside HA, but I do understand where you come from. That's fine, really. It requires a bit more code to do proper config validation, but that's all. It's done and working. |
Caution
This PR changes the domain of the integration, so current users will lose their device configs!
The config schema also changed, so verify your YAML if you use it to configure the devices.
This no longer overwrites the official integration.
This PR introduces a rewrite of this integration. The main goal of this was to better align the integration with the Home Assistant (HA) development workflow with two main changes:
Breaking changes
Features
DataUpdateCoordinatorGreeDeviceabstraction for device logicRestoreEntitysupport inClimateEntityImprovements
Fixes
Known problems:
As you can see, there are a lot of changes, and I understand if this does not go through as is.