Commit Graph

19057 Commits (b35fbd8d20312d33a9599ec691ccd359fab0016f)

Author SHA1 Message Date
Joost Lekkerkerker 5796b651af
Use snapshot test helper in Brother (#115885) 2024-04-20 17:14:42 +02:00
Joost Lekkerkerker 16e31d8f74
Add test helper to snapshot a platform (#115880)
* Add test helper to snapshot a platform

* Add test helper to snapshot a platform
2024-04-20 14:49:57 +02:00
Maciej Bieniek 194f3366ce
Use snapshot testing in NAM sensor and diagnostics (#115877)
* Use snapshot testing in NAM diagnostics

* Use snapshot testing in NAM sensor

* Add NAM data fixture

---------

Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-04-20 12:34:27 +02:00
Maciej Bieniek c4e7a7af21
Use snapshot testing in Brother sensor (#115875)
Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-04-20 12:33:08 +02:00
Maciej Bieniek c2450c1112
Use snapshot testing in GIOS sensor (#115876)
Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-04-20 12:32:11 +02:00
Maciej Bieniek c8d52c02c5
Use snapshot testing in NextDNS (#115879)
* Use snapshot testing in NextDNS sensor

* Use snapshot testing in NextDNS switch

* Use snapshot testing in NextDNS binary sensor

* Use snapshot testing in NextDNS button

---------

Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-04-20 12:31:20 +02:00
Michael 354c20a57b
Automatic cleanup of entity and device registry in AVM FRITZ!SmartHome (#114601) 2024-04-20 12:13:56 +02:00
slyoldfox ebbcad17c6
Add scheduled mode to renault charge mode (#115427)
Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2024-04-19 18:22:12 +02:00
avee87 18d6581523
Fix Hyperion light not updating state (#115389) 2024-04-19 18:21:21 +02:00
Joost Lekkerkerker cc2e0fd921
Make Withings recoverable after internet outage (#115124) 2024-04-19 18:18:32 +02:00
Joost Lekkerkerker c108c7df38
Add reauth flow to Google Tasks (#109517)
* Add reauth flow to Google Tasks

* Update homeassistant/components/google_tasks/config_flow.py

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>

* Add tests

* Reauth

* Remove insta reauth

* Fix

---------

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>
2024-04-19 17:38:39 +02:00
Simone Chemelli ff83d9acff
Add missing media_player features to Samsung TV (#115788)
* add missing features

* fix snapshot
2024-04-19 16:45:19 +02:00
Jan Bouwhuis 5b082ed669
Add group tests with mixed domain entities (#115849) 2024-04-19 14:48:18 +02:00
hahn-th ed4f00279e
Show default profiles in homematic cloud climate entity (#107348)
* Default names for visible profiles

* Increase number of devices in test

* remove unnecessary check

* Add testcase and split another into two

* Add type annotations and docstring

* Remove code which not belongs to the PR

* Add myself to codeowners
2024-04-19 08:09:48 +02:00
Joe Neuman 4cce75177a
Add get_torrents service to qBittorrent integration (#106501)
* Upgrade QBittorrent integration to show torrents

This brings the QBittorrent integration to be more in line with the Transmission integration. It updates how the integration is written, along with adding sensors for Active Torrents, Inactive Torrents, Paused Torrents, Total Torrents, Seeding Torrents, Started Torrents.

* Remove unused stuff

* Correct name in comments

* Make get torrents a service with a response

* Add new sensors

* remove service

* Add service with response to get torrents list

This adds a service with a response to be able to get the list of torrents within qBittorrent

* update

* update from rebase

* Update strings.json

* Update helpers.py

* Update to satisfy lint

* add func comment

* fix lint issues

* another update attempt

* Fix helpers

* Remove unneccesary part in services.yaml and add translations

* Fix return

* Add tests

* Fix test

* Improve tests

* Fix issue from rebase

* Add icon for get_torrents service

* Make get torrents a service with a response

* remove service

* Add service with response to get torrents list

This adds a service with a response to be able to get the list of torrents within qBittorrent

* Update to satisfy lint

* Handle multiple installed integrations

* fix lint issue

* Set return types for helper methods

* Create the service method in async_setup

* Add CONFIG_SCHEMA

* Add get_all_torrents service

* fix lint issues

* Add return types and ServiceValidationError(s)

* Fix naming

* Update translations

* Fix tests
2024-04-19 07:56:37 +02:00
J. Nick Koston 1d6ae01baa
Handle Bluetooth adapters in a crashed state (#115790)
* Skip bluetooth discovery for Bluetooth adapters in a crashed state

* fixes

* fixes

* adjust

* coverage

* coverage

* fix race
2024-04-18 15:06:53 -05:00
J. Nick Koston b18f1ac265
Migrate device_sun_light_trigger to use async_track_state_change_event (#115555)
* Migrate device_sun_light_trigger to use async_track_state_change_event

async_track_state_change is legacy and will eventually be deprecated after
all core usage is removed. There are only two places left

* coverage
2024-04-18 10:45:06 -04:00
J. Nick Koston 588c260dc5
Skip processing websocket_api schema if it has no arguments (#115618)
* Skip processing websocket_api schema if has no arguments

About 40% of the websocket commands on first connection have
no arguments. We can skip processing the schema for these cases

* cover

* fixes

* allow extra

* Revert "allow extra"

This reverts commit 85d9ec36b3.

* match behavior
2024-04-18 10:41:08 -04:00
J. Nick Koston ea8d4d0dca
Add reauth support to oncue (#115667)
* Add reauth support to oncue

* review comments

* reauth on update failure

* coverage
2024-04-18 10:39:58 -04:00
J. Nick Koston 53c48537d7
Add bluetooth adapter model and manufacturer to config flow (#115780)
* Show bluetooth adapter model and manufacturer in config flow

If there are multiple adapters, it could be a bit difficult
to figure out which one is which

* Show bluetooth adapter model and manufacturer in config flow

If there are multiple adapters, it could be a bit difficult
to figure out which one is which

* reorder

* reorder

* names

* remove

* fix incomplete mocking

* more missing mocks
2024-04-18 10:39:32 -04:00
Lukasz Szmit ceaf8f2402
Add support for payload_template in rest component (#107464)
* Add support for payload_template in rest component

* Update homeassistant/components/rest/schema.py

* Update homeassistant/components/rest/data.py

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-18 15:22:58 +02:00
vexofp 8ba1340c2e
Clarify cover toggle logic; prevent opening when already open (#107920)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-18 14:58:16 +02:00
Jan Bouwhuis 3299bc5ddc
Translate service validation errors (#115024)
* Move service validation error message to translation cache

* Fix test

* Revert unrelated change

* Address review comments

* Improve error message

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-18 14:36:03 +02:00
Erwin Douna d5e5a16303
Add diagnostics platform to DSMR Reader (#115805)
* Add diagnostics platform

* Feedback

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-18 14:08:23 +02:00
mkmer 28da10ad0d
Handle connection error in honeywell (#108168)
* Handle connection error

* Catch connection error

* Add tests

* Add translation strings

* Clean up overlapping exceptions

* ServiceValidationError

* HomeAssistant Error translations

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-18 13:53:32 +02:00
J. Nick Koston 0398a481c3
Fix failing sanix tests (#115793)
Fixing failing sanix tests

Regenerate snapshot to match what actually happens. There is no
translation keys for these two
2024-04-18 09:25:03 +02:00
Keith Burzinski 14515b77bb
Add valve entity support for ESPHome (#115341)
Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2024-04-17 20:47:15 -05:00
J. Nick Koston 98ed6e7fe5
Bump habluetooth to 2.7.0 (#115783) 2024-04-17 17:47:40 -05:00
J. Nick Koston b829f1030b
Migrate snooze config flow to use eager_start (#115658) 2024-04-17 14:59:16 -05:00
Joost Lekkerkerker 07a46f17d0
Add sanix sensor tests (#115763)
Add sanix tests
2024-04-17 21:20:12 +02:00
Sid cdc49328be
Address late reviews for the enigma2 config flow (#115768)
* Address late reviews for the enigma2 config flow

* fix tests

* review comments

* test for issues

* Apply suggestions from code review

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

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-17 21:08:10 +02:00
Jan Bouwhuis 8275512130
Add mqtt notify platform (#115653)
* Add mqtt notify platform

* Stale docstring
2024-04-17 20:07:11 +02:00
jan iversen 3202743b6c
Cleanup modbus test mocks (#115412) 2024-04-17 19:10:09 +02:00
Álvaro Fernández Rojas 7e9b5b1128
Allow selecting Air Quality mode for Airzone Cloud (#106769)
* airzone_cloud: add Air Quality mode select

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

* trigger CI

* trigger CI

* Update select.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* airzone_cloud: select: remove AirzoneSelectDescriptionMixin usage

* airzone_cloud: select: rename AIR_QUALITY_DICT

---------

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-17 17:11:29 +02:00
Mike Degatano f1ebe9d20a
Add repairs to hassio manifest (#115486)
* Add repairs to hassio manifest

* Remove unnecessary fixture
2024-04-17 15:51:29 +02:00
Sid be0926b7b8
Add config flow to enigma2 (#106348)
* add config flow to enigma2

* Apply suggestions from code review

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

* fix suggested change

* use parametrize for config flow tests

* Restore PLATFORM_SCHEMA and add create_issue to async_setup_platform

* fix docstring

* remove name, refactor config flow

* bump dependency

* remove name, add verify_ssl, use async_create_clientsession

* use translation key, change integration type to device

* Bump openwebifpy to 4.2.1

* cleanup, remove CONF_NAME from entity, add async_set_unique_id

* clear unneeded constants, fix tests

* fix tests

* move _attr_translation_key out of init

* update test requirement

* Address review comments

* address review comments

* clear strings.json

* Review coments

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-17 15:21:54 +02:00
Erik Montnemery 764a0f29cc
Allow [##:##:##] type keypad address in homeworks (#115762)
Allow [##:##:##] type keypad address
2024-04-17 15:04:37 +02:00
Erik Montnemery e45583b83b
Fix homeworks import flow (#115761) 2024-04-17 15:00:10 +02:00
Erik Montnemery 3f62267a48
Fix flaky qld_bushfire test (#115757) 2024-04-17 14:29:49 +02:00
Tomasz 864c80fa55
Add Sanix integration (#106785)
* Add Sanix integration

* Add Sanix integration

* Add sanix pypi package

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Add Sanix integration

* Fix ruff

* Fix

* Fix

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2024-04-17 14:24:34 +02:00
J. Nick Koston 6dcfe861fd
Bump habluetooth to 2.5.2 (#115721) 2024-04-16 18:34:57 -05:00
Maciej Bieniek e7076ac83f
Use separate data coordinators for AccuWeather observation and forecast (#115628)
* Remove forecast option

* Update strings

* Use separate DataUpdateCoordinator for observation and forecast

* Fix tests

* Remove unneeded variable

* Separate data coordinator classes

* Use list comprehension

* Separate coordinator clasess to add type annotations

* Test the availability of the forecast sensor entity

* Add DataUpdateCoordinator types

* Use snapshot for test_sensor()

---------

Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-04-17 00:00:16 +02:00
Matthew Hallonbacka 4a89e18b7e
Fix check for missing parts on incoming SMS (#105068)
* Fix check for missing parts on incoming SMS

* Add tests for get_and_delete_all_sms function

* Fix CI issues

* Install libgammu-dev in CI

* Bust the venv cache

* Include python-gammu in requirements-all.txt

* Adjust install of dependencies

---------

Co-authored-by: Erik <erik@montnemery.com>
2024-04-16 21:34:09 +02:00
BestPig 586d27320e
Add Sound Mode selection in soundpal components (#106589) 2024-04-16 17:45:48 +02:00
Guido Schmitz 63c9aef71d
Correct spelling of "Wi-Fi" in devolo_home_network (#106167)
* Use Wi-Fi in devolo_home_network

* Recreate snapshots

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-16 16:28:25 +02:00
myMartek 18ac9a7ba5
Add select hold to AppleTVs remote entity as possible command (#105764)
* Fixed home hold and added select hold

* Fixed home hold and added select hold

* Removed select_hold for now

* Fixed wrong import block sorting

* Fixed unit tests for AppleTV

* Added select hold command to AppleTV integration

* Removed home_hold and added hold_secs option for remote commands

* Added DEFAULT_HOLD_SECS

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-16 16:16:32 +02:00
Joost Lekkerkerker e9894f8e91
Add extract media url service to media extractor (#100780)
* Exclude manifest files from youtube media extraction

* Add media_extractor service to extract media

* Fix snapshot

* Run ytdlp async

* Add icon

* Fix

* Fix
2024-04-16 16:13:03 +02:00
Erik Montnemery 7cd0fe3c5f
Don't reload other automations when saving an automation (#80254)
* Only reload modified automation

* Correct check for existing automation

* Add tests

* Remove the new service, improve ReloadServiceHelper

* Revert unneeded changes

* Update tests

* Address review comments

* Improve test coverage

* Address review comments

* Tweak reloader code + add a targetted test

* Apply suggestions from code review

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

* Explain the tests + add more variations

* Fix copy-paste mistake in test

* Rephrase explanation of expected test outcome

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-16 15:58:57 +02:00
Martin Hjelmare 093aee672c
Fix ambient network test linting (#115691) 2024-04-16 10:19:23 +02:00
Thomas Kistler 0dd8ffd1f5
Add a new "Ambient Weather Network" integration (#105779)
* Adding a new "Ambient Weather Network" integration.

* Rebase and update code coverage.

* Addressed some reviewer comments.

* Remove mnemonics and replace with station names.

* Remove climate-utils

* Remove support for virtual stations.

* Rebase

* Address feedback

* Remove redundant errors

* Reviewer feedback

* Add icons.json

* More icons

* Reviewer feedback

* Fix test

* Make sensor tests more robust

* Make coordinator more robust

* Change update coordinator to raise UpdateFailed

* Recover from no station found error

* Dynamically set device name

* Address feedback

* Disable some sensors by default

* Reviewer feedback

* Change from hub to service

* Rebase

* Address reviewer feedback

* Reviewer feedback

* Manually rerun ruff on all files
2024-04-16 09:46:15 +02:00
Stephen Alderman f62fb76765
Add Config Flow to LG Netcast (#104913)
* Add Config Flow to lg_netcast

* Add YAML import to Lg Netcast ConfigFlow

Deprecates YAML config support

* Add LG Netcast Device triggers for turn_on action

* Add myself to LG Netcast codeowners

* Remove unnecessary user_input validation check.

* Move netcast discovery logic to the backend

* Use FlowResultType Enum for tests

* Mock pylgnetcast.query_device_info instead of _send_to_tv

* Refactor lg_netcast client discovery, simplify YAML import

* Simplify CONF_NAME to use friendly name

Fix: Use Friendly name for Name

* Expose model to DeviceInfo

* Add test for testing YAML import when not TV not online

* Switch to entity_name for LGTVDevice

* Add data_description to host field in user step

* Wrap try only around _get_session_id

* Send regular request for access_token to ensure it display on the TV

* Stop displaying access token when flow is aborted

* Remove config_flow only consts and minor fixups

* Simplify media_player logic & raise new migration issue

* Add async_unload_entry

* Create issues when import config flow fails, and raise only a single yaml deprecation issue type

* Remove single use trigger helpers

* Bump issue deprecation breakage version

* Lint

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-16 09:29:02 +02:00
brave0d a99ecb024e
New BMW sensor for climate activity (#110287)
* add sensor with climate activity status

* Update strings.json

* use icon translation and is_available for sensor

* use enum with translations

* Return None if value is UNKNOWN

* fix getting the value: x.value

* fix getting the value: x instead of x.value

* Fix tests and pre-commit

---------

Co-authored-by: Richard <rikroe@users.noreply.github.com>
2024-04-16 09:24:32 +02:00
Tom Harris c5c407b3bb
Move Insteon configuration panel to config entry (#105581)
* Move Insteon panel to the config menu

* Bump pyinsteon to 1.5.3

* Undo devcontainer.json changes

* Bump Insteon frontend

* Update config_flow.py

* Code cleanup

* Code review changes

* Fix failing tests

* Fix format

* Remove unnecessary exception

* codecov

* Remove return from try

* Fix merge mistake

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-04-16 09:10:32 +02:00
Collin Fair 4aab073bd2
Remove cloud dependency from `islamic-prayer-times` (#115146)
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-15 15:42:33 -05:00
Sid 5f055a64bb
Enable Ruff B017 (#115335) 2024-04-15 22:25:09 +02:00
J. Nick Koston 15ecd3ae31
Fix flaky zwave update entity delay test (#115552)
The test assumed the node updates would happen in a specific order
but they can switch order based on timing.

Adjust to check to make sure all the nodes are called but make it
order independent
2024-04-15 13:12:09 +02:00
Brett Adams 5e1de6842d
Fix Teslemetry sensor values (#115571) 2024-04-15 01:48:22 +02:00
Arie Catsman 6092894ce5
For new installs make enphase_envoy phase entities default disabled (#115577) 2024-04-14 10:41:00 -05:00
Shay Levy 291df6dafe
Bump aioshelly to 9.0.0 (#114025)
* Update Shelly to use initialize from aioshelly

* Save indentation in _async_device_connect

* Use firmware_supported property from aioshelly

* Review comments

* Bump aioshelly

* Fix lint errors

* Test RPC initialized update
2024-04-14 18:07:26 +03:00
Sid 0200d1aa66
Unignore Ruff UP006, UP007 (#115533) 2024-04-14 00:26:58 -05:00
Sid c24ae01a43
Unignore Ruff E731 (#115564) 2024-04-14 00:15:10 -05:00
Sid 3799d20d43
Enable Ruff B905 (#114197) 2024-04-14 00:14:26 -05:00
Mr. Bubbles 927ea14562
Add exception translations to Bring integration (#115547)
* Add exception translations

* Add test for exceptions

* Remove unnecessary logging
2024-04-14 00:26:37 +02:00
J. Nick Koston 4955364948
Fix advantage_air disabled entity tests (#115548)
* Fix advantage_air disabled entity test

* fix both
2024-04-13 18:13:19 -04:00
J. Nick Koston 0b3627b59e
Add additional cached_property to camera entities (#115075) 2024-04-13 16:50:11 -05:00
J. Nick Koston dee99c764b
Complete ESPHome media_player coverage (#114352) 2024-04-13 16:29:14 -05:00
J. Nick Koston ee535ee611
Ensure test async_create_task eager start behavior matches production (#115517) 2024-04-13 15:58:52 -05:00
J. Nick Koston 0bd4064212
Update ollama config_flow task to use eager_start (#115455)
The test now adds a delay because it finished too fast
2024-04-13 16:54:21 -04:00
J. Nick Koston f452c5b84e
Add forecast subscription failure test case to nws (#115541) 2024-04-13 15:48:23 -05:00
J. Nick Koston f1ac33c246
Fix unmocked remote socket calls in sunweg tests (#115546)
Fix unmocked calls in sunweg tests
2024-04-13 16:36:33 -04:00
J. Nick Koston 008c42e282
Bump py-synologydsm-api to 2.4.2 (#115499)
Co-authored-by: mib1185 <mail@mib85.de>
2024-04-13 14:38:37 -05:00
Jan Bouwhuis 197070486f
Set up notify group with the notify services in test (#115526) 2024-04-13 17:10:16 +02:00
Jan Bouwhuis 36bdda5669
Migrate demo notify platform (#115448)
* Migrate demo notify platform

* Update homeassistant/components/demo/notify.py

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

* Remove no needed tests

* Cleanup redundant attribute assignment

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2024-04-13 14:27:07 +02:00
Jan Bouwhuis 38c7b99aef
Make legacy notify group tests independent of demo platform (#115494) 2024-04-13 12:58:31 +02:00
Toni Korhonen 84a975b61e
Add Balboa spa temperature range state control (high/low) (#115285)
* Add temperature range switch (high/low) to Balboa spa integration.

* Change Balboa spa integration temperature range control from switch to select

* Balboa spa integration: Fix ruff formatting

* Balboa spa integration: increase test coverage

* Balboa spa integration review fixes: Move instance attributes as class attributes. Fix code comments.
2024-04-13 10:44:02 +02:00
Jan Bouwhuis 127c27c9a7
Isolate legacy notify tests (#115470)
* Isolate legacy notify tests

* Rebase

* Refactor
2024-04-13 10:14:58 +02:00
J. Nick Koston bb9330135d
Fix race in influxdb test (#115514)
The patch was still too late in #115442

There is no good candidate to patch here since the late operation
is the error log that is being tested.

Patching the logger did not seem like a good idea so I went with
patching to wait for the error to be emitted since emit is the public
API of the log handler and was less likely to change
2024-04-13 09:13:01 +02:00
Jan Bouwhuis 76fefaafb0
Move out demo notify tests to the notify platform (#115504)
* Move test file

* Make independent of demo platform

* Restore tests for demo platform for coverage
2024-04-13 08:18:45 +02:00
Sid d74be6d5fe
Set Ruff RUF001-003 to ignore (#115477) 2024-04-13 00:51:36 +02:00
dontinelli 6eaf3402c6
Add re-auth-flow to fyta integration (#114972)
* add re-auth-flow to fyta integration

* add strings for reauth-flow

* resolve typing error

* update based on review comments

* Update homeassistant/components/fyta/config_flow.py

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

* add async_auth

* adjustment based on review commet

* Update test_config_flow.py

* remove credentials

* Update homeassistant/components/fyta/config_flow.py

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

* Update tests/components/fyta/test_config_flow.py

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

* Update tests/components/fyta/test_config_flow.py

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

* Update conftest.py

* Update test_config_flow.py

* Aktualisieren von conftest.py

* Update test_config_flow.py

---------

Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2024-04-12 20:33:24 +02:00
Brett Adams b266224ccd
Add diagnostics to Teslemetry (#115195)
* Add diag

* Add diag and tests

* Fix redaction

* Add another energy redact

* Review Feedback

* Update snapshot

* Fixed the wrong integration

* Fix snapshot again

* Update tests/components/teslemetry/test_diagnostics.py

---------

Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2024-04-12 20:27:38 +02:00
Robert Resch 348e1df949
Add strict connection (#112387)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-12 14:47:46 +02:00
Jan Bouwhuis a213de3db5
Add service schema tests for notify entity platform (#115457)
* Add service schema tests for notify entity platform

* Use correct entity

* Assert on exception value
2024-04-12 10:40:17 +02:00
Sid 9bf87329da
Enable Ruff FLY002 rule (#115112)
Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
2024-04-12 09:04:16 +02:00
Joost Lekkerkerker adafdb2b2d
Use enum device class in Netatmo health index sensor (#115409) 2024-04-12 08:40:27 +02:00
Joost Lekkerkerker 6cc2b1e10a
Use enum device class in Netatmo wind direction (#115413)
* Use enum device class in Netatmo wind direction

* Use enum device class in Netatmo wind direction

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-12 08:39:59 +02:00
Allen Porter c7cb0237d1
Fix bug in rainbird switch when turning off a switch that is already off (#115421)
Fix big in rainbird switch when turning off a switch that is already off

Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-11 22:14:52 -04:00
J. Nick Koston e3680044fe
Fix flakey influxdb test (#115442) 2024-04-11 13:26:03 -10:00
J. Nick Koston 2e8f4743eb
Fix flakey mobile app webhook test (#115447) 2024-04-11 12:17:01 -10:00
Sid a093f943d7
Use library classes instead of namedtuple in ipma tests (#115372) 2024-04-12 01:03:10 +03:00
J. Nick Koston 137514edb7
Bump aiohttp to 3.9.4 (#110730)
* Bump aiohttp to 3.9.4

This is rc0 for now but will be updated when the full release it out

* cleanup cruft

* regen

* fix tests (these changes are fine)

* chunk size is too small to read since boundry is now enforced

* chunk size is too small to read since boundry is now enforced
2024-04-11 11:58:56 -10:00
Allen Porter 6c1bc2a9f4
Reduce scope of diagnostics tests for rtsp_to_webrtc to not depend on global state (#115422) 2024-04-11 18:13:39 +02:00
Jan Bouwhuis 10076e6523
Add notify entity component (#110950)
* Add notify entity component

* Device classes, restore state, icons

* Add icons file

* Add tests for kitchen_sink

* Remove notify from no_entity_platforms in hassfest icons, translation link

* ruff

* Remove `data` feature

* Only message support

* Complete initial device classes

* mypy pylint

* Remove device_class implementation

* format

* Follow up comments

* Remove _attr_supported_features

* Use setup_test_component_platform

* User helper at other places

* last comment

* Add entry unload test and non async test

* Avoid default mutable object in constructor
2024-04-11 12:04:08 +02:00
Mike Degatano 5308e02c99
Add support for adopt data disk repair (#114891) 2024-04-11 11:23:10 +02:00
Steven B 6954fcc8ad
Add strict typing to ring integration (#115276) 2024-04-11 10:10:56 +02:00
Jan Bouwhuis 3546ca386f
Use freezer on diagnostics test (#115398)
* Use freezer on diagnostics test

* Patch correctly
2024-04-11 09:40:16 +02:00
Joost Lekkerkerker 4224234b7a
Add binary sensor to Netatmo (#115119)
* Add binary sensor to Netatmo

* Update homeassistant/components/netatmo/binary_sensor.py

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>

* Sigh

* Fix

* Fix

* Fix

---------

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>
2024-04-11 07:46:07 +02:00
J. Nick Koston e17c4ab4e3
Fix flakey tessie media_player test (#115391) 2024-04-10 14:18:11 -10:00
Jan Bouwhuis be8adf9d29
Fix zha test by tweaking the log level (#115368) 2024-04-10 13:10:46 -10:00
jan iversen 220801bf1c
Secure against resetting a non active modbus (#115364) 2024-04-10 22:09:10 +02:00
jan iversen 8d6473061c
Solve modbus test problem (#115376)
Fix test.
2024-04-10 21:39:53 +02:00
J. Nick Koston 63545ceaa4
Ensure automations do not execute from a trigger if they are disabled (#115305)
* Ensure automations are stopped as soon as the stop future is set

* revert script changes and move them to #115325
2024-04-10 08:42:18 -04:00
Shay Levy a6b93ea8ac
Fix Aranet failure when the Bluetooth proxy is not providing a device name (#115298)
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-10 14:58:35 +03:00
Joakim Sørensen 012509f683
Add documentation link for custom integrations in diagnostics (#115336)
* Add documentation link for custom integrations in diagnostics

* Enable custom integrations in test_download_diagnostics
2024-04-10 11:36:25 +02:00
Sid 3efee10b95
Enable Ruff RUF013 (#115333) 2024-04-10 08:55:59 +02:00
Joost Lekkerkerker 7e1a5b19c4
Add entity translations to Netatmo (#115104)
* Add entity translations to Netatmo

* Yes

* Remove

* Fix name
2024-04-10 08:50:27 +02:00
Sid d61db732da
Enable Ruff SLOT rules (#115043) 2024-04-09 18:57:27 -10:00
Collin Fair 0636ba340c
Fix flakiness of test_measure_sliding_window (#115322) 2024-04-09 18:28:06 -10:00
Luke Lashley 968de08e4b
Bump python-roborock to 1.0.0 (#115324)
* refactor base code

* refactor tests code
2024-04-09 20:50:46 -04:00
Joost Lekkerkerker 763df83cdb
Remove Nextbus YAML import (#115277) 2024-04-09 18:34:35 +02:00
Joost Lekkerkerker e7c247f1f0
Remove Twitch YAML import (#115278) 2024-04-09 18:34:29 +02:00
Paulus Schoutsen 2df6f1849f
Add OpenAI conversation entity (#114942)
* Add OpenAI conversation entity

* Add migration
2024-04-09 11:10:03 -04:00
Jesse Hills 68384bba67
Send/receive Voice Assistant audio via ESPHome native API (#114800)
* Protobuf audio test

* Remove extraneous code

* Rework voice assistant pipeline

* Move variables

* Fix reading flags

* Dont directly put to queue

* Bump aioesphomeapi to 24.0.0

* Update tests

- Add more tests for API pipeline
- Convert some udp tests to use api pipeline
- Update fixtures for new device info flags

* Fix bad merge

---------

Co-authored-by: Michael Hansen <mike@rhasspy.org>
2024-04-09 10:55:59 -04:00
Steven B 4cd2351bcc
Update and migrate ring non string unique ids (#115265)
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-08 23:08:46 -10:00
Steven B bf3eb463ae
Wrap tplink exceptions caused by user actions inside HomeAssistantError (#114919) 2024-04-08 22:35:25 -10:00
On Freund a852a38d24
Configurable maximum concurrency in Risco local (#115226)
* Configurable maximum concurrency in Risco local

* Show advanced Risco options in advanced mode
2024-04-09 09:59:27 +02:00
Robert Contreras af7d0187cb
Add tests to Home Connect integration (#114214)
* Add tests to Home Connect integration

* Fix misspelling

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

* Changes to tests with properly setup fixtures.

* Consolidated api tests, patched library instead of code

* Consolidate sensor edge cases, switch mock assertion to call_count

* Adjust assertion

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-09 08:52:39 +02:00
Allen Porter 4a7a22641e
Fix Google Tasks parsing of remove responses (#115258) 2024-04-09 07:39:31 +02:00
Jan-Philipp Benecke 44f8dbf86b
Fix failing escea test in connection with greeneye_monitor (#115237)
* Fix failing escea test in connection with greeneye_monitor

* typing
2024-04-08 22:11:14 +02:00
J. Nick Koston ca5ed274cb
Deprecate calling async_listen and async_listen_once with run_immediately (#115169) 2024-04-08 10:07:54 -10:00
Luke Lashley 5ef42078a3
Add a service to get maps for Roborock (#111478)
* add service to get rooms

* fix linting

* add snapshot

* change map id
2024-04-08 21:40:59 +02:00
Sid 9cbed10372
Enable Ruff PYI041 (#115229) 2024-04-08 09:29:05 -10:00
Marc Mueller a52a80f806
Always include old_state in EventStateChangedData [tests] (#115098) 2024-04-08 08:25:22 -10:00
Thomas55555 017b2fe685
Change scan interval for Husqvarna Automower (#115225)
* Change scan interval for Husqvarna Automower

* Also use const
2024-04-08 20:22:09 +02:00
Luca Angemi fc1ebdaaa3
Add config message items selector to imap option flow (#115108)
* Update const.py

* Update config_flow.py

* Update coordinator.py

* Update coordinator.py

* Update strings.json

* Update config_flow.py

* Update const.py

* Update coordinator.py

* Update config_flow.py

* Update config_flow.py

* Update test_diagnostics.py

* Update const.py

* Update test_init.py

* Update test_diagnostics.py

* Update test_diagnostics.py

* Update test_diagnostics.py

* Update test_init.py

* Update test_diagnostics.py

* Update test_init.py

* Update test_diagnostics.py

* Update test_diagnostics.py

* Update test_diagnostics.py

* Update test_config_flow.py

* Update config_flow.py

* Update test_config_flow.py

* Update test_init.py

* Update const.py

* Only make text and headers optional

* Add message data tests

* Add message data test

* Update test_config_flow.py

* Update test message data

* Fix ruff

* Fix ruff

* Update test_init.py

* Update strings.json

---------

Co-authored-by: jbouwh <jan@jbsoft.nl>
Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
2024-04-08 19:34:50 +02:00
Kim de Vos f23e48f373
Add sensor for CPU and memory utilization for unifi device (#114986)
Add system stats to unifi device sensors
2024-04-08 19:29:54 +02:00
Paulus Schoutsen f9a7e6bb9f
Add migration logic to assist_pipeline (#115172) 2024-04-08 11:29:55 -04:00
Illia cbaef096fa
Add Arve integration (#113156)
* add Arve integration

* Update homeassistant/components/arve/config_flow.py

Co-authored-by: Josef Zweck <24647999+zweckj@users.noreply.github.com>

* Various fixes, changed scan interval to one minute

* coordinator implementation

* Code cleanup

* Moved device info to the entity.py, ArveDeviceEntityDescription to sensor.py

* delete refresh before adding entities

Co-authored-by: Josef Zweck <24647999+zweckj@users.noreply.github.com>

* Update tests/components/arve/test_config_flow.py

Co-authored-by: Josef Zweck <24647999+zweckj@users.noreply.github.com>

* Update tests/components/arve/conftest.py

Co-authored-by: Josef Zweck <24647999+zweckj@users.noreply.github.com>

* Changed value_fn in sensors.py, added typing to description

* Code cleanups, platfrom test implementation

* New code cleanups, first two working tests

* Created platform test, generated snapshots

* Reworked integration to get all of the customer devices

* new fixes

* Added customer id, small cleanups

* Logic of setting unique_id to the config flow

* Added test of abortion on duplicate config_flow id

* Added "available" and "device" properties fro ArveDeviceEntity

* small _attr_unique_id fix

* Added new test, improved mocking, various fixes

* Various cleanups and fixes

* microfix

* Update homeassistant/components/arve/strings.json

* ruff fix

---------

Co-authored-by: Josef Zweck <24647999+zweckj@users.noreply.github.com>
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-08 17:24:32 +02:00
Sid f8b6629b26
Enable Ruff PGH rules (#115091) 2024-04-08 15:42:22 +02:00
Erwin Douna 85b453b86c
Fix Downloader test cases and error title (#114847)
* Fix test cases

* Return value

* isdir change

* FIx test cases and error title

* Removing patch

* Tiny needless fine-tuning
2024-04-08 15:28:07 +02:00
Jan Bouwhuis d9dada4fb3
Remove condition from ecobee humidifier attribute test (#115197)
Remove conditions from ecobee humidifier attribute test
2024-04-08 14:33:24 +02:00
gibwar e403b50ddc
Only reset requested utility meter with no tariff (#115170) 2024-04-08 10:05:46 +02:00
Jan Bouwhuis 8b5177e989
Add IMAP fetch service (#115127)
* Add IMAP fetch service

* Fix docstr
2024-04-08 09:50:28 +02:00
Brett Adams 1cace9a609
Add reauth to Teslemetry (#114726)
* Add reauth

* Add tests

* PARALLEL_UPDATES

* Bump quality to platinum

* Fix assertion

* Remove quality

* Remove async_create_task

* Review Feedback

* Remove loop inside parametrize

* Change config during reauth

* Fix missing return
2024-04-08 09:44:51 +02:00
Richard Kroegel 16fc935c87
Refactor BMW entity availability (#110294)
Co-authored-by: Richard <rikroe@users.noreply.github.com>
2024-04-08 09:26:50 +02:00
MarkGodwin 487480dc88
Address late review of TP-Link Omada (#115121)
tplink_omada implement feedback from #114138
2024-04-08 06:26:20 +02:00
J. Nick Koston 3daecc7a31
Remove remaining run_immediately=False from tests (#115168) 2024-04-07 16:47:41 -10:00
J. Nick Koston 1fd5f64dcc
Migrate matrix to use run_immediately for start listener (#115167)
* Migrate matrix to use run_immediately for start listener

* Migrate matrix to use run_immediately for start listener
2024-04-07 22:30:54 -04:00
J. Nick Koston af1023074e
Add an event_filter to google_assistant state reporting (#115160)
* adjust

* fix test since it happens sooner now

* remove debug

* remove unneeded test change

* reduce

* reduce
2024-04-07 21:30:03 -04:00
J. Nick Koston 6b4457043d
Deprecate async_add_hass_job (#115061) 2024-04-07 14:08:25 -10:00
J. Nick Koston 213cf76781
Fix flakey fritz image test (#115161) 2024-04-07 13:46:38 -10:00
J. Nick Koston d007b175c5
Write timer entity state before firing events (#115151) 2024-04-07 12:51:59 -10:00
Sid 8e98ba7312
Add first batch of Ruff PYI rules (#115100)
Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
2024-04-07 11:30:50 -10:00
Joost Lekkerkerker 9ec4e9a1a9
Remove Color extractor import flow (#115015)
* Remove Color extractor import flow

* Remove Color extractor import flow
2024-04-07 19:38:56 +02:00
wittypluck 63d43a9384
Add Glances network sensors (#114546)
* Add Glances network sensors

* Add unit test for network and remove unused MOCK_DATA

* Add network icons
2024-04-07 16:01:00 +02:00
Joost Lekkerkerker 32d62e477a
Add entity translations to Bluemaestro (#102424)
* Add entity translations to Bluemaestro

* Fix

* yes
2024-04-07 15:54:22 +02:00
J. Nick Koston 5630b3611d
Add an event filter to the alexa state report state change listener (#115076)
Co-authored-by: jbouwh <jan@jbsoft.nl>
2024-04-07 03:14:18 -10:00
Tobias Sauerwein f617000920
Add device removal capability for Netatmo (#107630)
* Add device removal capability for Netatmo

* Update tests/components/netatmo/test_init.py

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

* Update tests/components/netatmo/test_init.py

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

* Update tests/components/netatmo/test_init.py

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

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-07 15:10:00 +02:00
Álvaro Fernández Rojas d4d06c0bc3
Add Water Heater support for Airzone Cloud (#115097)
* airzone_cloud: add Water Heater support

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

* run CI

---------

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-04-07 15:07:40 +02:00
fhoekstra e4fbe539aa
Add GPU sensor to Glances (#106322)
* feat: add GPU sensor to Glances

* Add translations to Glances GPU sensor

* Fix translations of GPU processor and memory usage

* PR feedback: move icons to icons.json

thanks to @wittypluck

* Update glances snapshot with added GPU

* Remove JSON trailing comma

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

* Limit precision of Glance GPU mem usage sensor

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

* Clean up outdated snapshots

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-07 15:05:22 +02:00
Joost Lekkerkerker 1b07d3ecfa
Enable entities in Netatmo snapshot test (#115105) 2024-04-07 14:38:40 +02:00
Joost Lekkerkerker 021eed66f3
Add more base entities to netatmo (#107862)
* Rename netatmo base entity file

* Add more Netatmo base entities

* Add more Netatmo base entities

* Add more Netatmo base entities

* Add more Netatmo base entities

* Apply suggestions from code review

* Add more Netatmo base entities

* Add snapshot tests to Netatmo platforms

* Add snapshot tests to Netatmo platforms

* Fix snapshots

* Fix tests

* Update snapshots

* Add fans

* Add fans

* Update homeassistant/components/netatmo/select.py

Co-authored-by: Tobias Sauerwein <cgtobi@users.noreply.github.com>

* Add snapshot tests to Netatmo platforms

* Update snapshots

* minor clean up

* Fix tests

* Fix

* Fix

* Fix

* Move dot split to weather station sensors

---------

Co-authored-by: Tobias Sauerwein <cgtobi@users.noreply.github.com>
Co-authored-by: Tobias Sauerwein <cgtobi@gmail.com>
2024-04-07 13:36:12 +02:00
Joost Lekkerkerker 9f2fa7ec19
Add snapshot tests to Bluemaestro (#115094) 2024-04-07 13:19:40 +02:00
J. Nick Koston b456a212eb
Fix flakey tests using the _get_diagnostics_for_config_entry helper (#115069) 2024-04-06 21:58:23 -10:00
J. Nick Koston 8e645c9b32
Fix flakey cast discovery test (#115063) 2024-04-06 13:15:14 -10:00
Pete Sage 553c147933
Fix sonos switch test failures (#115052) 2024-04-06 12:51:21 -10:00
J. Nick Koston c4b5a7c027
Migrate start helper to use run_immediately (#115055) 2024-04-06 12:35:46 -10:00
wittypluck 3ef2c464ac
Add Glances DiskIO read/write sensors (#114933) 2024-04-07 00:13:02 +02:00
Kevin Stillhammer cce8e4839a
Add reconfigure step for waze_travel_time (#114885)
* Add reconfigure step for waze_travel_time

* Add reconfigure_successful string

* Update tests/components/waze_travel_time/test_config_flow.py

---------

Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2024-04-07 00:06:30 +02:00
Álvaro Fernández Rojas 9a1b0874fd
Update aioairzone-cloud to v0.5.1 (#115029)
* Update aioairzone-cloud to v0.5.1

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

* tests: airzone_cloud: fix diagnostics

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

---------

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-04-06 23:37:22 +02:00
mkmer 7f8341e03a
Deprecate aux heat from Honeywell (#114110)
* Remove aux heat

* Add switch entity for emheat

* Optimized async_setup_entry

* Fix errors in comments

* Fix new ruff failuer

* Use constant for EM

* Protect EM mode - must be in heat to turn on/off

* Restore aux_heat

* Add repair issue

* Add missing place holder to issue

* Better placeholder "option"
2024-04-06 17:22:56 +02:00
Joost Lekkerkerker b743a86aa9
Refactor Vilfo tests (#115020)
* Refactor Vilfo tests

* Patch is_host_valid
2024-04-06 15:48:52 +02:00
Øyvind Matheson Wergeland fdef3ece13
Fix placeholder quotes (#114974)
* When quoting placeholders, always use double quotes so Lokalise recognizes the placeholder.

* Ensure that strings does not contain placeholders in single quotes.

* Avoid redefining value

* Moved string_with_no_placeholders_in_single_quotes

* Define regex once

* Fix tests
2024-04-06 13:01:56 +02:00
Álvaro Fernández Rojas bd9070be11
Update aioairzone-cloud to v0.5.0 (#114928) 2024-04-06 12:24:00 +02:00
Nathan Spencer 6594d022ba
Bump pylitterbot to 2023.4.11 (#114918) 2024-04-06 12:16:00 +02:00
Sid 0d66d298ec
Enable Ruff RET504 (#114528)
* Enable Ruff RET504

* fix test

* Use noqa instead of cast

* fix sonos RET504

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-06 11:07:37 +02:00
Claudio Ruggeri - CR-Tech a28731c294
Add Swing Mode Feature to Modbus integration (#113710) 2024-04-06 11:01:44 +02:00
J. Nick Koston 657bc969a3
Improve performance of system_log traceback handling (#114992) 2024-04-05 16:47:17 -10:00
J. Nick Koston fb98a6f026
Make run_immediately the default for core EventBus listeners (#113752)
* DNM: Make run_immediately the default for listeners

This is a test to see how much progress we have made twords this goal

https://github.com/home-assistant/core/pull/113727#issuecomment-2004587947

* fix shutdown

* Revert "fix shutdown"

This reverts commit a8969d7db9.

* set false since it break utility meter tests

* one more

* fix rfxtrx test

* test needs to be explict now

* fix matrix

* fail sooner
2024-04-05 22:14:20 -04:00
Brent Petit c9ce848b4b
Add current_humidity to Ecobee humidifier (#114753)
* Ecobee: add current_humidity to humidifier

* Ecobee: Add test for current_humidity property

* Update current_humidity handling in climate and
humidifier entity to support the ecobee API
not returning actualHumidity, which is an optional
value.
Also updated tests to add a thermostat which
covers a non-populated humidity. In passing,
set up the new test thermostat to cover a missing
condition where the code doens't recognize the
ecobee model number. This gets ecobee humidifier
test coverage to 100%
2024-04-05 21:54:40 +02:00
Joost Lekkerkerker 0214511b38
Make config flow imports consistent (#114962)
* Make config flow imports consistent

* Fix
2024-04-05 21:38:11 +02:00
epenet 9204ccfa17
Use is in ConfigEntryState enum comparison in tests (N-Z) (#114926) 2024-04-05 17:37:00 +02:00
Ashot Tonoyan f2c091fe0c
Include serial number in HomeKit device info (#114688)
Very useful when adding a hub that has many identical devices already paired
2024-04-05 17:32:23 +02:00
epenet 0b01326f9f
Use is in ConfigEntryState enum comparison in tests (A-M) (#114925) 2024-04-05 17:16:55 +02:00
Joost Lekkerkerker 69f8de2c59
Create right import issues in Downloader (#114922)
* Create right import issues in Downloader

* Create right import issues in Downloader

* Create right import issues in Downloader

* Create right import issues in Downloader

* Fix

* Fix

* Fix

* Fix

* Apply suggestions from code review

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

* Fix

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-05 12:32:09 +02:00
Joost Lekkerkerker 772d9f754a
Fix Downloader YAML import (#114844) 2024-04-05 11:32:59 +02:00
epenet 24f83c5890
Use is in FlowResultType enum comparison in tests (#114917)
* Use is in FlowResultType enum comparison in tests

* Adjust auth

* Adjust systemmonitor

* Once more

* Add comment
2024-04-05 10:40:14 +02:00
Lex Li 1f37774352
Fix type cast in snmp (#114795) 2024-04-05 08:41:15 +02:00
J. Nick Koston 5447a1a015
Ensure all tables have the default table args in the db_schema (#114895) 2024-04-05 08:22:00 +02:00
J. Nick Koston d321906342
Always run keyed event trackers immediately (#114709) 2024-04-04 15:30:01 -10:00
J. Nick Koston 78920e1d71
Reduce august polling frequency (#114904)
Co-authored-by: TheJulianJES <TheJulianJES@users.noreply.github.com>
2024-04-04 15:28:36 -10:00
Marc Mueller 3c5089bc3f
Update import for EventStateChangedData [a-h] (#114899) 2024-04-04 11:48:36 -10:00
J. Nick Koston e0e54ab9d3
Migrate more sonos tasks to use eager_start (#114697) 2024-04-04 11:43:15 -10:00
Pete Sage 95ef087fa8
Fix Sonos Tests failing intermittently on CI (#114873) 2024-04-04 10:34:23 -10:00
Michael Hansen 1c2499b03a
Add "conversation" key to translations (#114887)
* Use translated trigger response

* Use conversation key instead
2024-04-04 14:45:27 -05:00
J. Nick Koston aedfd6c983
Add index for floor/label to the area registry (#114777) 2024-04-03 21:04:26 -10:00
J. Nick Koston 0c3ccabfb1
Speed up logger setup (#114610)
* Speed up logger setup

Preload core.logger and avoid saving it
until after startup

* add comment about 180s

* Adjust grammar

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-04 08:35:44 +02:00
J. Nick Koston e86fec310b
Improve performance of extracting entities by label (#114720) 2024-04-03 10:24:44 -10:00
Chris Bräucker 51a3e79048
Add wake on LAN via Fritz!Box for tracked devices (#106778) 2024-04-03 18:37:20 +02:00
Lenn e870d420a6
Rename Motionblinds BLE integration to Motionblinds Bluetooth (#114584) 2024-04-03 12:11:46 +02:00
Robert Resch 74d8c6cce4
Fix synology_dsm test side effects (#114722) 2024-04-03 11:11:56 +02:00
Joost Lekkerkerker f3ba713289
Use FlowResultType enum in config flow tests N-Z (#114682)
Use FlowResultType enum in config flow tests
2024-04-03 09:53:20 +02:00
Joost Lekkerkerker b9281327c4
Use FlowResultType enum in config flow tests A-M (#114681) 2024-04-03 09:21:17 +02:00
Erik Montnemery d058615961
Add service homeworks.send_command (#114059)
* Add service homeworks.send_command

* Translate exception
2024-04-03 09:10:10 +02:00
Pete Sage f26a7843c6
Fix Sonos play imported playlists (#113934) 2024-04-03 00:10:15 +02:00
Joost Lekkerkerker 9b41e3d124
Use is in enum comparison in config flow tests A-E (#114669) 2024-04-02 11:22:05 -10:00
Joost Lekkerkerker ee66f6ec8c
Use is in enum comparison in config flow tests P-T (#114675) 2024-04-02 11:21:50 -10:00
Joost Lekkerkerker 5d500cb74b
Use is in enum comparison in config flow tests K-O (#114672) 2024-04-02 11:21:42 -10:00
Dos Moonen 3875533f95
Bump solax to 3.1.0 (#114617)
0.3.2 was succeeded by 0.3.4.
0.3.3 was yanked
0.3.4 was succeeded by 3.0.5.
3.0.5 is succeeded by 3.1.0.
2024-04-02 23:16:39 +02:00
Joost Lekkerkerker 2ef0521d3d
Use is in enum comparison in config flow tests U-Z (#114677)
* Use right enum expression U-Z

* Fix
2024-04-02 23:09:56 +02:00
Jan Bouwhuis 83b56ab005
Add IMAP seen, move and delete service (#114501)
* Add seen, move and delete IMAP services

* Add entry_id to the imap_content event data

* Use config validation library

* Add tests

* Add logging

* Typo in docstr

* Add guard
2024-04-02 23:05:05 +02:00
Joost Lekkerkerker 906d3198e3
Use is in enum comparison in config flow tests F-J (#114670)
* Use right enum expression F-J

* Fix
2024-04-02 23:01:37 +02:00
Phil Bruckner ea2bb24484
Remove old device tracker device cleanup code & test (#114668) 2024-04-02 15:23:59 -05:00
Joost Lekkerkerker 2175cd6039
Add tests for Roomba Options flow (#114666)
* Add tests for Roomba Options flow

* Fix
2024-04-02 21:49:53 +02:00
Aidan Timson 17f0002549
Azure DevOps integration tests (#114577)
* Add tests to azure devops

* Remove Azure DevOps files from coverage

* Add assertion for entity registration in test_sensors()

* Remove unnecessary code in test_sensor.py

* Refactor test_sensors function

* Fix

* Test unique id

* Refactor

* Refactor reauth_flow test in azure_devops module

* Suggested changes, batched

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

* Changes

* Use snapshot

* Remove redundant entry fetch

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-04-02 21:23:55 +02:00
Robert Resch f85511255c
Fix Rpi_power test race condition (#114662) 2024-04-02 21:19:43 +03:00
jayme-github 850dac0655
Don't overwrite target temperature by setting hvac mode in AVM Fritz!SmartHome (#112119) 2024-04-02 20:14:02 +02:00
atlflyer ef7836be73
Add icon to command_line cover config (#114645)
* Add icon to command_line cover config

* Remove unwanted #noqa tag

* Remove redundancy from new test name

* Apply requested changes
2024-04-02 20:59:57 +03:00
Robert Resch 17625dc74d
Fix Google translate TTS test race condition (#114656) 2024-04-02 18:52:41 +02:00
Paulus Schoutsen 52bd3efad9
Clean up unnecessary setup calls in tests (#114644) 2024-04-02 17:30:41 +02:00
Joost Lekkerkerker 0b7d9d6c44
Remove YAML configuration from Withings (#114626)
* Remove YAML configuration from Withings

* Remove YAML configuration from Withings

* Remove YAML configuration from Withings
2024-04-02 13:36:44 +02:00
Brett Adams f36c37a3b7
Fix battery heater in Tessie (#114568) 2024-04-02 12:23:08 +02:00
Jan Bouwhuis acf2f855fe
Raise ServiceValidationError on number out of range exception (#114589) 2024-04-02 12:22:00 +02:00
Joakim Sørensen a1ae4ec23d
Add sensor entities to Traccar Server (#111374) 2024-04-02 12:11:28 +02:00
Joost Lekkerkerker 21c7cc3250
Bump roombapy to 1.8.1 (#114478)
* Bump roombapy to 1.7.0

* Bump

* Bump

* Fix
2024-04-02 11:15:52 +02:00
Robert Resch 67c334f842
Fix ruff issue in sonos (#114616) 2024-04-02 10:30:01 +02:00
Maciej Bieniek c8f282c8bc
Improve Shelly RPC device update progress (#114566)
Co-authored-by: Shay Levy <levyshay1@gmail.com>
Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-04-02 10:15:58 +02:00
Pete Sage 31cd41adb8
Display sonos album title with URL encoding (#113693)
* unescape the title

When extracting the title from the item_id, it needs to be unescaped.

* sort imports
2024-04-02 10:11:45 +02:00
mkmer 078535e1d6
Add diagnostic platform to Whirlpool (#114578)
* Add diagnostic platform and tests

* lowercase variable

* Correc doc string
2024-04-02 09:41:40 +02:00
Erik Montnemery 0030c97f59
Tweak integration sensor (#114384)
* Tweak integration sensor

* Improve tests
2024-04-02 09:19:25 +02:00
Jan-Philipp Benecke c2ffed9b2d
Use switch entities instead of toggle entities in tests (#114585) 2024-04-02 08:25:28 +02:00
J. Nick Koston ce9d4c8683
Fix flakey cast discovery stop test (#114605)
https://github.com/home-assistant/core/actions/runs/8515215623/job/23322322954?pr=114602
2024-04-01 21:34:54 -04:00
Paulus Schoutsen d2e4f5f36e
Add conversation entity (#114518)
* Default agent as entity

* Migrate constant to point at new value

* Fix tests

* Fix more tests

* Move assist pipeline back to cloud after dependenceis
2024-04-01 21:34:25 -04:00
Martin Hjelmare b1af590eed
Fix reolink media source data access (#114593)
* Add test

* Fix reolink media source data access
2024-04-02 00:14:13 +02:00
Sid 304ed8bf3d
Unignore Ruff PLC in tests (#114572) 2024-04-01 21:28:54 +02:00
J. Nick Koston 96120b64e0
Fix missing mocking in nextdns tests (#114541) 2024-04-01 06:53:49 -10:00
Michael 2e11a61726
Automatic cleanup of entity and device registry in Tankerkoenig (#114573) 2024-04-01 16:04:18 +02:00
J. Nick Koston ea7f2af966
Fix missing mocking in blink tests (#114540)
extracted from #114539
2024-04-01 11:23:38 +02:00
Sid d5f883fbf0
Unignore Ruff PLR in tests (#114470)
* Unignore Ruff PLR in tests

* Address review comments

* review comments

* fix import

* Update test_api.py

* Update test_api.py

* Update test_api.py
2024-04-01 11:11:59 +02:00
J. Nick Koston be398e0a3f
Fix flakey sonos test test_creating_entry_sets_up_media_player (#114539) 2024-03-31 13:49:24 -10:00
Jan-Philipp Benecke 04786e019a
Use device registry mock instead of `hass.helpers` in traccar_server tests (#114532) 2024-04-01 00:42:46 +02:00
Jan-Philipp Benecke ecf286cd81
Avoid use of `hass.helpers` in plugwise test (#114534) 2024-04-01 00:41:47 +02:00
Jan-Philipp Benecke 0238c2ea9e
Use device registry mock instead of `hass.helpers` in dsmr tests (#114535) 2024-04-01 00:41:06 +02:00
Robert Svensson 05d40fbc4c
Bump axis to v60 (#114544)
* Improve Axis MQTT support

* Bump axis to v60
2024-04-01 00:24:41 +02:00
Thomas55555 5eb4cf6a05
Add error sensor for Husqvarna Automower (#113165)
* Add error sensor for Husqvarna Automower

* Apply suggestions from code review

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>

* address review

* Add restricted reason sensor

* ruff

* pin options

---------

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>
2024-03-31 20:06:30 +02:00
wittypluck 7919ca63d0
Add uptime sensor to Glances (#111402)
* Add uptime sensor to Glances

* Merge upstream

* Merge upstream

* Fix coverage

* Add uptime sensor to Glances

* Merge upstream

* Merge upstream

* Fix coverage

* Move most uptime specific code to DataUpdateCoordinator

* Add last_reported after merge with upstream

* Add unit tests for uptime sensor

* Add unit tests for uptime sensor

* Add unit tests for uptime sensor

* Add unit tests for uptime sensor

* Move update code out of getter native_value()

* Add unit tests for uptime sensor

* Update uptime method signatures

* Set uptime icon in icons.json

* Use freezer.tick for uptime tests

* Frozen time test fails on github

* Add MIN_UPTIME_VARIATION const value

* Only update uptime on startup or when remote server restarts

* Fix for 0 values

* Set value to None to set state to Unknown if key is not found

* Add unit test for uptime change

* Code reduction

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2024-03-31 20:04:39 +02:00
Joost Lekkerkerker 52741d7114
Add single config entry to Analytics insights (#114427)
* Add single config entry to Analytics insights

* Add single config entry to Analytics insights

* Add single config entry to Analytics insights
2024-03-31 15:47:24 +02:00
Sid d846676e84
Enable first batch of Ruff RET rules (#114480)
* Enable first batch of Ruff RET rules

* disable pylint rules
2024-03-31 11:30:59 +02:00
Jan-Philipp Benecke 6e3e09f2c3
Use entity & device registry mocks instead of `hass.helpers` in airthings_ble tests (#114520) 2024-03-31 09:08:07 +02:00
Paulus Schoutsen f01235ef74
Re-organize conversation integration (#114502)
* Re-organize conversation integration

* Clean up 2 more imports

* Re-export models

* Fix imports

* Uno mas

* Rename agents to models

* Fix cast test that i broke?

* Just blocking till I'm done

* Wrong place
2024-03-31 00:05:25 -04:00
J. Nick Koston f0b07ae942
Add pytest rewrite for wemo tests that use entity_test_helpers (#114516) 2024-03-30 17:35:49 -10:00
TheJulianJES b0a1450a2b
Fix ZHA websocket API test (#114495)
* Fix result overwriting expected config

* Use `BASE_CUSTOM_CONFIGURATION` for initial/expected config
2024-03-31 00:17:09 +01:00
Michael Hansen d23b22b566
Add initial support for floors to intents (#114456)
* Add initial support for floors to intents

* Fix climate intent

* More tests

* No return value

* Add requested changes

* Reuse event handler
2024-03-30 16:59:20 -04:00
Bruno Henrique 9f9a141112
Add UniFi WLAN Password sensor (#114419)
* Adding UniFi WLAN Password Sensor

* Adding UniFi WLAN Password Sensor

* Adding UniFi WLAN Password Sensor

* Adding UniFi WLAN Password Sensor

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>

* Adding UniFi WLAN Password Sensor

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>

* Adding UniFi WLAN Password Sensor

* Adding UniFi WLAN Password Sensor

* Adding UniFi WLAN Password Sensor

---------

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
2024-03-30 19:49:33 +01:00
J. Nick Koston d63adb6350
Improve sonos test synchronization (#114468) 2024-03-30 06:34:47 -10:00
Shay Levy 3e99afdd54
Cleanup Shelly RGBW light entities (#114410) 2024-03-30 18:48:57 +03:00
Bruno Henrique 53f262095c
Add UniFi WLAN regenerate password button (#114422)
* Adding UniFi WLAN Change Password Button

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>

* Adding UniFi WLAN Regenerate Password Button

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>

---------

Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
2024-03-30 15:53:23 +01:00
Joost Lekkerkerker b7527feb5f
Rework opensky tests (#114441)
* Rework opensky tests

* Rework opensky tests

* Fix
2024-03-30 14:52:33 +01:00
Sid 6587ee20db
Enable Ruff TRY300 (#114437)
* Enable Ruff TRY300

* Update validation.py

* Address review comments
2024-03-30 10:37:59 +01:00
J. Nick Koston 9a79320861
Mark executor jobs as background unless created from a tracked task (#114450)
* Mark executor jobs as background unless created from a tracked task

If the current task is not tracked the executor job should not
be a background task to avoid delaying startup and shutdown.

Currently any executor job created in a untracked task or
background task would end up being tracked and delaying
startup/shutdown

* import exec has the same issue

* Avoid tracking import executor jobs

There is no reason to track these jobs as they are always awaited
and we do not want to support fire and forget import executor jobs

* fix xiaomi_miio

* lots of fire time changed without background await

* revert changes moved to other PR

* more

* more

* more

* m

* m

* p

* fix fire and forget tests

* scrape

* sonos

* system

* more

* capture callback before block

* coverage

* more

* more races

* more races

* more

* missed some

* more fixes

* missed some more

* fix

* remove unneeded

* one more race

* two
2024-03-30 00:16:53 -04:00