Commit Graph

43 Commits (6423501498cedc6a11bed9e9a07fde0d3426379b)

Author SHA1 Message Date
Joost Lekkerkerker 6bb4e7d62c
Bump ruff to 0.3.4 (#112690)
Co-authored-by: Sid <27780930+autinerd@users.noreply.github.com>
Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-03-26 00:02:16 +01:00
Marc Mueller 32f3f46542
Add empty line after module docstring (2) [tests.components] (#112737) 2024-03-08 19:16:21 +01:00
Marc Mueller 87165c0d6e
Add empty line after module docstring [tests t-z] (#112712) 2024-03-08 14:44:56 +01:00
Niels Perfors 951743551a
Add Tado add meter readings service (#111552) 2024-02-26 23:47:01 +01:00
G Johansson bc720b48b4
Add TURN_OFF and TURN_ON to ClimateEntityFeature (#101673)
* Add ClimateEntityFeature.TURN_OFF

* Fixes

* Fixes

* wording

* Change to services

* Fixing

* Fixing

* Last bits

* Review comments

* Add hvac_modes checks

* Fixes

* Add tests

* Review comments

* Update snapshots

* balboa

* coolmaster

* ecobee

* mqtt

* nest

* plugwise

* smarttub

* whirlpool

* zwave_js

* fix test climate

* test climate

* zwave

* nexia

* nuheat

* venstar

* tado

* smartthings

* self.hvac_modes not None

* more tests

* homekit_controller

* homekit controller snapshot
2024-01-30 15:07:47 +01:00
Erwin Douna 15e3af72d1
Fix Tado unique mobile device dispatcher (#107631)
* Add unique home ID device dispatch

* Adding fixture for new setup

* Minor refactor work

* Add check for unlinked to different homes

* If the interface returns an error

* Proper error handling

* Feedback fixes

* Comments for error in client

* Typo

* Update homeassistant/components/tado/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/tado/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update devices fix standard

* Dispatch out of loop

* Update dispatcher

* Clean up

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-01-10 12:09:10 +01:00
Erwin Douna 59a01fcf9c
Add try-catch for invalid auth to Tado (#106774)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-01-03 09:15:39 +01:00
Erwin Douna 4decc2bbfb
Refactor Tado to use OAuth in the DeviceTracker (#102610)
* Refactor to use TadoConnector in the DeviceTracker

* Proposing myself as code owner to be notified of issues

* Update homeassistant/components/tado/device_tracker.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Fixing method names

* Current progress, switching machines

* Updating DeviceTracker to working prototype

* Removing unnecessary callback

* Adding dispatcher logic

* Minor fine-tuning the intervals

* Removing unnecessary debug log

* Update homeassistant/components/tado/device_tracker.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update homeassistant/components/tado/device_tracker.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Fix sorting

* Retrieve devices from the Tado connector data

* Asyncio feedback & dispatch generic mobile devices

* Updating const

* Fine-tuning unloading

* Making add_tracked_entites callback

* Adding unload over dispatcher_connect

* Convert on_demand_update to callback

* Removing now unused method

* Merging method to on_demand_u

* Adding create_issue to address repair

* Updating with better translation

* Converting to callback

* Adding _attr_should_poll

* Putting back the on_demand_update

* Adding unique_id

* Converting to TrackerEntity

* Adding import step (review needed!)

* Update homeassistant/components/tado/device_tracker.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/tado/device_tracker.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/tado/device_tracker.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Typing and location_name

* Changing to _attr_unique_id

* Import improvement attempt

* Property feedback

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Adding CONF_HOME_ID and task in get_scanner

* Updating descriptions

* Removing the create_task

* Putting back PLATFORM_SCHEMA

* Adding device_tracker

* Adding get for HomeID

* Get it better ;)

* Retrieve HomeID from API

* Add integration title in dialogs

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Fixing homeID and strings.json

* Delete request in strings

* Update deprecation date

* Adding test cases for import flow

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Removing none

* Fixing test cases

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Removing from context manager

* Removing code owner

* Re-adding code owner

* Fix get scanner return value

* Fix device tracker interface

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2023-12-27 14:17:23 +01:00
J. Nick Koston 0eca433004
Update zeroconf discovery to use IPAddress objects to avoid conversions (#100567) 2023-09-19 18:58:46 +02:00
Erwin Douna d761b5ddbf
Add tests and typing to Tado config flow (#98281)
* Upgrading tests

* Code improvements and removing unused function

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update tests/components/tado/test_config_flow.py

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Importing Any

* Rerunning Blackformatter

* Adding fallback scenario to options flow

* Adding constants

* Adding a retry on the exceptions

* Refactoring to standard

* Update homeassistant/components/tado/config_flow.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Adding type to validate_input

* Updating test

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2023-08-17 19:37:34 +02:00
Joost Lekkerkerker 26152adb23
Add entity translations to Tado (#96226) 2023-07-23 14:32:25 +02:00
chiefdragon 9672db0354
Add new preset to Tado to enable geofencing mode (#92877)
* Add new preset to Tado to enable geofencing mode
Add new 'auto' preset mode to enable Tado to be set to auto geofencing
mode.  The existing ‘home’ and ‘away’ presets switched Tado into manual
geofencing mode and there was no way to restore it to auto mode.
Note 1: Since preset modes (home, away and auto) apply to the Tado home
holistically, irrespective of the Tado climate entity used to select
the preset, three new sensors have been added to display the state of
the Tado home
Note 2: Auto mode is only supported if the Auto Assist skill is enabled
in the owner's Tado home. Various checks have been added to ensure the
Tado supports auto geofencing and if it is not supported, the preset is
not listed in the preset modes available

* Update codeowners in manifest.json

* Update main codeowners file for Tado component
2023-05-23 19:08:00 +02:00
epenet 278050a73f
Add type hints to integration tests (t-z) (#87707) 2023-02-08 19:10:53 +01:00
Erik Montnemery 096ef5da47
Use Home Assistant swing modes in tado climate (#84278) 2023-01-17 16:13:49 +01:00
epenet 053c4428a9
Prettify json (component test fixtures) (#68892) 2022-03-30 11:37:17 +02:00
north3221 e76170fbfd
Add overlay options to Tado (#65886)
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2022-03-29 22:59:03 -07:00
Joshua Roys 9134e5c844
Get discovered zeroconf IPv6 addresses (#65462) 2022-02-11 16:46:17 -06:00
epenet 77dfeb062f
Update ZeroconfServiceInfo in tests (n-t) (#60219)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-11-23 10:35:44 -06:00
epenet 39149e19f7
Use ZeroconfServiceInfo in tado (#60111)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-11-22 11:54:15 +01:00
Paulus Schoutsen 31153ac155
Move fixtures part 1 (#58902) 2021-11-01 20:47:05 -07:00
Ville Skyttä cc0c79ac9a
Use http.HTTPStatus in components/[tuv]* (#58325) 2021-10-24 11:27:17 +02:00
Paulus Schoutsen a4d9019ffc
Refactor persistent notification to no longer route all data via a service (#57157)
* Convert persistent notification tests to async

* Create/dismiss persistent notifications in exposed functions, not service calls

* Fix notify persistent_notification

* Remove setting up persistent_notification

* Drop more setups

* Empty methods

* Undeprecate sync methods because too big task

* Fix setup clearing notifications

* Fix a bunch of tests

* Fix more tests

* Uno mas

* Test persistent notification events

* Clean up stale comment

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-10-07 12:58:00 +02:00
Niklas Åström 783cc1eacd
Optimise requests to the tado servers (#56261)
This avoids calling the tado servers unnecessarily many times, especially for bigger homes. This is done by calling aggregating endpoints instead of iterating over the zones and devices and calling endpoints over and over.
2021-09-22 14:01:30 +02:00
Ville Skyttä 153d6e891e
Use config_entries.SOURCE_* constants (#49631) 2021-04-25 11:27:40 +02:00
Franck Nijhof 7264c95217
Clean up superfluous integration setup - part 6 (#49298) 2021-04-16 09:23:27 -07:00
Álvaro Fernández Rojas ff09643b33
Add Tado weather support (#44807) 2021-03-10 10:31:37 -10:00
Álvaro Fernández Rojas 470121e5b0
Restore Tado binary sensor attributes (#46069) 2021-02-24 07:17:01 -06:00
north3221 f2a8ccdbae
Add tado service set temperature offset (#45014) 2021-01-26 09:11:29 +01:00
J. Nick Koston 47c0adb312
Remove YAML support from tado (#45384) 2021-01-24 01:33:30 +01:00
Álvaro Fernández Rojas ec926105a0
Bump PyTado to 0.10.0 (#44770)
* Bump PyTado to v0.10.0

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>

* Tado: switch to getDeviceInfo

This function has been introduced in version 0.10.0 of PyTado.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>

* Tado: update tests

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2021-01-04 03:53:15 +01:00
Álvaro Fernández Rojas 067f2d0098
Add tado zone binary sensors (#44576)
These should be binary sensors.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2021-01-02 13:35:59 +01:00
Franck Nijhof 65cf2fcb6f
Drop asynctest (#44746) 2021-01-01 22:31:56 +01:00
Álvaro Fernández Rojas 6d043f2ca1
Tado: add full list of devices (#44475)
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2020-12-27 16:36:35 +01:00
Paulus Schoutsen 1c36bf5e19
Fix block till done in create entry config flow tests (#42290) 2020-10-24 16:20:56 +02:00
Franck Nijhof 1c2ebdf307
Upgrade black to 20.8b1 (#39287) 2020-08-27 13:56:20 +02:00
Paulus Schoutsen ec47216388
Use built-in test helpers on 3.8 (#34901) 2020-04-30 13:29:50 -07:00
J. Nick Koston 29383f98b5
Add ability to ignore tado discovery (#34650)
* Add ability to ignore tado discovery

* update test

* Update tests/components/tado/test_config_flow.py

Co-Authored-By: Chris Talkington <chris@talkingtontech.com>

* Update tests/components/tado/test_config_flow.py

Co-Authored-By: Chris Talkington <chris@talkingtontech.com>

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
2020-04-25 17:08:53 -05:00
J. Nick Koston 7a8d1c00a4
Add support for turning on swing mode in tado (#34404) 2020-04-19 12:17:06 +02:00
J. Nick Koston 4b1626a748
Config flow for tado (#33677)
* Config flow for tado

* Add homekit models

* self review fixes

* reduce since the loop is gone

* Update homeassistant/components/tado/water_heater.py

Co-Authored-By: Michaël Arnauts <michael.arnauts@gmail.com>

* Change identifier

* Ensure fallback mode is on by default

* unique ids much be str

Co-authored-by: Michaël Arnauts <michael.arnauts@gmail.com>
2020-04-12 13:42:36 -05:00
J. Nick Koston 3566803d2e
Fix setting zone overlays for tados that support swing (#33439)
* Fix setting zone overlays for tados that support swing

* Support for changing swing mode will come at a later
time as another upstream update is required.

* remove debug

* style
2020-03-31 17:29:45 -05:00
J. Nick Koston f42804805c
Move Tado zone state handling into upstream python-tado library (#33195)
* Tado climate state moved to python-tado

* Resolve various incorrect states and add tests for known tado zone states

* Write state instead of calling for an update

This is a redux of pr #32564 with all of the zone state now moved into
python-tado and tests added for the various states.

* stale string

* add missing undos to dispachers

* remove unneeded hass

* naming

* rearrange

* fix water heater, add test

* fix water heater, add test

* switch hvac mode when changing temp if in auto/off/smart
2020-03-30 09:06:26 -05:00
Michaël Arnauts 8c52e2c923
Revert "Breakout tado zone code into a single place (#32564)" (#32639)
This reverts commit c2b03332a0.
2020-03-10 09:32:56 +01:00
J. Nick Koston c2b03332a0
Breakout tado zone code into a single place (#32564)
* Breakout tado zone code into a single place

* Resolve various incorrect states and add tests for known tado zone states

* Fix home and away presets

* Upgrade to PyTado 0.4.0 which improves http performance and fixes setting fan speed.

* Write state instead of calling for an update

* adjust codeowners

* Add tests for michael's tado and fix heatingPower.value

* Guards are much cleaner

* Adjust per review

* Remove hass passing
2020-03-09 17:44:34 -07:00