New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix and refactor current tahoma integration #41267
Conversation
Signed-off-by: Mick Vleeshouwer <mick@imick.nl>
717e7f7
to
22b64c1
Compare
Why do we have to add the config flow in this PR? I'd expect this PR to just change the library and all interfaces to the library that needs to change. |
The whole logic has been changed along side the API. I'm not sure it makes any sense to compare it to the existing core integration. Although it replaces the old one with the same domain name, I would argue in favor of treating it as a new integration. Not sure whether that's possible though. |
It's not a new integration. We don't need to change this much in this PR. Please strip it down to the bare minimum in each PR. This PR should just change the library and the required interfaces. It should not add any new features. |
fair enough :) |
I understand that a PR should be small, since this is very hard to review. We can separate the Config Flow for sure, however breaking down all the new functionality into separate PR's will be hard... I could start with removing the Config Flow + some extra added features in Indeed, this PR also offers new functionality, since we worked for months on it as a custom component. The main issue is that the integration is core is broken, but still has many platforms like Another possibility could be to remove the broken |
What needs to change in the platforms, besides the library interface, to not have a broken integration? |
Almost all code, since the new async API is using different endpoints and responses in combination with the DataUpdateCoordinator. I will strip as much code as possible and update this PR, however the code in the platforms needs fundamental changes, which I could probably not work around. But the ConfigFlow and OptionsFlow could be separated in another PR, same for the services added. I don't prefer to work from zero again to adapt the old code to the new async API, since there are many fundamental differences around handling commands / states and not relying on a hardcoded list. |
It's ok to update the platforms to make them work with the new library. Just don't add any new user facing features. |
Signed-off-by: Mick Vleeshouwer <mick@imick.nl>
Signed-off-by: Mick Vleeshouwer <mick@imick.nl>
Signed-off-by: Mick Vleeshouwer <mick@imick.nl>
Great to hear and thanks for your review. I have removed the Config Flow, Options Flow and registered services. This should eliminate all user facing features. I don't believe that we are able to get this pull request any smaller. Do you think that this one is small enough to be reviewed? |
We just received confirmation from Somfy that they allow the use of the internal TaHoma API! 🥳 There are a few restrictions, which require us to make small changes to this PR.
This is not a definitive solution, Somfy will be monitoring the traffic generated and evaluate. |
Closing in favour of #43966. |
This is quite a big pull request to review unfortunately, due to the changes we had to make to the original tahoma integration. The tahoma integration is broken since the
2020.3.4-12
firmware update and has an active alert on Home Assistant Alerts.@vlebourl, @tetienne and me worked on rewriting this component for the last months and we think it is now ready to be added to core. We have had quite some testers using the custom component and we had tons of feedback.
We will split the changes in multiple PR's to core, however we couldn't ignore that the first one would be bigger than expected. It was not possible to only touch parts of this integration, without fixing others, to bring this integration back in line with the current standards.
Future PR's will add support for additional platforms like
alarm_control_panel
,climate
andlight
plus some other fixes that would clutter this pr to much.Breaking change
MotionSensor
,SmokeSensor
,ContactSensor
mapping from sensor to binary_sensor.GarageDoor
mapping from switch to cover.OnOffLight
from switch to light (light not in this PR).assumed_state = True
.Proposed change
Type of change
Example entry for
configuration.yaml
:Since this integration now fully supports the config flow, the YAML configuration could possibly be removed in the future.
Additional information
Checklist
black --fast homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.The integration reached or maintains the following [Integration Quality Scale][quality-scale]:
To help with the load of incoming pull requests: