Compare commits

...

935 Commits

Author SHA1 Message Date
Paulus Schoutsen
cfa4740973 Remove media_id from pipeline TTS-END events 2025-04-30 01:30:07 +00:00
Marc Mueller
97084e9382 Remove redundant typing cast in miele (#143913) 2025-04-30 03:13:23 +02:00
J. Nick Koston
9db34fe232 Bump habluetooth to 3.45.0 (#143909) 2025-04-30 00:05:33 +02:00
Åke Strandberg
c4f0b4ab23 Bump pymiele to 0.4.1 (#143903) 2025-04-30 00:55:23 +03:00
Brian Choromanski
1647afc58a Improve parse_time_expression list comprehension to get interval values (#143488) 2025-04-29 22:20:05 +01:00
Martin Hjelmare
53ea8422f8 Improve Z-Wave hassio confirm form text (#143908) 2025-04-29 22:57:30 +02:00
Jan Bouwhuis
0b988b3fac Bump incomfort-client to v0.6.8 (#143895)
Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-29 22:05:52 +02:00
Thomas55555
5a4abe3ec1 Bump apsystems-ez1 to 2.6.0 (#143897)
Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
2025-04-29 21:36:13 +02:00
J. Nick Koston
89abc5ac69 Add WebSocket API to ssdp to observe discovery (#143862) 2025-04-29 21:03:53 +02:00
Norbert Rittel
08fe6653bb Add missing hyphen to "self-test" in weheat (#143899) 2025-04-29 22:02:24 +03:00
Norbert Rittel
9aa18c7157 Add missing hyphen to "self-check" in incomfort (#143900) 2025-04-29 20:59:15 +02:00
Retha Runolfsson
cc7929f8fb Add log when device is online and unavailable (#143648) 2025-04-29 20:52:12 +02:00
Josef Zweck
d657298791 Add statistic entities to lamarzocco (#143415)
* Bump pylamarzocco to 2.0.0b2

* Add statistic entities to lamarzocco

* add icons

* Update coordinator.py

* update uom

* Update homeassistant/components/lamarzocco/sensor.py

Co-authored-by: Simon Lamon <32477463+silamon@users.noreply.github.com>

* revert cups

* remove unnecessary call (for now)

---------

Co-authored-by: Simon Lamon <32477463+silamon@users.noreply.github.com>
2025-04-29 20:49:26 +02:00
Jan Bouwhuis
05f393560f Fix mcp_server CI test (#143898) 2025-04-29 20:40:50 +02:00
Abílio Costa
92da640d4c Rename const maps in Whirlpool (#143409) 2025-04-29 20:39:29 +02:00
Manu
ad3fd151aa Add reconfiguration flow to ista EcoTrend integration (#143457) 2025-04-29 20:37:04 +02:00
Simon Lamon
cd104dc08c LinkPlay group members should return the entity ids (#141791) 2025-04-29 20:28:08 +02:00
Norbert Rittel
d3745d2519 Add missing hyphens to "self-…" in imeon_inverter (#143888)
* Add missing hyphens to "self-…" in `imeon_inverter`

* Update test_sensor.ambr
2025-04-29 21:01:49 +03:00
Norbert Rittel
931f3fa41a Fix spelling of "self-consumption" in tessie/tesla_fleet/teslemetry (#143890)
* Fix spelling of "self-consumption" in `tessie`

* Fix spelling of "self-consumption" in `tesla_fleet`

* Fix spelling of "self-consumption" in `teslemetry`
2025-04-29 21:01:41 +03:00
Norbert Rittel
87b5a91212 Add missing hyphen to "self-clean" in roborock (#143893)
Fix four states that contain "self-clean" by adding the missing hyphen.
2025-04-29 21:01:35 +03:00
Norbert Rittel
3b8da62d84 Make spelling of "self-consumption" consistent in growatt_server (#143886)
Also fix one overlooked sentence-casing.
2025-04-29 21:01:08 +03:00
Norbert Rittel
86a48294f4 Change all imap action descriptions to match HA style (#143894)
Change all `imap` action description to match HA style

Change all four descriptions to use third-person singular to ensure proper (machine) translations.
2025-04-29 20:59:06 +03:00
Ville Skyttä
a03884981f Prefer huawei_lte SSDP model name over friendly name (#143725) 2025-04-29 19:25:32 +02:00
Ville Skyttä
ab695f90c7 Upgrade url-normalize to 2.2.1 (#143751) 2025-04-29 19:10:57 +02:00
Allen Porter
efcf8f9555 Improve TurnOn/Off LLM tool descriptions (#143768) 2025-04-29 19:09:05 +02:00
epenet
f71903a563 Simplify device registry checks in renault tests (#143863) 2025-04-29 19:03:14 +02:00
Petro31
95552e9a5b Add trigger based template lights (#140631)
* Add abstract template light class in preparation for trigger based template lights

* add base for trigger entity

* Update more tests

* revert trigger template entity changes and light trigger tests.

* fix merge conflicts

* address comments

* change function name

* nitpick

* fix merge conflict issue

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2025-04-29 18:02:44 +02:00
Åke Strandberg
5da57271b2 Add 3 duration sensors to miele (#143160)
* Add 3 duration sensors

* Update snapshot

* Address review comments

* Cleanup

* Adjust type hint
2025-04-29 17:53:24 +02:00
Norbert Rittel
62a7139f4d Fix hyphens on "self-consumption"/"serial number" in enphase_envoy (#143887) 2025-04-29 17:29:48 +02:00
Franck Nijhof
a7be26cd95 Merge branch 'master' into dev 2025-04-29 15:17:37 +00:00
J. Nick Koston
9c3b0952e0 Turn off autospec for zeroconf mocks (#143879) 2025-04-29 16:45:58 +02:00
J. Nick Koston
c771f446b4 Bump aioesphomeapi to 30.1.0 (#143881) 2025-04-29 16:13:30 +02:00
Petro31
9a25561017 Fix duplicate code from merge conflict (#143880)
fix conflict
2025-04-29 16:09:08 +02:00
Manuel Stahl
bd870f0537 Remove dependency on modbus for stiebel_eltron (#136482)
* Remove dependency on modbus for stiebel_eltron

The modbus integration changed its setup, so it is
not possible anymore to have an empty hub.

* Add config flow

* Update pystiebeleltron to v0.1.0

* Fix

* Fix

* Add test for non existing modbus hub

* Fix tests

* Add more tests

* Add missing translation string

* Add test for import failure

* Fix issues from review comments

* Fix issues from review comments

* Mock stiebel eltron client instead of setup_entry

* Update homeassistant/components/stiebel_eltron/__init__.py

* Update homeassistant/components/stiebel_eltron/__init__.py

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-04-29 15:34:16 +02:00
Manuel Stahl
d7f43bddfa Remove dependency on modbus for stiebel_eltron (#136482)
* Remove dependency on modbus for stiebel_eltron

The modbus integration changed its setup, so it is
not possible anymore to have an empty hub.

* Add config flow

* Update pystiebeleltron to v0.1.0

* Fix

* Fix

* Add test for non existing modbus hub

* Fix tests

* Add more tests

* Add missing translation string

* Add test for import failure

* Fix issues from review comments

* Fix issues from review comments

* Mock stiebel eltron client instead of setup_entry

* Update homeassistant/components/stiebel_eltron/__init__.py

* Update homeassistant/components/stiebel_eltron/__init__.py

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-04-29 14:57:01 +02:00
Åke Strandberg
87107c5a59 Add log of missing codes to miele diagnostics (#143877)
Add missing code log to diagnostics
2025-04-29 14:56:45 +02:00
Patrick
9ce920b35a Add support for external USB drives to Synology DSM (#138661)
* Add external usb drives

* Add partition percentage used

* Move icons to icons.json

* Add external usb to diagnostics

* Add assert for external usb entity

* Fix reset external_usb

* Update homeassistant/components/synology_dsm/diagnostics.py

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>

* Update homeassistant/components/synology_dsm/diagnostics.py

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>

* Fix diagnostics

* Make each partition a device

* Add usb sensor tests

* Add diagnostics tests

* It is possible that api.external_usb is None

* Merge upstream into syno_external_usb

* add manufacturer and model to partition

* fix tests

---------

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
Co-authored-by: mib1185 <mail@mib85.de>
2025-04-29 13:32:21 +02:00
J. Diego Rodríguez Royo
15aff9662c Refresh Home Connect program entities possible options when an appliance gets connected (#143213)
Refresh options when an appliance gets connected
2025-04-29 13:12:21 +02:00
Åke Strandberg
da6fb91886 Add some more sensors to miele integration (#142979)
* Add some more sensors

* Add some debug logging and correct spelling

* Address review comments

* Split out duration sensors to separate PR

* Update strings

* Filter program phases by device type

* Update tests

* Fix auto link

* Address som of the comments

* Lint

* Lint

* Remove duplicates from enum sensor options

* Update snapshot

* Sort options in enum sensors
2025-04-29 13:07:55 +02:00
Alex Fuchs
1e880f7406 Bump apsystems-ez1 to 2.5.1 (#143739)
Bump apsystems-ez1 to 2.5.1 to fix debounce problem
2025-04-29 13:04:57 +02:00
Matrix
81153042d3 Bump YoLink Lib to v0.5.2 (#143873)
Bump YoLink API to v0.5.2
2025-04-29 12:57:23 +02:00
Michael
493ca261dc Add strict type checking to SMTP integration (#143698) 2025-04-29 12:56:29 +02:00
Ville Skyttä
7493b340ca Add more huawei_lte sensor descriptions (#143707) 2025-04-29 12:54:36 +02:00
Norbert Rittel
e85e60ed6a Use common state "Fault" in wolflink (#143688) 2025-04-29 12:53:09 +02:00
chammp
8ff4d5dcbf Adapt template sensors to use the same plural trigger/condition/action definitions as automations (#127875)
* Add plurals to template entities

* Ruff

* Ruffy ruff

* Fix linters

* Fix bug introduced after merging dev

* Fix merge mistake

* Revert adding automation helper

* Revert "Fix bug introduced after merging dev"

This reverts commit 098d478f150a06546fb9ec3668865fa5d763c6b2.

* Fix blueprint validation

* Apply suggestions from code review

---------

Co-authored-by: Erik <erik@montnemery.com>
2025-04-29 11:52:58 +02:00
Norbert Rittel
f2838e493b Use common state for "Fault" in peblar (#143708) 2025-04-29 11:39:21 +02:00
Åke Strandberg
a71edcf1a1 Add fan platform to miele integration (#143772)
* Add fan platform

* Fix after review comment

* Address review comments

* Remove commented code

* Update tests

* Use constant
2025-04-29 10:48:56 +02:00
Arie Catsman
47bef74e7c apply for platinum quality scale for enphase_envoy (#143846) 2025-04-29 10:41:22 +02:00
Erwin Douna
b757a7e3fe Replace pymelcloud with python-melcloud (#142120) 2025-04-29 10:38:00 +02:00
dependabot[bot]
362ff5724d Bump actions/attest-build-provenance from 2.2.3 to 2.3.0 (#143865) 2025-04-29 10:31:16 +02:00
Joost Lekkerkerker
4f8363a5c2 Add availability to SmartThings devices (#143836)
* Bump pySmartThings to 3.1.0

* Bump pySmartThings to 3.2.0

* Add availability to SmartThings devices

* Add availability to SmartThings devices

* Add availability to SmartThings devices
2025-04-29 10:29:07 +02:00
Maciej Bieniek
ae3925118c Do not allow to enable BT scanner for Shelly Gen4 device with Zigbee enabled (#143824)
* Bluetooth is not supported when Zigbee is enabled

* Update tests

* Format
2025-04-29 11:12:34 +03:00
Petro31
b2fcab20a6 Add trigger based entities to template switch (#141763)
* Add trigger based entities to template switch platform

* add suggestions
2025-04-29 09:40:16 +02:00
Brett Adams
6423957d29 Add common translations to Sentry in Teslemetry (#143868)
missing translation keys
2025-04-29 09:26:19 +02:00
Brett Adams
835cdad0a9 Add sentry mode sensor to Teslemetry (#143855)
* Add sentry mode sensor

* Fix state handler
2025-04-29 08:37:10 +02:00
Klaas Schoute
d8d6decb38 Bump odp-amsterdam to v6.1.1 (#143854) 2025-04-29 08:35:56 +02:00
Erik Montnemery
16b42cc109 Add cv.renamed (#143834) 2025-04-29 07:36:37 +02:00
tmenguy
a47f27821f Add some tests with an invalid plugStatus and renault twingo iii. (#143838) 2025-04-28 22:31:27 +02:00
Daniel Hjelseth Høyer
c797e7a973 Mill, add statistics (#130406)
* Mill, new features

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* typo

* tests

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mill

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* Update const.py

* Update sensor.py

* Update sensor.py

* Add test

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* Add test

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mill

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mock_setup_entry

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* after_depencies

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* Mill

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mill stats

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mill stats

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* format

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mill

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* Add test

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* tests

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

* mill

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>

---------

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
2025-04-28 21:59:42 +02:00
Norbert Rittel
245eb64405 Fix spelling of "self-test" in apcupsd (#143843) 2025-04-28 22:35:16 +03:00
Martin Hjelmare
a895fcf057 Bump zwave-js-server-python to 0.63.0 (#143844) 2025-04-28 21:34:47 +02:00
Norbert Rittel
5706fb26b8 Make spelling of "self-test" consistent in zha (#143842)
While the "self-test" button already contains the recommended hyphen it's missing in the switch and sensor entity names.
2025-04-28 21:07:50 +03:00
Åke Strandberg
3f82120cdc Add miele core temp sensors (#143785)
Add core temp sensors
2025-04-28 18:47:42 +02:00
Brett Adams
20df183470 Improve energy entities in Teslemetry (#143641)
* Energy fixes

* improvements

* Add more icons
2025-04-28 18:47:12 +02:00
dependabot[bot]
980216795f Bump docker/build-push-action from 6.15.0 to 6.16.0 (#143651)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 6.15.0 to 6.16.0.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](471d1dc4e0...14487ce63c)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-version: 6.16.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-28 16:50:07 +02:00
Joost Lekkerkerker
fdfcd841ba Bump pySmartThings to 3.2.0 (#143833)
* Bump pySmartThings to 3.1.0

* Bump pySmartThings to 3.2.0
2025-04-28 16:23:06 +02:00
Josef Zweck
28a09794e9 Bump pylamarzocco to 2.0.0b6 (#143778)
* Bump pylamarzocco to 2.0.0b5

* bump to 6
2025-04-28 16:22:46 +02:00
David Knowles
a0c9217375 Schlage: Source valid auto lock times from pyschlage (#143382)
* Source auto lock times from pyschlage

* Update auto lock strings

* Test all options are translated
2025-04-28 14:45:38 +02:00
Petro31
469176c59b Fix trigger template entity issue when coordinator data is None (#143830)
Fix issue when coordinator data is None
2025-04-28 14:32:16 +02:00
Erik Montnemery
3ece672890 Update rainforest_raven test snapshots (#143829) 2025-04-28 14:04:10 +03:00
Brett Adams
c6ebba8843 Add streaming connectivity binary sensors to Teslemetry (#143443)
* Add connectivity entities

* Add connectivity entities

* Fix Wi-Fi spelling in Teslemetry component
2025-04-28 12:58:40 +02:00
Erik Montnemery
1f047807a4 Update netatmo test snapshots (#143828) 2025-04-28 13:48:50 +03:00
Erik Montnemery
f1b724c49a Update samsungtv test snapshots (#143826) 2025-04-28 13:48:39 +03:00
J. Nick Koston
5ebed2046c Bump bluetooth-data-tools to 1.28.1 (#143817) 2025-04-28 12:05:07 +02:00
Arie Catsman
d1236a53b8 add enphase_envoy interface mac to device registry (#143758)
* add enphase_envoy interface mac to device registry

* Test for capitalized error log entry.

* increase mac collection delay from 17 to 34 sec
2025-04-28 11:20:11 +02:00
Tsvi Mostovicz
84f07ee992 Bump hdate to 1.1.0 (#143759) 2025-04-28 10:38:49 +02:00
J. Nick Koston
d7f5e48626 Bump aioshelly to 13.6.0 (#143814)
changelog: https://github.com/home-assistant-libs/aioshelly/compare/13.5.0...13.6.0
2025-04-28 11:27:50 +03:00
Norbert Rittel
56e07bb1f2 Use common state for "Fault", add recommended hyphen in fronius (#143812)
* Use common state for "Fault" in `fronius`

Also add a recommended hyphen to "self-consumption".

See Wiktionary: "Words derived from self- are usually formed with a hyphen. Using a hyphen is recommended by the U.S. Government Printing Office Style Manual."

* Update test_sensor.ambr
2025-04-28 11:18:07 +03:00
J. Nick Koston
45b2700375 Bump habluetooth to 3.44.0 (#143802) 2025-04-28 03:45:47 -04:00
Erik Montnemery
d860b35f41 Fix flaky test test_async_parallel_updates_with_zero_on_sync_update (#143810) 2025-04-28 09:27:26 +02:00
Martin Hjelmare
5392062edd Add backup agent retention config (#143174) 2025-04-28 09:24:23 +02:00
Åke Strandberg
d9a09a2aea Enable deletion of stale miele devices (#143811)
Enable deletion of stale devices
2025-04-28 08:59:34 +02:00
epenet
3daff73d36 Add renault reconfigure flow (#143449)
* Add renault reconfigure flow

* docstring
2025-04-28 08:43:20 +02:00
J. Nick Koston
e6b88ec087 Bump thermopro-ble to 0.12.0 (#143799)
* Bump thermopro-ble to 0.12.0

changelog: https://github.com/Bluetooth-Devices/thermopro-ble/compare/v0.11.0...v0.12.0

* update tests
2025-04-28 08:37:20 +02:00
J. Nick Koston
592dcec852 Bump govee-ble to 0.44.0 (#143800)
changelog: https://github.com/Bluetooth-Devices/govee-ble/compare/v0.43.1...v0.44.0
2025-04-28 08:36:02 +02:00
J. Nick Koston
2a6b79ec0f Bump bluemaestro-ble to 0.3.0 (#143795)
* Bump bluemaestro-ble to 0.3.0

changelog: https://github.com/Bluetooth-Devices/bluemaestro-ble/compare/v0.2.3...v0.3.0

* update tests
2025-04-28 08:35:22 +02:00
J. Nick Koston
afc1d224a0 Bump sensorpro-ble to 0.6.0 (#143796)
* Bump sensorpro-ble to 0.6.0

changelog: https://github.com/Bluetooth-Devices/sensorpro-ble/compare/v0.5.3...v0.6.0

* update tests
2025-04-28 08:34:34 +02:00
J. Nick Koston
b668acda24 Bump inkbird-ble to 0.14.1 (#143793)
changelog: https://github.com/Bluetooth-Devices/inkbird-ble/compare/v0.13.0...v0.14.1
2025-04-28 08:33:48 +02:00
J. Nick Koston
c3996d6931 Bump sensorpush-ble to 1.8.0 (#143794)
* Bump sensorpush-ble to 1.8.0

changelog: https://github.com/Bluetooth-Devices/sensorpush-ble/compare/v1.7.1...v1.8.0

* fix tests
2025-04-28 08:33:11 +02:00
J. Nick Koston
9ec174776c Bump leaone-ble to 0.2.0 (#143798)
* Bump leaone-ble to 0.2.0

changelog: https://github.com/Bluetooth-Devices/leaone-ble/compare/v0.1.0...v0.2.0

* update tests
2025-04-28 08:31:58 +02:00
J. Nick Koston
6a8722cf7c Bump thermobeacon-ble to 0.9.0 (#143797)
* Bump thermobeacon-ble to 0.9.0

changelog: https://github.com/Bluetooth-Devices/thermobeacon-ble/compare/v0.8.1...v0.9.0

* update tests
2025-04-28 08:30:57 +02:00
epenet
000b1d80b0 Update docs in renault quality-scale (#143806) 2025-04-28 08:29:28 +02:00
epenet
6d8654610e Remove obsolete code in Renault integration (#143808) 2025-04-28 08:25:03 +02:00
Olivier Douville
5cd4c8e896 Add missing state class in sfr-box (#143773)
* Update sensor.py - Add MEASUREMENT state class on alimvoltage and temperature sensors

This will allow state values to be stored in LTS (long term statistics)

* Update tests accordingly to previous changes in sensors

* Update tests accordingly to previous changes in sensors
2025-04-28 07:55:29 +02:00
Erik Montnemery
cec8db173b Remove redundant entity_id collision check in entity registry (#143660)
* Remove redundant entity_id collision check in entity registry

* Update test
2025-04-28 07:50:26 +02:00
J. Nick Koston
dd9dad80be Bump habluetooth to 3.42.0 and bleak-esphome to 2.14.0 (#143787) 2025-04-27 19:36:58 -05:00
Åke Strandberg
9992ade051 Bump pymiele to 0.4.0 (#143789) 2025-04-27 23:31:10 +01:00
J. Nick Koston
36da4a9b72 Bump bluetooth-data-tools to 1.28.0 (#143782)
changelog: https://github.com/Bluetooth-Devices/bluetooth-data-tools/compare/v1.27.0...v1.28.0

related issue https://github.com/home-assistant/core/issues/143769#issuecomment-2833594159
2025-04-27 16:50:42 -05:00
Mick Vleeshouwer
3fc34244ac Fix hvac_mode property to handle missing CORE_ON_OFF state in Atlantic Electrical Heater in Overkiz (#143330) 2025-04-27 20:42:51 +02:00
tronikos
753c07e911 Bump opower to 0.12.0 (#143748) 2025-04-27 20:40:10 +02:00
Joris Drenth
d0850e2931 Bump Wallbox version to 0.9.0 (#143775)
Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-27 20:36:20 +02:00
Manu
c704df004a Add diagnostics platform to ntfy platform (#143774) 2025-04-27 19:58:15 +02:00
Yuxin Wang
d95c9c496e Make exception messages translatable for APCUPSD (#143747)
Add translation domain and key for UpdateFailed in coordinator
2025-04-27 16:35:55 +02:00
Ville Skyttä
d28f4ed618 Set device class for huawei_lte connectivity binary sensors (#143764) 2025-04-27 16:34:11 +02:00
Jan Bouwhuis
7a0580eff5 Import media player constants at integration level for alexa smart home (#143767) 2025-04-27 15:36:42 +02:00
Sanjay Govind
f94af84f2a Update deprecated const usage in alexa integration (#143741) 2025-04-27 14:33:16 +02:00
Allen Porter
31fb199670 Bump voluptuous-openapi to 0.0.7 (#143742) 2025-04-27 12:10:26 +02:00
Brett Adams
a1ca0a1cb2 Dont add location entities without location scope in Teslemetry (#143497)
* Dont add location entities without location scope

* Fix tests

* simplify logic

* Add test
2025-04-27 11:25:58 +02:00
Allen Porter
2326c23133 Increase Gemini max tokens to avoid failures observed in evaluations (#143728)
* Increase Gemini max tokens to avoid failures observed in evaluations

* Update snapshots
2025-04-26 15:30:47 -07:00
J. Nick Koston
d4c1d1bdb9 Split up SSDP integration into modules (#143732)
* Split up SSDP integration into modules

* Split up SSDP integration into modules

* migrate tests
2025-04-26 18:09:51 -04:00
Allen Porter
8d258871ff Record Anthropic token statistics in conversation trace (#143727)
* Record anthopic token statistics in conversation trace

* Add test coverage for output token parsing
2025-04-26 18:04:12 -04:00
Thomas55555
49299a6bf0 Bump aioautomower to 2025.4.4 (#143533)
* Bump aioautomower to 2025.4.1

* Update split_tests.py

* revert b3222b9be9

Co-authored-by: Shay Levy <levyshay1@gmail.com>

* aioautomower==2025.4.2

* fix

* aioautomower==2025.4.30b0

* revert

* some try

* aioautomower==2025.4.0

* aioautomower==2025.4.3b0

* aioautomower==2025.4.4

---------

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
Co-authored-by: Shay Levy <levyshay1@gmail.com>
2025-04-27 00:07:14 +03:00
Shay Levy
868b8ad318 Move Switcher handle_coordinator_update to base entity (#143738) 2025-04-27 00:01:44 +03:00
Simone Chemelli
40752dcfb6 Translate missing exceptions in SamsungTV (#143628)
* Translate missing exceptions in SamsungTV

* apply review comment
2025-04-26 22:43:07 +02:00
Stefan Agner
18f51abfe6 Remove unnecessary Supervisor info call (#143700) 2025-04-26 15:27:31 -05:00
Maikel Punie
3e2c54dcbd Bump velbusaio to 2025.4.2 (#143675) 2025-04-26 15:22:10 -05:00
Manu
a0cd14b4e8 Add reauth flow to ntfy integration (#143729) 2025-04-26 22:05:13 +02:00
Norbert Rittel
35c6fdbce8 Use common state for "Fault" in shelly (#143730) 2025-04-26 21:08:39 +03:00
sebfortier2288
202addc39d Remove sebfortier2288 from Soma code owners (#143715)
* chore(soma): remove from codeowner

* chore(soma): remove from sebfortier2288 codeowners
2025-04-26 19:56:56 +03:00
Shay Levy
d8cb7c475b Update Switcher temperature sensor device class and state class (#143722)
* Update Switcher temperature sensor device class and state class

* Remove  temperature translation key

* Remove icon
2025-04-26 16:22:44 +02:00
Shay Levy
03bacd747e Use device_registry fixture in Switcher test_remove_device (#143723) 2025-04-26 17:05:51 +03:00
Manu
97b6a68cda Improve device handling for disconnected IronOS devices (#143446)
* Improve device handling for disconnected IronOS devices

* requested changes

* ble_device
2025-04-26 13:34:44 +02:00
Shay Levy
eee18035cf Use value_fn in Switcher sensor platform (#143711) 2025-04-26 13:34:13 +02:00
Maciej Bieniek
f1b3b0c155 Refactor tests for Shelly config flow (#143517)
* Add mock_setup_entry

* Add mock_setup

* Improve test_form_gen1_custom_port

* Improve test_form_errors_get_info

* Improve test_form_errors_test_connection

* Improve test_reconfigure_with_exception

* Improve test_form_auth_errors_test_connection_gen1

* Improve test_form_auth_errors_test_connection_gen2

* Cleaning

* Upate quality scale

* Always use result variable

* Remove unnecessary async_block_till_done
2025-04-26 13:00:45 +03:00
Åke Strandberg
f5d3495c62 Add properties to miele entity class (#143622)
* Add properties to Entity class

* Remove setter and most platform constructors
2025-04-26 09:55:11 +02:00
Martin Hjelmare
e14a356c24 Allow Z-Wave controller migration on USB discovery (#143677)
Allow migration on USB discovery
2025-04-26 07:52:32 +02:00
J. Nick Koston
4e7d396e5b Add WebSocket API to zeroconf to observe discovery (#143540)
* Add WebSocket API to zeroconf to observe discovery

* Add WebSocket API to zeroconf to observe discovery

* increase timeout

* cover

* cover

* cover

* cover

* cover

* cover

* fix lasting side effects

* cleanup merge

* format
2025-04-25 21:18:09 -04:00
J. Nick Koston
34d17ca458 Move state length validation to StateMachine APIs (#143681)
* Move state length validation to StateMachine async_set method

We call validate_state to make sure we do not allow any states
into the state machine that have a length>255 so we do not break
the recorder. Since async_set_internal already requires callers
to pre-validate the state, we can move the check to async_set
instead of at State object creation time to avoid needing to
check it twice in the hot path (entity write state)

* move check in async_set_internal so it only happens on state change

* no need to check if same_state
2025-04-25 21:15:15 -04:00
J. Nick Koston
03950f270a Remove lower call in async_reserve (#143682)
async_reserve is only called from the the entity_platform helper
which already ensures the entity_id is validated and in lower
case.
a783b6a0ab/homeassistant/helpers/entity_platform.py (L936)
2025-04-25 21:12:55 -04:00
Denis Shulyaka
7074331461 Preserve reasoning during tool calls for openai_conversation (#143699)
Preserve reasoning after tool calls for openai_conversation
2025-04-25 21:12:23 -04:00
Maksim Doroshko
4c9cd70f65 Set unique id in ephember (#143180)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-25 23:06:16 +01:00
Ville Skyttä
7a105de969 Add missing huawei_lte sensor translations (#143694) 2025-04-25 22:54:56 +01:00
Åke Strandberg
eec9a28fe8 Add zeroconf discovery to miele (#143259)
* Add zeroconf discovery

* Strip unnecessary code

* Remove one line more

* Remove one more

* Add test for zeroconf flow

* Finish zeroconf flow
2025-04-25 23:18:20 +02:00
Arie Catsman
963f1b1907 bump pyenphase to 1.26.0 (#143686) 2025-04-25 08:50:37 -10:00
dependabot[bot]
dcac9b5f20 Bump actions/download-artifact from 4.2.1 to 4.3.0 (#143650) 2025-04-25 20:40:18 +02:00
Joost Lekkerkerker
765a95c273 Set entities to config category in SmartThings (#143669) 2025-04-25 20:21:35 +02:00
Tomáš Bedřich
6a115d0133 Add S3 integration (#139325)
* Add S3 integration

* Improve translations and error handling

* Test S3 integration

* Update QoS

* Add missing data_description strings

* Fix missing async_initialize_backup in tests

* PR changes

* Remove unique ID, rely on abort_entries_match

* Raise only BackupAgentError (#139754), introduce decorator for error handling

* Switch to metadata-file based solution

* PR changes

* Revert strict typing

* Bump dependency

* Silence mypy

* Pass docs URLs as description_placeholders

* PR changes

* Rename _api to api

* PR Changes

* PR Changes 2

* Remove api abstraction

* Handle S3 multipart upload size limitations

* PR changes
2025-04-25 20:16:44 +02:00
Åke Strandberg
a057effad5 Add miele binary_sensor platform (#142903)
* Add binary_sensor platform

* Address review comments

* Adjust icons and names.

* Change Info to Notification active

* Trigger CI

* Trig CI

* Adjust tests

* Update strings.json

* Update strings.json
2025-04-25 19:32:08 +02:00
Dan
94b0800989 Fix surepetcare sensor error (#143286)
* fix: changed boolean to map to 'online' attribute.

* fix: added catch in case of future changes to prevent complete sensor failure.

* fix: surepetcare - added additional catches in case rssi values aren't included in online status.

* fix: remove hub_rssi when not defined.

* fix: proper code spacing

* fix: use .get for clarity instead of try.

* fix: now written in Python.

* fix: renamed variables for clarity.

* Update homeassistant/components/surepetcare/binary_sensor.py

* fix: update surepetcare test __init__.py mock_feeder with online status.

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-25 19:29:29 +02:00
Åke Strandberg
a783b6a0ab Add climate platform to miele integration (#143333)
* Add climate platform

* Merge

* Address review and improve test

* Address review comments

* Streamline entity naming

* Update tests/components/miele/test_climate.py

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-25 19:18:39 +02:00
Åke Strandberg
5302964eb6 Add button platform to miele (#143508)
* WIP Button platform

* Add button platform

* Disable by default, Address review , update tests

* Follow review comments
2025-04-25 19:10:32 +02:00
Norbert Rittel
261dbd16a6 Add common state "Fault" (#143390) 2025-04-25 18:47:19 +02:00
Guido Schmitz
672dbc03c6 Use coordinator data for devolo Home Network PLC data rate sensor (#143606) 2025-04-25 18:45:16 +02:00
Åke Strandberg
ed0bdf9e5f Add switch platform to miele integration (#142925)
* Add switch platform

* Add a type hint

* Update after review
2025-04-25 18:40:52 +02:00
Simone Chemelli
735e2e4192 Add missing exception translations to Comelit (#142861)
* Add missing exception translations to Comelit

* update quality scale

* remove unwanted placeholder
2025-04-25 18:34:29 +02:00
Martin Hjelmare
0aabb11220 Improve Z-Wave migration flow (#143673) 2025-04-25 18:33:19 +02:00
Jozef Kruszynski
09ad14bc28 Update Music Assistant browse media types (#143249)
* Update Music Assistant browse media types

* changes based on review comments
2025-04-25 18:32:48 +02:00
J. Nick Koston
d61e39743b Reduce ref counting in _async_write_ha_state (#143634)
* Reduce ref counting in _async_write_ha_state

It no longer makes sense to keep a temp reference
to entity_id and hass since the function was
refactored and there are very few accesses now.

* one more place we can reduce ref counts
2025-04-25 18:25:16 +02:00
Paulus Schoutsen
ea90df434b Add an icon to the VoIP assist satellite entities (#143671) 2025-04-25 11:02:53 -05:00
Norbert Rittel
67fc682df2 Sentence-case "webhook" in locative (#143646) 2025-04-25 17:27:32 +02:00
Norbert Rittel
381b495efc Change "webhook (applet)" to lowercase in ifttt (#143642) 2025-04-25 17:27:22 +02:00
Norbert Rittel
812db815f1 Change "webhook" to lowercase and use "webhook service" in dialogflow (#143643)
* Change "webhook" to lowercase and fix grammar in `dialogflow`

* Replace "integration" with "service"
2025-04-25 17:22:12 +02:00
Retha Runolfsson
24ee19f1e2 Update quality scale for switchbot (#143145)
update quality_scale
2025-04-25 17:21:01 +02:00
Everton Leite
f72c5ebb76 Add ratio attribute to Transmission torrent info (#143459) 2025-04-25 17:00:02 +02:00
epenet
1075ea1220 Bump renault-api to 0.3.0 (#143657) 2025-04-25 16:52:23 +02:00
Glenn Waters
ce7edca136 Bump env_canada lib to 0.10.2 (#143664) 2025-04-25 16:44:16 +02:00
Doug Hoffman
3e16857a1e Bump uiprotect to 7.5.5 (#143668)
* Update manifest.json

* Update requirements_all.txt

* Update requirements_test_all.txt
2025-04-25 16:43:52 +02:00
Martin Hjelmare
5b1e32f51d Clean up Z-Wave config flow (#143670) 2025-04-25 16:43:19 +02:00
Ludovic BOUÉ
4adf5ce826 Support for Matter 1.4 Water Heater device type (#131505)
* Create water_heater.json

* Update water_heater.json

* Update water_heater.json

* TankVolume

* TankPercentage

* WaterHeaterMode

WaterHeaterMode

* Update sensor.py

* ruff-format

* Update water_heater.json

 Attributes of WaterHeaterManagement Cluster on Endpoint 2
ClusterId 148 (0x0094)

* Update test_sensor.py

water_heater fixture

* Update test_sensor.py

* SensorDeviceClass=VOLUME_STORAGE for `TankVolume`

* `BoostStateEnum` map

* WaterHeaterManagementBoostState

* Update sensor.py

* WaterHeaterManagementEstimatedHeatRequired

* Fix UnitOfEnergy

* Format

* Add `device_types.WaterHeater` to Climate

* Strings for Tank sensors

* WaterHeater icons

* Update icons.json

* Update strings.json

* Update water_heater.json

* ruff-format

* Fix tests

* Fix sensor.py

* Fix icons

* WaterHeaterManagementEstimatedHeatRequired

* WaterHeaterManagementBoostState

* BoostState as a binary sensor

* ElectricalPowerMeasurement values

* Fix tests

* Create water_heater.py

* Update climate.py from dev branch

* Resolve conflicts

* ruff-format

* Add Platform.WATER_HEATER

* Update water_heater.py

* Update water_heater.py

* Update water_heater.py

* Update water_heater.py

* Add WaterHeaterManagement sensors

* Update tests

* Add select test

* Add strings

* First try with water_heater

* Testing current_operation

* BoostState attribute

* target_temperature attributes

* target_temperature attribute

* set_temperature and set_operation_mode

* turn_on / turn_off

* Trigger Boost command

* Fix WaterHeaterBoostInfoStruct

* Add test file

* Add climate cluster to fixture

* Add climate cluster to fixture

* Add tests

* Add ON_OFF feature

* Update tests

* Update tests

* Translate WaterHeaterMode

* Change description

* Update test and snapshots

* Update snapshots

* Set entity name to None to make the device name be the name of the entity

* Format

* Update water_heater.py

* Fix format

* ruff-format

* Import ServiceValidationError

* Update homeassistant/components/matter/water_heater.py

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

* Update water_heater.py

* Update test_water_heater.py

* Update test_water_heater.ambr

* Update test_water_heater.py

* Update select.py

* Update snapshots

* Rename to boost_info

* Set WaterHeaterMode

* Update snapshots

* Update snapshots

* Fix for warning
W7431: Argument 3 should be of type AddConfigEntryEntitiesCallback in async_setup_entry (hass-argument-type)

* Update strings.json

* Update strings and tests

* Fix missing brace

* Update tests

* fix test

* Updates strings

* Fix async_set_temperature

* Update tests

* Update tests

* Update homeassistant/components/matter/water_heater.py

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

* Sort strings in strings.json

* Update homeassistant/components/matter/water_heater.py

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

* Remove unused line

* Remove min/max target temperatures

* Remove BOOST_STATE_MAP

* Add comment

* Remove SUPPORT_FLAGS_HEATER

* Remove system_mode_value check

* Update homeassistant/components/matter/water_heater.py

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

* Reformat async_set_temperature()

* Update snapshots

* Remove MatterWaterHeaterMode selector

* Update snapshots

* Rename test to test_water_heater_set_temperature

* Add test_water_heater_set_operation_mode

* Remove reset_mock

* Update tests/components/matter/test_water_heater.py

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

* Add test_update_from_water_heater

* Add test_water_heater_turn_on_off

* Add test_water_heater_boostmode

* Fix SystemMode value for STATE_HIGH_DEMAND

* Add disable boost from water heater device side test

* Remove unused lines

* Remove unused lines

* Fix test indentation

* Fix water heater tests

* Check for None

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-25 15:28:28 +02:00
Petro31
4a1905a2a2 Update template cover to modern style config (#141878) 2025-04-25 15:22:49 +02:00
Michael
59af3a396c Remove unnecessary mixins from AVM Fritz!SmartHome (#143658)
remove unnecessary mixin
2025-04-25 14:12:59 +02:00
Martin Hjelmare
7c584ece23 Make proper Z-Wave reconfigure flow (#143549)
* Make proper Z-Wave reconfigure flow

* Improve backup_failed string
2025-04-25 14:19:03 +03:00
Petro31
ff2c901930 Update trigger based template entity resolution order (#140660)
* Update trigger based template entity resolution order

* add test

* fix most comments

* Move resolution to base class

* add comment

* remove uncessary if statement

* add more tests

* update availability tests

* update logic stage 1

* phase 2 changes

* fix trigger template entity tests

* fix trigger template entities

* command line tests

* sql tests

* scrape test

* update doc string

* add rest tests

* update sql sensor _update signature

* fix scrape test constructor

* move state check to trigger_entity

* fix comments

* Update homeassistant/components/template/trigger_entity.py

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

* Update homeassistant/helpers/trigger_template_entity.py

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

* Update homeassistant/helpers/trigger_template_entity.py

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

* update command_line and rest

* update scrape

* update sql

* add case to command_line sensor

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2025-04-25 13:17:25 +02:00
Erik Montnemery
dc8e1773f1 Remove unused defaults from entity_registry.RegistryEntry (#143655) 2025-04-25 12:41:58 +02:00
Stefan Agner
b0d9a2437d Bump aiohasupervisor from version 0.3.b1 to version 0.3.1 (#143585) 2025-04-25 12:20:28 +02:00
Paul Bottein
2be6ecd50f Assign plex update entity to server device (#143654)
* Assign plex update entity to server device

* Fix tests

* Apply suggestions from code review

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-25 11:21:14 +02:00
J. Nick Koston
fa0bb35e6c Avoid creating tasks to add entities when no entities are passed (#143647)
async_add_entities would return early if no entities
were passed but its a bit cleaner to not create the
task in the first place. I noticed in py-spy that
tplink was passing empty lists frequently
which made a task and than did nothing.
2025-04-25 10:16:20 +02:00
Franck Nijhof
360bffa3a9 2025.4.4 (#143653) 2025-04-25 09:47:05 +02:00
Maciej Bieniek
5b503f21d7 Abort Shelly flows if the device is not fully provisioned (#143652)
* Abort flows if the device is not fully provisioned

* Update tests
2025-04-25 10:37:58 +03:00
Franck Nijhof
2214d9b330 Bump version to 2025.4.4 2025-04-25 06:54:02 +00:00
Joost Lekkerkerker
6a2d733d85 Bump pysmartthings to 3.0.5 (#143586) 2025-04-25 06:53:49 +00:00
cnico
7392d5a30a Bump dio-chacon-api to v1.2.2 (#143489)
Bump dio-chacon-api to v1.2.2 to solve https://github.com/home-assistant/core/issues/142808
2025-04-25 06:53:48 +00:00
J. Nick Koston
b3deeca939 Bump aiohomekit to 3.2.14 (#143440) 2025-04-25 06:53:47 +00:00
Simone Chemelli
c38a3a239c Fix Vodafone Station config entry unload (#143371) 2025-04-25 06:53:45 +00:00
Simon Lamon
afa6ed09ef Sync random sensor device classes (#143368) 2025-04-25 06:53:44 +00:00
Simon Lamon
deb966128f Add scan interval and parallel updates to LinkPlay media player (#143324) 2025-04-25 06:53:43 +00:00
Marc Mueller
73707fa231 Fix licenses check for setuptools (#143292) 2025-04-25 06:53:41 +00:00
Marc Mueller
10ac39f6b2 Update setuptools to 78.1.1 (#143275) 2025-04-25 06:53:40 +00:00
Arjan
2e05dc8618 Météo-France: Additional states and change weather condition for "Ciel clair" (#143198)
* Additional new states and change for ciel-clair

* Adding new previously unmapped state

* Adding new forecast state

Adding Brouillard dense, reported after the review
2025-04-25 06:53:39 +00:00
J. Diego Rodríguez Royo
d8233b4de5 Create Home Connect active and selected program entities only when there are programs (#143185)
* Create active and selected program entities only when there are programs

* Test improvements
2025-04-25 06:53:37 +00:00
Arjan
7cbc3ea65f Meteofrance: adding new states provided by MF API since mid April (#143137) 2025-04-25 06:53:36 +00:00
J. Nick Koston
cb0523660d Improve error logging when state is too long (#143636) 2025-04-24 18:37:32 -10:00
Michael
605bf7e287 Add volume flow rate device class to water_flow sensor in PEGELONLINE (#143631)
add SensorDeviceClass.VOLUME_FLOW_RATE to water_flow sensor
2025-04-25 00:42:58 +02:00
Michael
3405b2549b Add new units L/h , L/s and m³/s to volume flow rate sensor device class (#143625)
add new units L/h , L/s and m³/s
2025-04-25 00:17:47 +02:00
Shay Levy
d83c617566 Fix naming consistency in Switcher service strings (#143629) 2025-04-25 01:00:42 +03:00
Brett Adams
7016c19b2f Disable polling for modern vehicles in Teslemetry (#143495) 2025-04-24 23:59:26 +02:00
Simone Chemelli
5cd4a0ced6 Use typed ConfigEntry in SamsungTV (#143627) 2025-04-24 23:55:10 +02:00
J. Nick Koston
347c1a2141 Remove duplicate _attr_should_poll in ESPHome EsphomeAssistSatelliteWakeWordSelect (#143624) 2025-04-25 00:41:51 +03:00
J. Nick Koston
46eae64ef6 Mark ESPHome quality as platinum (#143033) 2025-04-24 11:30:51 -10:00
J. Nick Koston
a74fe60b91 Fix ESPHome async_step_reconfigure signature (#143620) 2025-04-24 11:30:27 -10:00
J. Nick Koston
fab70a80bb Quality improvements for the ESPHome dashboard coordinator (#143619) 2025-04-24 23:20:05 +02:00
J. Nick Koston
2abe2f7d59 Remove unused hass from EsphomeAssistSatelliteWakeWordSelect (#143618) 2025-04-24 11:18:39 -10:00
Abílio Costa
cc970354d7 Add Maytag virtual integration supported by Whirlpool (#143612) 2025-04-24 23:14:39 +02:00
Jan Bouwhuis
e389ff2537 Allow float for device_tracker location accuracy (#143604) 2025-04-24 23:09:18 +02:00
hahn-th
088f0c82bd Bump homematicip to 2.0.1 (#143609) 2025-04-24 23:07:59 +02:00
Norbert Rittel
fa1bb27dd2 Fix sentence-casing of "webhook" in gpslogger and geofency (#143614)
* Fix sentence-casing of "webhook" in `gpslogger`

* Fix sentence-casing of "webhook" in `geofency`
2025-04-25 00:07:42 +03:00
J. Nick Koston
5a6ce34352 Improve ESPHome test typing (#143617) 2025-04-24 10:41:37 -10:00
Paulus Schoutsen
fdcb88977a Add voice styles to HA Cloud (#143605)
* Add voice styles to HA Cloud

* Add seperator and extract util
2025-04-24 16:23:15 -04:00
Stefan Agner
a584ccb8f7 Remove add-on changelog from cached information (#143526) 2025-04-24 22:14:46 +02:00
Mick Vleeshouwer
cc290b15f6 Fix available status of entities in Overkiz (#143538)
* Add availability property to OverkizEntity for device status

* Update homeassistant/components/overkiz/entity.py

Co-authored-by: J. Nick Koston <nick+github@koston.org>

---------

Co-authored-by: J. Nick Koston <nick+github@koston.org>
2025-04-24 21:58:36 +02:00
Shay Levy
575db4665d Fix Switcher review comments (#143607) 2025-04-24 21:54:25 +02:00
J. Nick Koston
a61aff8432 Cleanup duplicate entry data in ESPHome assist_satellite (#143611) 2025-04-24 09:51:58 -10:00
J. Nick Koston
3aa1c60fe3 ESPHome quality improvements round 2 (#143613)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-24 09:51:33 -10:00
Abílio Costa
39f3aa7e78 Mark Whirlpool quality as bronze (#143603) 2025-04-24 20:44:15 +02:00
J. Nick Koston
01e2c3272b Improve error message when ESPHome reconfigure selects an unexpected device (#143608) 2025-04-24 08:44:02 -10:00
J. Nick Koston
5afcd3e54e Remove the previously deprecated ESPHome assist in progress binary sensor (#143536) 2025-04-24 08:43:48 -10:00
Norbert Rittel
b081064954 Use correct singular and lowercase for "webhook" in mailgun (#143595) 2025-04-24 21:38:42 +03:00
Norbert Rittel
11e63ca96a Use correct singular and lowercase for "webhook" in twilio (#143596) 2025-04-24 21:38:03 +03:00
Abílio Costa
6457d46107 Raise ConfigEntryNotReady when fetching Whirlpool appliances fails (#143601) 2025-04-24 21:25:15 +03:00
Norbert Rittel
987bf4d850 Fix spelling of "counterclockwise" in deconz (#143523) 2025-04-24 21:23:40 +03:00
Paulus Schoutsen
fa80c0a88d Bump hass-nabucasa to 0.96.0 (#143542)
* Bump hass-nabucasa to 0.96.0

* Adjust for new voice info format
2025-04-24 13:12:11 -04:00
Norbert Rittel
f69484ba02 Fix missing plural on "Advisories" in environment_canada (#143562) 2025-04-24 19:17:30 +03:00
Norbert Rittel
11f63c7868 Use common strings for "already_in_progress" etc. in music_assistant (#143570)
* Use common string for "already_in_progress" in `music_assistant`

* Use common string for "cannot_connect" as well
2025-04-24 19:16:43 +03:00
Norbert Rittel
3245124553 Use common string for error::unknown in iometer (#143575) 2025-04-24 19:16:33 +03:00
Joost Lekkerkerker
44475967eb Bump pysmartthings to 3.0.5 (#143586) 2025-04-24 19:13:58 +03:00
Norbert Rittel
2d27b5ac53 Use common string for abort::unknown in srp_energy (#143576) 2025-04-24 17:20:53 +02:00
Erik Montnemery
2ae161d8b5 Wait for person integration in onboarding (#143584) 2025-04-24 17:08:53 +02:00
Norbert Rittel
aefe83b1a3 Use common string for "cannot_connect" in imgw_pib (#143574) 2025-04-24 16:54:41 +02:00
Abílio Costa
f86e85b931 Use None for Unknown state in Whirlpool sensor (#143582) 2025-04-24 15:12:45 +01:00
dependabot[bot]
993ebc9eba Bump github/codeql-action from 3.28.15 to 3.28.16 (#143546)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.15 to 3.28.16.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v3.28.15...v3.28.16)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.28.16
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-24 15:34:14 +02:00
dependabot[bot]
1d99bbf22e Bump actions/setup-python from 5.5.0 to 5.6.0 (#143545)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5.5.0 to 5.6.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v5.5.0...v5.6.0)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: 5.6.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-24 15:32:11 +02:00
Åke Strandberg
eb4fa635bf Add miele light platform (#143119)
* WIP

* Add light platform

* Address review comments

* Address review and improve tests

* Address review comments in tests
2025-04-24 15:02:39 +02:00
Michael
49522d93df Enable strict type checks for PEGELONLINE (#143563)
enable strict type checks for pegel_online
2025-04-24 14:42:47 +02:00
Norbert Rittel
9e0a7122f5 Fix typos and use a common string in synology_dsm (#143573)
- fix spelling of "Home Assistant", removing wrong hyphen
- remove excessive comma
- fix spelling of "passcode" (single word)
- capitalize "Zeroconf" (name)
- use common string for "reconfigure_successful"
2025-04-24 14:36:49 +02:00
Åke Strandberg
e4fe7ba985 Fix bug in miele diagnostics (#143569)
Fix bug when redacting identifiers in diagnostics
2025-04-24 14:16:31 +02:00
Simone Chemelli
f3ea11bbc1 Bump aiovodafone to 0.10.0 to use async_create_clientsession in Vodafone Station integration (#143537)
* Use async_create_clientsession in Vodafone Station integration

* bump library and rename method
2025-04-24 14:05:42 +02:00
Simone Chemelli
55de91530d Bump aiocomelit to 0.12.0 to use async_create_clientsession in Comelit integration (#143528)
* Use async_create_clientsession in Comelit integration

* bump library and rename method
2025-04-24 14:05:11 +02:00
Maciej Bieniek
290bbcfa3e Improve type annotation in the Shelly text and number platform (#143568)
* Define _id with type

* Define attribute_value with type
2025-04-24 13:55:40 +02:00
Maciej Bieniek
061a1be2bc Use DeviceInfo in the Shelly RPC entity base class (#143565)
Use DeviceInfo
2025-04-24 13:49:43 +02:00
Michael
4bd8c319dd Small fixes to the translation strings in PEGELONLINE (#143567)
small fixes
2025-04-24 13:47:23 +02:00
Michael
367022dd8c Use shorthand attributes in PEGELONLINE (#143564)
use shorthand attributes
2025-04-24 13:39:34 +02:00
ildar170975
f1975d9dbf Elevate Recorder "Error executing ..." from warning to error (#142816) 2025-04-24 11:36:39 +01:00
Retha Runolfsson
0764cf1165 Bump PySwitchbot to 0.60.1 (#143551) 2025-04-23 23:02:41 -10:00
Retha Runolfsson
a55a6e5c48 Add diagnostics for switchbot integration (#143389) 2025-04-23 21:02:44 -10:00
J. Nick Koston
5230aa8917 Increase zeroconf timeout to 10s (#143541) 2025-04-23 19:52:35 -10:00
Retha Runolfsson
f7e3e207b7 Add parallel updates in lock and lock unit tests for switchbot integration (#143391)
Co-authored-by: J. Nick Koston <nick@koston.org>
2025-04-23 19:49:09 -10:00
Erwin Douna
6f0c59f1be Tado bump 0.18.14 & race condition fix (#143531)
* Bump PyTado 0.18.14

* Add test
2025-04-24 08:44:17 +03:00
Josef Zweck
5fcdbd7742 Bump onedrive-personal-sdk to 0.0.14 (#143534) 2025-04-24 08:43:13 +03:00
J. Nick Koston
4173ff5339 Small quality fixes for ESPHome (#143535) 2025-04-23 09:42:27 -10:00
Abílio Costa
e8c4d08b25 Make Whirlpool test check for success after failure (#143525) 2025-04-23 21:00:32 +03:00
J. Nick Koston
36081c69e0 Break apart zeroconf integration to prepare for WebSocket API (#143490) 2025-04-23 07:47:37 -10:00
J. Nick Koston
65db3c1164 Fix display issues with ESPHome encryption key steps (#143483) 2025-04-23 18:39:32 +02:00
Maciej Bieniek
11f02e48d7 Use aioshelly method to set the target temperature for Shelly BLU TRV (#143504) 2025-04-23 18:37:29 +02:00
Stefan Agner
e41283a40a Handle Tailscale hosts without client connectivity details (#143505) 2025-04-23 18:36:55 +02:00
Abílio Costa
738e39413d Fix KeyError in energy websocket (#143519) 2025-04-23 18:34:48 +02:00
Norbert Rittel
8df0a950f7 Make use of "counterclockwise" consistent in hue (#143521) 2025-04-23 18:34:37 +02:00
Robert Resch
199a274c80 Remove deprecated hass.helpers (#143514) 2025-04-23 17:24:25 +02:00
Allen Porter
731d1ab796 Add quality scale for google calendar integration (#131328)
* Add quality scale for google calendar integration

* Update status and comments for the quality scale

* Update based on pr feedback

* Update quality_scale.yaml

* Update quality_scale.yaml

* Update quality_scale.yaml

* Update quality_scale.yaml

* Update quality_scale.yaml

* Update quality_scale.yaml for dependency-transparency

* Score silver, gold, and platinum levels

* Update quality scale

* Update quality scale
2025-04-23 16:32:20 +02:00
Manu
f6d8868eb6 Fix some minor issues and nitpicks in ntfy integration (#143516)
Fix nitpicks
2025-04-23 16:28:58 +02:00
Michael
253cc377b4 Remove boost and off temperature workaround from AVM Fritz!SmartHome (#142863)
* remove workaround

* remove hvacmode from mapping dict
2025-04-23 16:12:35 +02:00
J. Diego Rodríguez Royo
1bfd585f3c Adjust Home Connect max executions parameters (#143509)
Adjust max executions parameters to ensure that 1000 calls per day are not reached
2025-04-23 15:52:53 +02:00
Tobias Sauerwein
839eb0fe14 Bump pyatmo to 9.0.0 (#143512)
* wip

* fix

* fix

* fix

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-04-23 16:24:03 +03:00
Robert Resch
3dcd06806d Rename Nuki to Nuki Bridge (#143463)
* Rename Nuki to Nuki bridge

* Apply suggestions from code review

Co-authored-by: Shay Levy <levyshay1@gmail.com>

---------

Co-authored-by: Shay Levy <levyshay1@gmail.com>
2025-04-23 15:10:26 +02:00
Manu
3c174ce329 Add ntfy (ntfy.sh) integration (#135152)
Co-authored-by: Robert Resch <robert@resch.dev>
2025-04-23 14:52:13 +02:00
Arjan
8a2347539c Météo-France: Additional states and change weather condition for "Ciel clair" (#143198)
* Additional new states and change for ciel-clair

* Adding new previously unmapped state

* Adding new forecast state

Adding Brouillard dense, reported after the review
2025-04-23 14:44:36 +02:00
Jan-Philipp Benecke
f22eca3d9e Remove deprecated hass.components (#141947) 2025-04-23 14:04:36 +02:00
Robert Resch
3cb301214f Fix hassfest type hints for ConfigSubentryFlow (#143502) 2025-04-23 12:14:00 +01:00
Marc Mueller
8215faea0d Replace unnecessary MappingProxyType runtime uses in integrations (#143507) 2025-04-23 12:22:12 +02:00
turakamou
beab4e0d7c Fix device tracker of freebox component to get devices from all interfaces (#142668) 2025-04-23 11:14:37 +01:00
Maciej Bieniek
b785d5297a Use aioshelly methods with Shelly RPC text and select entities (#143464) 2025-04-22 22:07:05 -10:00
Norbert Rittel
d86d7b8843 Fix sentence-casing in two strings of group (#143500)
Make them consistent with the rest of the integration.
2025-04-23 10:32:09 +03:00
cnico
2ca5f05555 Bump dio-chacon-api to v1.2.2 (#143489)
Bump dio-chacon-api to v1.2.2 to solve https://github.com/home-assistant/core/issues/142808
2025-04-23 10:31:43 +03:00
J. Nick Koston
e95188059f Bump fnv-hash-fast to 1.5.0 (#143494)
changelog: https://github.com/Bluetooth-Devices/fnv-hash-fast/compare/v1.4.0...v1.5.0
2025-04-23 10:31:23 +03:00
dependabot[bot]
73e6c8541c Bump sigstore/cosign-installer from 3.8.1 to 3.8.2 (#143501)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-23 09:26:01 +02:00
epenet
6f9c8b2aa0 Add exception translations to Renault (#143452) 2025-04-23 08:40:31 +02:00
Marc Mueller
2d20df37b1 Use runtime data for hyperion (#143461)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-22 13:24:47 -10:00
tdfountain
0b2e5cd253 Move device registry into function declaration for tests in NUT (#143349) 2025-04-22 13:11:14 -10:00
Arie Catsman
0208188bb5 Apply for bronze integration quality status for enphase_envoy (#136332)
Co-authored-by: Joostlek <joostlek@outlook.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2025-04-22 11:59:58 -10:00
tdfountain
44ae596929 Add translated UoM for non-standard sensor measures in NUT (#143307) 2025-04-22 11:56:43 -10:00
Maciej Bieniek
db0cbf1ea9 Use rpc_call decorator in the Shelly entity module (#143484) 2025-04-22 11:51:08 -10:00
Josef Zweck
896da4abbd Bump pylamarzocco to 2.0.0b3 (#143477) 2025-04-22 21:26:26 +02:00
Josef Zweck
731e9bbbfc Fix issue in with jellyfin during browsing (#143478) 2025-04-22 19:59:24 +01:00
Manu
bf1c138a3c Fix some mistakes in the Habitica tests (#143465) 2025-04-22 20:53:09 +02:00
Paulus Schoutsen
00fc3e2c29 ESPHome Assist Satellite share TTS url in RUN_START (#143460) 2025-04-22 14:22:31 -04:00
Norbert Rittel
a258aa50a5 Fix inconsistent spelling of "add-ons" in analytics_insights (#143466) 2025-04-22 19:35:29 +02:00
Marc Mueller
3cf12a4792 Replace unnecessary MappingProxyType annotations in integrations (#143451) 2025-04-22 18:14:32 +02:00
Andre Lengwenus
e56f6fafdc Remove redundant parameter from config_entry data of LCN integration (#135912) 2025-04-22 18:00:30 +02:00
Thomas55555
e9789e0b3e Add/remove devices on push in Husqvarna Automower (#142550)
Co-authored-by: Robert Resch <robert@resch.dev>
2025-04-22 17:58:42 +02:00
Paulus Schoutsen
8aa30b0ccb Migrate VoIP to use Assist Pipeline TTS tokens (#139671)
* Migrate VoIP to use pipeline token

* migrate announcements to use TTS token
2025-04-22 10:24:24 -04:00
Manu
871a7c87bf Fix error in diagnostics test in ista EcoTrend integration (#143456) 2025-04-22 15:52:25 +02:00
Marc Mueller
72337e4c77 Fix lg_thinq RuntimeWarning in tests (#143448) 2025-04-22 14:22:04 +02:00
Manu
aedd60e74f Add diagnostics platform to ista EcoTrend (#143428) 2025-04-22 14:12:43 +02:00
Manu
9249ea0dbb Abort reauth flow on unique id mismatch in ista EcoTrend integration (#143430) 2025-04-22 14:11:09 +02:00
Josef Zweck
357ec7034e Roll back changes on upload failure in onedrive (#143012) 2025-04-22 14:10:52 +02:00
Marc Mueller
fa4e0519fa Remove unnecessary typing casts in anthropic (#143447) 2025-04-22 14:05:59 +02:00
Manu
ccd1a08aca Clear statistics on entry removal in ista EcoTrend integration (#143433) 2025-04-22 13:57:28 +02:00
Brett Adams
c654936a91 Cleanup base streaming entity in Teslemetry (#143375) 2025-04-22 13:40:09 +02:00
Manu
6c7317fbc3 Increase test coverage in ista EcoTrend integration (#143426)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-22 13:37:13 +02:00
Josef Zweck
159e55296f Make backup listing more resilient for onedrive (#143010)
Co-authored-by: Erwin Douna <e.douna@gmail.com>
2025-04-22 13:36:59 +02:00
Manu
8a084599d8 Refactor coordinator of ista EcoTrend integration (#143422) 2025-04-22 13:29:05 +02:00
Brett Adams
24b51e0582 Delay stream startup in Teslemetry (#142447) 2025-04-22 13:23:25 +02:00
Brett Adams
2e2faeb612 Add remaining Binary Sensor entities to Teslemetry (#143384) 2025-04-22 13:16:29 +02:00
Simon Lamon
d3a8af9ed0 Add scan interval and parallel updates to LinkPlay media player (#143324) 2025-04-22 13:11:39 +02:00
Josef Zweck
def11f9959 Change lamarzocco general update frequency (#143417) 2025-04-22 12:52:27 +02:00
Mick Vleeshouwer
0b64151ae0 Add icon translations and missing text translations for select in Overkiz (#143369) 2025-04-22 12:48:35 +02:00
Mick Vleeshouwer
a86c6e0809 Add 'auto' HVACMode for AtlanticElectricalTowelDryer in Overkiz (#143243) 2025-04-22 12:45:12 +02:00
Maciej Bieniek
88821b1d0e Use aioshelly methods with Shelly RPC number entities (#142482) 2025-04-22 12:44:02 +02:00
Marc Mueller
73f636c40d Use HassKey for wemo data (#143322) 2025-04-22 12:42:24 +02:00
Ville Skyttä
042e11b1d7 Add huawei_lte config flow data descriptions (#143388) 2025-04-22 12:40:57 +02:00
epenet
06cc505956 Remember previous input in renault config flow (#143438) 2025-04-22 12:39:13 +02:00
Manu
8aab7d5504 Add translations to UpdateFailed exceptions in IronOS (#143285) 2025-04-22 12:36:14 +02:00
Brett Adams
c52f73269e Dont cache available property in Teslemetry (#143380) 2025-04-22 12:35:36 +02:00
Josef Zweck
fa2ad54d90 Bump pylamarzocco to 2.0.0b2 (#143413) 2025-04-22 12:27:10 +02:00
Marc Mueller
fa9af6a021 Use HassKey for zone data (#143323) 2025-04-22 12:18:21 +02:00
epenet
a3605921c9 De-duplicate test helper function (#143437)
* De-duplicate test helper function

* One more
2025-04-22 12:04:12 +02:00
Michael
e9269a1d33 Remove deprecated yaml import from local file (#143405) 2025-04-22 11:50:28 +02:00
Michael
39807abc7d Remove deprecated yaml import from Canary (#143410) 2025-04-22 11:49:01 +02:00
Brett Adams
08ae05cc76 Remove wake helper from Teslemetry (#143376) 2025-04-22 11:40:03 +02:00
J. Nick Koston
2188603a49 Bump aiohomekit to 3.2.14 (#143440) 2025-04-22 11:00:40 +02:00
Michael
fbe2370df7 Remove deprecated action call addon_update from Supervisor (#143404)
remove deprecated action call addon_update
2025-04-22 10:39:17 +02:00
Brett Adams
8fb1c6535d Bump teslemetry-stream to 0.7.5 (#143387)
* bump

* v0.7.5
2025-04-22 11:24:07 +03:00
Abílio Costa
6534dff4bc Remove uneeded constructor from Whirlpool climate (#143408)
* Remove uneeded constructor from Whirlpool climate

* Update homeassistant/components/whirlpool/climate.py

Co-authored-by: Josef Zweck <josef@zweck.dev>

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-22 11:04:09 +03:00
Abílio Costa
44f2897919 Use spec for Whirlpool mocks (#143416)
Use `spec` to cleanup unecessary mock function definitions.
2025-04-22 10:07:18 +03:00
J. Nick Koston
30b7e36f10 Bump yalexs-ble to 2.6.0 (#143420)
changelog: https://github.com/bdraco/yalexs-ble/compare/v2.5.7...v2.6.0
2025-04-22 10:06:28 +03:00
Norbert Rittel
2f6ad8ea4a Fix sentence-casing in intellifire (#143435)
* Fix sentence-casing in `intellifire`

* Update test_sensor.ambr

* Update test_binary_sensor.ambr
2025-04-22 10:05:01 +03:00
Norbert Rittel
78afd566ec Fix sentence-casing of "Error status" in motionmount (#143436) 2025-04-22 10:04:38 +03:00
Noah Husby
02cc679692 Bump aiorussound to 4.5.2 (#143431)
* Bump aiorussound to 4.5.1

* Bump aiorussound to 4.5.2
2025-04-22 10:03:24 +03:00
Josef Zweck
1064588c00 Add last cleaned sensor to lamarzocco (#143414) 2025-04-22 07:02:16 +02:00
Mick Vleeshouwer
54050f10b7 Add support for HVAC mode "OFF" in Somfy Heating Temperature Interface in Overkiz (#143396)
Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-21 21:31:44 +02:00
Markus Adrario
f0cf620854 Add Homee wind_monitoring_state to numbers (#139848) 2025-04-21 21:21:15 +02:00
Norbert Rittel
80f34620c8 Use common state for "Error" in peblar (#143273) 2025-04-21 20:24:02 +02:00
Michael
7030000348 Remove deprecated yaml import from Smarty (#143406)
remove deprecated yaml import
2025-04-21 18:20:57 +03:00
Álvaro Fernández Rojas
fc7f1ab42f Update aioairzone-cloud to v0.6.12 (#143400)
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2025-04-21 18:10:26 +03:00
Ville Skyttä
89a6bc4354 Huawei LTE icon improvements (#143342)
* Set icon for Huawei LTE eNodeB ID

This identifies the base station ~ tower, so use the tower icon for it.

* Use antenna rather than (power) transmission tower across

https://github.com/home-assistant/core/pull/143342#discussion_r2051781388
2025-04-21 18:09:20 +03:00
J. Nick Koston
849121a124 Improve human-readable name for new/reauth/reconfig in ESPHome (#143302)
* Improve human-readable prompt when requesting ESPHome credentials

Users reported difficulty identifying which device needs reauthentication, especially when names are similar (e.g., `power-meter` vs `power-meter-EEFF`). Previously, only the hostname was shown, which led to confusion. This change includes the config entry title or friendly name—when available—in the prompt to make device identification easier.

* Update homeassistant/components/esphome/config_flow.py

* add missing cover

* tweaks

* one more

* one more

* cover

* some are ``, some are not, make them all ``

* Apply suggestions from code review

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2025-04-21 10:25:14 -04:00
J. Nick Koston
ba6ce28d3c Add DHCP discovery subscribe websocket API (#143106)
* Add DHCP discovery subscribe websocket API

* fix circular import

* fixes

* fixes

* fixes

* reduce

* reduce

* reduce

* fix tests

* fix tests

* rework

* tests

* reduce number of lines changed

* reduce
2025-04-21 10:25:04 -04:00
Simone Chemelli
4b8447bc82 Move quality scale to bronze for UptimeRobot (#143399) 2025-04-21 15:05:44 +01:00
J. Nick Koston
6698b3a1dc Improve ESPHome abort messages for already-configured devices (#143289)
* Improve ESPHome abort messages for already-configured devices

Users often struggle to identify which ESPHome device is already configured—especially when replacing a device or renaming an existing one.
This PR improves the abort messages to include more helpful details, so users can pinpoint the conflicting device without needing to dig through the `core.config_entries` file manually.

* Update homeassistant/components/esphome/strings.json
2025-04-21 09:41:15 -04:00
J. Nick Koston
352ef0d009 Correct handling of entities with empty name for ESPHome devices (#143366)
Correct handling of empty name for ESPHome devices

If the name was set to "", ESPHome should treat this as if the
name is empty. Since protobuf treats empty fields as "" we need
to handle this as `None` internally as otherwise it leads to
friendly names like "Friendly Name " with a trailing space and
unexpected entity_id formats

fixes #132532
2025-04-21 09:38:29 -04:00
J. Nick Koston
bb73ecc1f4 Restore service call performance by avoiding expensive runtime cast (#143378)
Improve service call performance by avoiding expensive runtime type checking

Most of the overhead here was casting
2025-04-21 09:37:10 -04:00
Simone Chemelli
7ea8827e69 Fix typos in UptimeRobot tests (#143397) 2025-04-21 14:11:51 +02:00
Simon Lamon
8fa48a9781 Sync random sensor device classes (#143368) 2025-04-21 13:58:47 +02:00
mdcdr
694c768666 Fix utility_meter wrong/old value on reset (#142951)
Co-authored-by: Erwin Douna <e.douna@gmail.com>
Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
2025-04-21 12:45:57 +01:00
karwosts
51eb4770a7 Use config_entry selector for reload_config_entry (#143370) 2025-04-21 11:52:26 +01:00
J. Nick Koston
274a507bc4 Bump aiohttp to 3.11.18 (#143392)
changelog: https://github.com/aio-libs/aiohttp/compare/v3.11.17...v3.11.18
2025-04-21 13:42:21 +03:00
Retha Runolfsson
da8339066b Add light unit tests for switchbot (#140436) 2025-04-21 11:07:03 +01:00
Simone Chemelli
ee3ee5b165 Fix Vodafone Station config entry unload (#143371) 2025-04-20 23:56:09 +02:00
Adrien Cognee
e86bffdf89 Set Cozytouch hvac action from regulation mode in Overkiz (#143363)
Set cozytouch hvac action from regulation mode
2025-04-20 22:01:38 +02:00
Adrien Cognee
931161b007 Add missing icons to Cozytouch preset modes in Overkiz (#143364)
Add missing to cozytouch preset modes
2025-04-20 21:18:47 +02:00
Adrien Cognee
2d30ae2bd9 Rename Cozytouch comfort preset modes in Overkiz (#143365)
Rename cozytouch comfort preset modes
2025-04-20 21:18:31 +02:00
Norbert Rittel
1ad60881cb Fix spelling of "off-grid" in tesla_fleet (#143359)
* Fix spelling of "off-grid" in `tesla_fleet`

* Update test_number.ambr
2025-04-20 21:21:51 +03:00
Norbert Rittel
18cd389c77 Fix spelling of "off-grid" in tessie (#143358)
* Fix spelling of "off-grid" in `tessie`

* Update test_number.ambr
2025-04-20 21:21:29 +03:00
Norbert Rittel
26ea97cb44 Fix spelling of "off-grid" and "on-grid" in teslemetry (#143357)
* Fix spelling of "off-grid" and "on-grid" in `teslemetry`

* Update test_number.ambr
2025-04-20 21:21:06 +03:00
Norbert Rittel
d7f6db5efd Fix spelling of "off-grid" in apsystems (#143356)
* Fix spelling of "off-grid" in `apsystems`

* Update test_binary_sensor.ambr
2025-04-20 21:20:43 +03:00
Norbert Rittel
99b25efb67 Fix spelling of "off-grid" in goodwe (#143355) 2025-04-20 21:20:23 +03:00
karwosts
8699e69ae5 Optimize sliding window history_stats to not re-query the database every interval (#143279)
Co-authored-by: J. Nick Koston <nick@koston.org>
2025-04-20 08:08:28 -10:00
Mick Vleeshouwer
f928818bf1 Bump pyOverkiz to 1.17.1 (#143353) 2025-04-20 19:52:10 +02:00
Åke Strandberg
35e26629af Bump pymiele to 0.3.6 (#143338) 2025-04-20 20:45:28 +03:00
Ville Skyttä
6e7f49591f Upgrade huawei-lte-api to 1.11.0 (#143351) 2025-04-20 20:45:03 +03:00
Maciej Bieniek
7fea432102 Bump aioshelly to version 13.5.0 (#143350) 2025-04-20 20:42:39 +03:00
David Knowles
b76cddcf9f Bump pyschlage to 2025.4.0 (#143345) 2025-04-20 07:35:50 -10:00
Norbert Rittel
9b2faf207d Fix spelling of "off-peak", improve error message in teslemetry (#143321) 2025-04-20 12:49:16 +03:00
Norbert Rittel
9e59f07401 Use common state for "Error" in zha (#143320) 2025-04-20 11:55:36 +03:00
Norbert Rittel
928faeba0d Use common state for "Error" in tessie (#143319) 2025-04-20 11:49:34 +03:00
Norbert Rittel
521a44b953 Use common state for "Error" in roborock (#143318) 2025-04-20 11:49:17 +03:00
Norbert Rittel
fb60479578 Use common state for "Error" in prusalink (#143317) 2025-04-20 11:49:02 +03:00
Norbert Rittel
29b67505a7 Use common state for "Error" in bmw_connected_drive (#143316) 2025-04-20 11:37:27 +03:00
Norbert Rittel
6f178a8a23 Use common state for "Error", capitalize "1P" in lektrico (#143315)
- replace "Error" with new common state reference
- capitalize the abbreviation "1P" (single phase)
2025-04-20 11:37:07 +03:00
Norbert Rittel
b29c295adc Use common state for "Error" in jvc_projector (#143283) 2025-04-20 10:57:00 +03:00
Norbert Rittel
8b0f9d4317 Use common state for "Error" in aranet (#143282) 2025-04-20 10:56:27 +03:00
Norbert Rittel
e1ba2a8ca2 Use common state for "Error" in matter (#143268) 2025-04-20 10:56:12 +03:00
Norbert Rittel
eb852cec43 Use common state for "Error" in tesla_wall_connector (#143272) 2025-04-20 10:55:50 +03:00
Arjan
0bed5727cb Linkplay: bump lib to 0.2.4 (#143313) 2025-04-20 09:53:40 +02:00
Marc Mueller
a749ecceed Add helper method to clear logger overwrites for tests (#143301) 2025-04-20 09:28:30 +02:00
tdfountain
b5b934b8a1 Use _get_reauth_entry rather than storing in flow for NUT (#143308)
Use _get_reauth_entry rather than storing in flow
2025-04-20 08:30:15 +02:00
Mick Vleeshouwer
6b09fe2377 Support new local token generation method in Overkiz (#143181)
* Initial implementation of new token method for Local API

* Improve translations

* Update text

* Bugfix

* Bugfix

* Bugfixes

* Fixes

* Bugfix

* Bugfix

* Fix

* small fix

* Fix tests

* Refactor token usage in Overkiz config flow tests

* Refactor local API configuration flow tests for clarity and update reauthentication logic

* Improve comments

* Update tests

* Update homeassistant/components/overkiz/strings.json

Co-authored-by: Josef Zweck <josef@zweck.dev>

---------

Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-20 06:29:18 +02:00
tdfountain
cbb4ff2fd9 Remove icon for button that uses default icon in NUT (#143305) 2025-04-19 16:35:13 -10:00
tdfountain
eb642e8a06 Remove unused variable in test util for NUT (#143304) 2025-04-19 16:22:10 -10:00
tdfountain
b97d8e163d Fix type of port in test util for NUT (#143303) 2025-04-19 16:13:05 -10:00
tdfountain
7c0d2832cd Add remove device support to NUT (#143293) 2025-04-19 16:07:42 -10:00
Marc Mueller
205cfae1a4 Update setuptools to 78.1.1 (#143275) 2025-04-19 15:57:53 -10:00
Marc Mueller
f861a2b72c Fix licenses check for setuptools (#143292) 2025-04-20 02:24:44 +02:00
Marc Mueller
5843e63878 Add contextmanager to reset logger after set_level call in tests (#143295) 2025-04-20 02:13:01 +02:00
Marc Mueller
961f8afe53 Remove debug option in unifiprotect tests (#143296) 2025-04-19 14:00:22 -10:00
tdfountain
37769b94cd Remove unnecessary persistent notification in test case for NUT (#143298)
Remove unnecessary persistent notification
2025-04-20 01:55:26 +02:00
tdfountain
f5c0c207ec Fix display state to return None instead of STATE_UNKNOWN in NUT (#143297)
Fix return value to avoid STATE_UNKNOWN
2025-04-20 01:53:29 +02:00
tdfountain
b4344a8de2 Remove unused variable and import in NUT (#143294)
Remove unused variable in validate_input
2025-04-20 01:50:22 +02:00
J. Nick Koston
e02c200775 Bump aiohttp to 3.11.17 (#143290) 2025-04-19 12:30:43 -10:00
Marc Mueller
8f4435019b Reset logging level in esphome test (#143291) 2025-04-19 23:59:45 +02:00
Norbert Rittel
ec55f716e1 Use common state for "Error" in fronius (#143284) 2025-04-19 23:06:44 +02:00
Thomas55555
012f6b660c Add more states to error sensor in Husqvarna Automower (#143270)
* Add more states to error sensor in Husqvarna Automower

* Use new common state

* tests and duplicates
2025-04-19 21:16:01 +02:00
Norbert Rittel
9de136789c Use common state for "Error" in blue_current (#143274) 2025-04-19 21:13:52 +02:00
Thomas55555
84a8c1312f Add entity categories to Husqvarna Automower sensors (#143277) 2025-04-19 21:13:24 +02:00
Norbert Rittel
21f9ad3994 Use common state for "Error" in home_connect (#143276) 2025-04-19 21:13:09 +02:00
Norbert Rittel
a9e77dc0db Use common state for "Error", fix sentence-casing in tplink_omada (#143278)
* Use common state for "Error", fix sentence-casing in `tplink_omada`

- replace "Error" with common state reference
- correct missing sentence-casing in several strings

* Update test_switch.ambr
2025-04-19 21:12:14 +02:00
Abílio Costa
626eb77060 Replace literals with consts in Govee Light Local tests (#143280) 2025-04-19 21:11:36 +02:00
Abílio Costa
7674f6b5aa Turn on after setting parameters in Govee Light Local (#143233) 2025-04-19 19:56:56 +01:00
Norbert Rittel
16c72c491d Use common state for "Error" in lawn_mower (#143266) 2025-04-19 21:23:51 +03:00
Norbert Rittel
99e1245c9b Use common state for "Error" in vacuum (#143265) 2025-04-19 21:22:04 +03:00
tdfountain
f42b137c1b Add missing data description strings of config flow for NUT (#143267) 2025-04-19 07:27:03 -10:00
Maciej Bieniek
4e852911aa Add tracker power saving binary sensor to Tractive integration (#142718)
* Add power saving binary sensor

* Update tests

* tracker_state_reason is not always present in hardware event
2025-04-19 17:30:15 +02:00
Paulus Schoutsen
30ab068bfe Wyoming to use tokens instead of media source IDs for TTS (#139668)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-19 12:50:41 +02:00
Tsvi Mostovicz
6499ad6cdb Cleanup tests for Jewish calendar integration (#138793) 2025-04-19 12:46:04 +02:00
Paulus Schoutsen
6f99b1d69b TTS to use ffmpeg in streaming fashion (#140536) 2025-04-19 12:41:52 +02:00
J. Nick Koston
42c4ed85a1 Remove legacy format exception for ESPHome entity naming (#143049) 2025-04-19 12:41:07 +02:00
J. Nick Koston
3e3697dc7a Add reconfigure support to ESPHome (#143132) 2025-04-19 12:40:07 +02:00
epenet
ff1ab1da37 Decouple service registration in Renault (#143210) 2025-04-19 12:36:54 +02:00
Allen Porter
3da77726d0 Allow selection of multiple LLM APIs in Anthropic (#143190) 2025-04-19 12:34:51 +02:00
Josef Zweck
879cdcc0a4 Filter media players in browse media action to supported feature (#143183) 2025-04-19 12:31:39 +02:00
Josef Zweck
9b8a35dbb3 Add sensors to lamarzocco (#143156)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-19 12:30:22 +02:00
Josef Zweck
7c7f18b501 Add preinfusion settings to lamarzocco (#143159) 2025-04-19 12:29:08 +02:00
Franck Nijhof
6f0a9910ea 2025.4.3 (#143253) 2025-04-19 12:22:36 +02:00
Sid
6e8c971038 Initialize time _attr_native_value with None (#143171) 2025-04-19 12:08:29 +02:00
Josef Zweck
09131d8647 Add more features to lamarzocco updates (#143157) 2025-04-19 12:07:11 +02:00
J. Nick Koston
930fa18224 Avoid creating ClientTimeout object on every hassio ingress request (#143254) 2025-04-19 12:05:27 +02:00
Josef Zweck
9c9c115d1a Add websocket connectivity binary sensor to lamarzocco (#143161) 2025-04-19 11:52:56 +02:00
K
b6e9643586 Continue conversation with full-width question mark support (#143078) 2025-04-19 11:51:56 +02:00
LG-ThinQ-Integration
83f2acddf8 Raise ConfigEntryNotReady mqtt setup fails In LG ThinQ (#140488)
Co-authored-by: yunseon.park <yunseon.park@lge.com>
2025-04-19 11:50:13 +02:00
MichaelMKKelly
35f9cc55f1 Fix Automation/Script: sequence within a parallel ignoring enabled flag (#142977)
Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-19 11:49:05 +02:00
Allen Porter
4483025856 Update Google Generative AI to allow multiple LLM APIs (#143191) 2025-04-19 11:44:12 +02:00
Allen Porter
61e4be4456 Update OpenAI conversation agent to allow multiple LLM APIs (#143189) 2025-04-19 11:43:27 +02:00
Retha Runolfsson
f11f4510a2 Add switchot switches unit test with restore state (#143250) 2025-04-19 11:39:52 +02:00
Norbert Rittel
b3c3be0483 Add common state for "Error" (#143139) 2025-04-19 11:32:05 +02:00
Brett Adams
7c3df46570 Add typed listeners to Teslemetry binary sensor platform (#142238) 2025-04-19 11:29:14 +02:00
Franck Nijhof
b8793760a1 Bump version to 2025.4.3 2025-04-19 09:17:04 +00:00
Joost Lekkerkerker
6264f9c67b Fix missing binary sensor for CoolSelect+ in SmartThings (#143216) 2025-04-19 09:16:46 +00:00
Joost Lekkerkerker
2a74deb84e Fix SmartThings soundbar without media playback (#143170) 2025-04-19 09:16:45 +00:00
puddly
9d1ff37a79 Bump ZHA to 0.0.56 (#143165)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-19 09:16:43 +00:00
Franck Nijhof
2f99164781 Reduce jumping Starlink uptime sensor (#143076) 2025-04-19 09:16:42 +00:00
Marc Mueller
80ef32f09d Add Python-2.0 to list of approved licenses (#143052) 2025-04-19 09:16:40 +00:00
G Johansson
63be0e2e1a Bump pysmhi to 1.0.2 (#143007)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-19 09:16:39 +00:00
Simone Chemelli
74c4553bb0 Increase uptime deviation for Shelly (#142996)
* Increase uptime deviation for Shelly

* fix test

* make troubleshooting easy

* change deviation interval

* increase deviation to 1m
2025-04-19 09:16:38 +00:00
starkillerOG
e240707b32 Bump reolink-aio to 0.13.2 (#142985) 2025-04-19 09:16:36 +00:00
Simone Chemelli
7c867852a9 Fix switch state for Comelit (#142978) 2025-04-19 09:16:35 +00:00
G Johansson
2d149dc746 Bump holidays to 0.70 (#142954) 2025-04-19 09:16:33 +00:00
Alex L
7edcddd3e4 Update UK Transport Integration URL (#142949) 2025-04-19 09:16:32 +00:00
Tsvi Mostovicz
71f658b560 Don't do I/O while getting Jewish calendar data schema (#142919) 2025-04-19 09:16:31 +00:00
Guido Schmitz
9886db5d6d Bump devolo_plc_api to 1.5.1 (#142908) 2025-04-19 09:16:29 +00:00
Glenn Waters
c236cd070c Bump Environment Canada library to 0.10.1 (#142882) 2025-04-19 09:16:28 +00:00
Kevin Stillhammer
9f1a830d32 Only get tracked pairs for kraken (#142877)
Only get tracked pairs

Getting all available pairs leads to a too long request URL
2025-04-19 09:16:26 +00:00
Allen Porter
1e69ce9111 Fix quality loss for LLM conversation agent question answering (#142873)
* Fix a bug parsing a streaming response with no json

* Remove debug lines

* Fix  quality loss for LLM conversation agent question answering

* Update tests
2025-04-19 09:15:41 +00:00
starkillerOG
389297155d Fix Reolink Home Hub Pro playback (#142871)
Fix Home Hub Pro playback
2025-04-19 09:12:22 +00:00
starkillerOG
c341b86520 Select correct Reolink device uid (#142864)
* Select correct device_uid

* Fix styling

* restructure

* Add test

* Update test_util.py

* Add explanation string
2025-04-19 09:12:21 +00:00
Eric Park
88eef379b2 Keep track of last play status update time in Apple TV (#142838) 2025-04-19 09:12:20 +00:00
peteS-UK
34767d4058 Force Squeezebox item id to string (#142793)
force item_id to string
2025-04-19 09:12:18 +00:00
Dionisis Toulatos
12c3d54a63 Fix MQTT device discovery when using node_id (#142784)
* Fix device discovery when using node_id

* tests

---------

Co-authored-by: jbouwh <jan@jbsoft.nl>
Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
2025-04-19 09:12:16 +00:00
Manu
33a185dade Fix error in recurrence calculation of Habitica integration (#142759)
Fix error in rrule calculation of Habitica integration
2025-04-19 09:12:15 +00:00
Erik Montnemery
c1c5776d85 Correct enum member check in home_connect (#142666)
* Correct enum member check in home_connect

* Update homeassistant/components/home_connect/coordinator.py

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

* Add mypy override

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-19 09:12:14 +00:00
Brett Adams
eda642554d Check Energy Live API works before creating the coordinator in Tessie (#142510)
* Check live API works before creating the coordinator

* Fix diag

* Fix mypy on entity

* is not None
2025-04-19 09:12:11 +00:00
Chase Mamatey
51f5ce013f Fix duke_energy data retrieval to adhere to service start date (#136054) 2025-04-19 09:12:10 +00:00
Josef Zweck
44450f9d7d Fix reconfigure flow for lamarzocco (#143152) 2025-04-19 11:07:45 +02:00
Brett Adams
c34e280fc2 Add typed listeners to Teslemetry sensor platform (#142236) 2025-04-19 10:56:29 +02:00
J. Nick Koston
aef266b940 Refactor live history and logbook to avoid unnecessary task creation for recorder sync (#143244) 2025-04-19 10:55:11 +02:00
G Johansson
f873219d25 Bump pysmhi to 1.0.2 (#143007)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-18 22:45:09 -10:00
Louis Christ
7de5646d6b Bump pyblu to 2.0.1 (#143178) 2025-04-19 10:41:50 +02:00
puddly
1e89f3ec9a Bump ZHA to 0.0.56 (#143165)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-19 10:38:34 +02:00
Joost Lekkerkerker
d8d9449e2b Fix SmartThings soundbar without media playback (#143170) 2025-04-19 09:53:31 +02:00
Marc Mueller
850d9a0254 Update types packages (#143187) 2025-04-19 09:52:09 +02:00
tmenguy
c422bcf1e2 Make renault scan interval dynamic (#142964)
Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2025-04-19 09:51:41 +02:00
Retha Runolfsson
27b7fb6f91 Add humidifier unit test for switchbot (#143207) 2025-04-19 09:48:01 +02:00
Mick Vleeshouwer
302dbc424b Add device class and options to sensor defect for Overkiz (#143241) 2025-04-19 06:51:33 +02:00
J. Nick Koston
a7922690c4 Adjust cover reproduce state to prefer setting positions if supported (#143226) 2025-04-18 11:34:33 -10:00
Mick Vleeshouwer
5541de2bcb Fix state class for tariff sensor in Overkiz (#143234) 2025-04-18 22:15:35 +02:00
Mick Vleeshouwer
4c14184111 Add native units, device classes, and state classes for consumption sensors in Overkiz (#143239) 2025-04-18 22:13:49 +02:00
Mick Vleeshouwer
d78f63e4d0 Add device class for outlet engine sensor in Overkiz integration (#143238) 2025-04-18 22:12:30 +02:00
Mick Vleeshouwer
f38d50b928 Add duration device class and unit of measurement for Overkiz (#143237) 2025-04-18 22:11:51 +02:00
Mick Vleeshouwer
5c5b832d01 Add device class for moisture detection in Overkiz binary sensors (#143236) 2025-04-18 22:11:06 +02:00
Jan Bouwhuis
2b4c5178f4 Fix Intergas climate entity category (#143240) 2025-04-18 22:09:50 +02:00
J. Nick Koston
59588f960d Fix flakey Bluetooth options flow tests (#143215) 2025-04-18 10:08:17 -10:00
Joost Lekkerkerker
d3b335f53f Fix missing binary sensor for CoolSelect+ in SmartThings (#143216) 2025-04-18 20:41:18 +03:00
Josef Zweck
c3037bae39 Add service definition for user facing action to media player search (#143177)
* Add service definition for user facing action to media player search

* add filter

* Reorder and update fields in services.yaml
2025-04-18 15:07:46 +02:00
J. Nick Koston
9b1ab34352 Fix hassio mocking in ESPHome dashboard tests (#143212) 2025-04-18 14:11:36 +02:00
J. Nick Koston
221a8597da Make unknown media source exception translatable (#143208) 2025-04-18 01:17:56 -10:00
J. Nick Koston
45022752a0 Make remaining ESPHome exceptions translatable (#143184) 2025-04-17 22:22:08 -10:00
J. Nick Koston
aa342eb476 Add additional config entry typing to ESPHome (#143126) 2025-04-17 22:03:52 -10:00
J. Nick Koston
32b26b8270 Add icons for ESPHome entities (#143202) 2025-04-17 21:56:11 -10:00
J. Nick Koston
e07c29caad Small improvements to ESPHome setup (#143204) 2025-04-17 21:51:16 -10:00
J. Nick Koston
b487c12ab1 Remove unreachable code in ESPHome media_players (#143203) 2025-04-17 21:51:03 -10:00
J. Diego Rodríguez Royo
60293648dc Create Home Connect active and selected program entities only when there are programs (#143185)
* Create active and selected program entities only when there are programs

* Test improvements
2025-04-18 00:09:52 +02:00
Abílio Costa
e7994b3da1 Fix missing go2rtc dependency in non-docker setups (#143172) 2025-04-17 10:03:47 -10:00
Josef Zweck
b88bf74e13 Cleanup lamarzocco tests (#143176) 2025-04-17 20:53:47 +02:00
peteS-UK
8355727eb1 Fix for media content type case in Squeezebox (#143099) 2025-04-17 18:56:28 +02:00
Marc Mueller
c7290908cc Update mypy-dev 1.16.0a8 (#143166) 2025-04-17 18:13:00 +02:00
Abílio Costa
1307cd4b10 Add bronze quality scale for Whirlpool (#142752) 2025-04-17 15:31:12 +01:00
Abílio Costa
c0b2193718 Use freezer for time change in Whirlpool config flow test (#143162) 2025-04-17 16:14:21 +02:00
Abílio Costa
f9bb7e404e Improve Whirlpool config flow test completeness and naming (#143118) 2025-04-17 13:40:57 +01:00
Josef Zweck
bbb8a1bacc Migrate lamarzocco to pylamarzocco 2.0.0 (#142098)
* Migrate lamarzocco to pylamarzocco 2.0.0

* bump manifest

* Remove CONF_TOKEN

* remove icons

* Rename coordiantor

* use none for token

* Bump version

* Move first get settings

* remove sensor snapshots

* Change iot_class from cloud_polling to cloud_push

* Update integrations.json

* Re-add release url

* Remove extra icon, fix native step

* fomat

* Rename const

* review comments

* Update tests/components/lamarzocco/test_config_flow.py

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

* add unique id check

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-17 13:34:06 +02:00
Petar Petrov
0aaa4fa79b Create empty Z-Wave JS device on smart start provisioning (#140872)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-17 13:18:48 +02:00
Paul Bottein
4ed81fb03f Use firmware name from device class for matter update entity (#143140)
* Use firmware name from device class for matter update entity

* Update tests
2025-04-17 12:50:10 +02:00
Åke Strandberg
7d13c2d854 Add miele diagnostics platform (#142900) 2025-04-17 11:42:07 +02:00
Petar Petrov
cadbb623c7 New ZWave-JS migration flow (#142717)
* ZwaveJS radio migration flow

* Partial migration flow

* basic migration flow

* report exact progress to frontend

* Display backup file path

* string tweak

* update tests

* improve exception handling

* radio -> controller

* test tweak

* test tweak

* clean up and test error handling

* more tests

* test progress

* PR comments

* fix tests

* test restore progress

* more coverage

* coverage

* coverage

* make mypy happy

* PR comments

* Apply suggestions from code review

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

* ruff

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-17 10:14:47 +02:00
J. Nick Koston
4d959fb91c Bump esphome-dashboard-api to 1.3.0 (#143128) 2025-04-17 09:57:55 +02:00
J. Nick Koston
1fb3d8d601 Bump habluetooth to 3.39.0 (#143125) 2025-04-17 09:56:38 +02:00
J. Nick Koston
dd4334e3ba Bump yarl to 1.20.0 (#143124) 2025-04-17 09:55:30 +02:00
Sid
5eee47d1e4 Bump eheimdigital to 1.1.0 (#143138) 2025-04-17 09:44:40 +02:00
Arjan
54def1ae0e Meteofrance: adding new states provided by MF API since mid April (#143137) 2025-04-17 08:47:37 +02:00
J. Nick Koston
6a36fc75cf Fix flakey ESPHome dashboard tests (attempt 2) (#143123)
These tests do not need a config entry, only the integration
to be set up. Since I cannot replicate the issue locally after
1000 runs, I switched it to use async_setup_component to minimize
the potential problem area and hopefully fix the flakey test

I also modified the test to explictly set up hassio to ensure
the patch is effective since we have to patch a late import

last observed flake: https://github.com/home-assistant/core/actions/runs/14503715101/job/40689452294?pr=143106
2025-04-17 08:36:34 +02:00
Josef Zweck
bf69d4e0a8 Add search to media_player (#140321)
* Add search to media_player

* rename attr

* Add searchable property

* add pagination parameters

* Add suggested changes

* Apply suggestions

* Fix cast tests

* Fix first set of components

* update snapshot

* More tests

* more test fixes

* Rename attr

* first own test

* Add to google test

* Add service test

* Rename search query arg

* Add required feature to search service

* remove kwarg

* Update homeassistant/components/media_player/__init__.py

Co-authored-by: Marcel van der Veldt <m.vanderveldt@outlook.com>

* fix hue test

---------

Co-authored-by: Marcel van der Veldt <m.vanderveldt@outlook.com>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2025-04-16 23:09:16 +02:00
Eric Park
fe248a2ebd Keep track of last play status update time in Apple TV (#142838) 2025-04-16 22:41:32 +02:00
Norbert Rittel
49ad9a8bd5 Use common states for "Auto" and "Manual" in smartthings (#142976) 2025-04-16 22:28:34 +02:00
Franck Nijhof
fa75b477e9 Add device class for fuel sensor in StarLine integration (#143111) 2025-04-16 22:11:14 +02:00
Guido Schmitz
3c1d93f503 Use entity_registry_enabled_by_default fixture in devolo Home Network (#143108) 2025-04-16 21:12:50 +02:00
Norbert Rittel
21fabd3afa Use common state for "Manual" in tolo (#143104) 2025-04-16 21:47:07 +03:00
Norbert Rittel
0ec4652b52 Use common state for "Manual", unify intercardinal directions in netatmo (#143062)
In US English the intercardinal directions (Northeast, Southwest, etc.) are written in single words, not using hyphens. That can be adapted in Lokalise for Home Assistant's "English (United Kingdom)" UI language.

Making them identical in both occurrences also resolves the missing sentence-casing of "North-East" etc.
2025-04-16 21:44:24 +03:00
Abílio Costa
e901dc4ec4 Move _attr_should_poll to base Whirlpool entity class (#143100) 2025-04-16 21:43:38 +03:00
Artur Pragacz
9d02436a72 Remove outdated test for locks (#143061)
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
2025-04-16 18:34:14 +01:00
Guido Schmitz
9fb7542a6f Remove old test in devolo Home Network (#143095) 2025-04-16 17:29:44 +01:00
Norbert Rittel
ddf37a847d Use common state for "Manual", fix sentence-casing in homekit_controller (#143083) 2025-04-16 06:19:43 -10:00
Evan Graham
024ec2b153 OpenAI Conversation: Add web search support for new models (#143054)
Use a list of openai models for web search support in openai_conversation
2025-04-16 18:08:36 +02:00
Alex Meridian
f8b56c460e Update blueprint syntax (#135050) 2025-04-16 15:41:14 +02:00
Guido Schmitz
42277955fa Use icon translations in devolo Home Network device tracker (#143089) 2025-04-16 15:38:26 +02:00
Abílio Costa
950c332e36 Fix wrong return type in Whirlpool test helper (#143085) 2025-04-16 14:10:25 +02:00
Simone Chemelli
44d6f0bc2b Increase uptime deviation for Shelly (#142996)
* Increase uptime deviation for Shelly

* fix test

* make troubleshooting easy

* change deviation interval

* increase deviation to 1m
2025-04-16 14:02:27 +02:00
rappenze
9bff88ad3e Add diagnostics to fibaro integration (#143003)
* Add diagnostics to fibaro

* Enhance diagnostic test

---------

Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-16 14:52:42 +03:00
Guido Schmitz
8de23b9559 Raise on failed switching in devolo Home Network (#143072) 2025-04-16 13:49:37 +02:00
Abílio Costa
fbba0d9a21 Remove unused fixtures from Whirlpool (#143082) 2025-04-16 13:39:28 +02:00
Abílio Costa
5beb415ada Refactor Whirlpool climate tests (#142689) 2025-04-16 12:03:40 +01:00
Franck Nijhof
187024367a Reduce jumping Starlink uptime sensor (#143076) 2025-04-16 12:23:54 +02:00
Norbert Rittel
e6262de5ab Use common state for "Manual" in homee (#143063) 2025-04-16 12:44:14 +03:00
Maksim Doroshko
c96bb45940 Use pyephember2 library in ephember (#140459)
* multiple homes support, all zones visible

* Update homes and zones

* set zone, target temp, curent temp, hot water type fixes

* Hotwater devices added

* Mode ajust

* next version could be 0.4.4

* depricated climate feature removed ClimateEntityFeature

* Migrate to pyephember2

* HEAT_COOL mode

* Revert EPH_TO_HA_STATE to HEAT_COOL

* homes and ember declaretion removed

* cleaning try catch blocks, flatten list on zones

* refactored

* Version updated

* try catch returned

* pyephember2==0.4.12

* Update homeassistant/components/ephember/climate.py

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

* reverting unique_id and depricated vClimateEntityFeature.AUX_HEAT

* Update homeassistant/components/ephember/climate.py

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

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-16 10:43:39 +02:00
Joost Lekkerkerker
50796a6a77 Grade Syncthru on the quality scale (#142829)
* Grade Syncthru on the quality scale

* Update homeassistant/components/syncthru/quality_scale.yaml

Co-authored-by: Josef Zweck <josef@zweck.dev>

* Update homeassistant/components/syncthru/quality_scale.yaml

---------

Co-authored-by: Josef Zweck <josef@zweck.dev>
2025-04-16 10:42:41 +02:00
J. Nick Koston
0fb0e132b6 Explictly set PARALLEL_UPDATES in ESPHome assist_satellite entity platform (#143068) 2025-04-15 21:39:47 -10:00
Norbert Rittel
494a991d10 Use common states for "Auto" / "Manual" in lametric (#143066) 2025-04-16 09:25:37 +02:00
J. Nick Koston
c32654db18 Add translated exception for ESPHome action call failures (#143067) 2025-04-15 21:19:05 -10:00
J. Nick Koston
f4e7ccfcfc Explictly set PARALLEL_UPDATES for ESPHome entity platforms (#143065) 2025-04-15 21:11:05 -10:00
J. Nick Koston
4a4cbe011a Bump aioesphomeapi to 30.0.1 (#143056) 2025-04-16 08:00:20 +02:00
J. Nick Koston
f68111c59f Fix flakey ESPHome dashboard setup test (#143057) 2025-04-16 07:59:09 +02:00
Kamil Breguła
1d845623a8 Add links to enable Google Calendar API (#142377)
* Add links to enable Google Calendar API

* Update tests
2025-04-15 21:24:32 -06:00
Marc Mueller
a93121a88d Add Python-2.0 to list of approved licenses (#143052) 2025-04-16 00:27:07 +02:00
J. Nick Koston
4ea1d88826 Improve ESPHome strings (#143048) 2025-04-15 11:35:20 -10:00
RogerSelwyn
a87b6fee89 Update sky_hub to remove codeowner (#143047) 2025-04-15 22:57:45 +02:00
Norbert Rittel
9baf5ad404 Use common states for "Auto" and "Manual" in flipr (#143011) 2025-04-15 22:39:20 +02:00
Norbert Rittel
5fd7306446 Use common state for "Auto" in wolflink (#143014) 2025-04-15 22:38:57 +02:00
Norbert Rittel
3a8828325a Use common state for "Auto", fix sentence-casing of "QR code" in romy (#143016) 2025-04-15 22:38:06 +02:00
Norbert Rittel
57bf59f6bd Use common state for "Auto" in xiaomi_miio (#143015) 2025-04-15 22:37:21 +02:00
Franck Nijhof
f0d81d077f Adjust issue template to assign Bug issue type (#143017) 2025-04-15 22:09:59 +02:00
Norbert Rittel
bb5aefb9e4 Use common state for "Manual" in hive (#143009) 2025-04-15 21:44:41 +03:00
Norbert Rittel
6a1739e883 Use common state for "Auto", fix casing in mqtt (#143000)
- use the (new) common state for "Auto"
- capitalize one occurrence of "mqtt"
- (fully) sentence-case two title strings

Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-15 20:24:44 +02:00
J. Nick Koston
ae306893ff Handle name conflicts in ESPHome config flow (#142966) 2025-04-15 08:09:51 -10:00
Norbert Rittel
5fd17d092b Use common states for "Auto" and "Manual" in overkiz (#143005) 2025-04-15 20:56:58 +03:00
Norbert Rittel
fad1d7bd1f Use common state for "Auto" in iron_os (#143001) 2025-04-15 19:30:05 +02:00
Norbert Rittel
dcf7520d2a Use common states for "Low", "Medium", "High" and "Auto" in tuya (#143002) 2025-04-15 19:29:15 +02:00
rappenze
998b33c207 Fix device creation in fibaro integration (#142957)
* Fix device creation in fibaro integration

* Better naming
2025-04-15 18:41:53 +02:00
Abílio Costa
7b3e7b7aea Remove uneeded setdefault from Whirlpool config entry (#142999) 2025-04-15 18:03:51 +02:00
Simone Chemelli
09a86d2ed2 Add quality scale to UptimeRobot (#142912)
* Add quality scale (gold) to UptimeRobot

* todos

* tweak

* tweak comment

* update after #142940

* improve comment

* update as per review comment

* one more comment

* update reconfiguration use case
2025-04-15 17:01:38 +02:00
Sid
285f7ec696 Add number platform to eheimdigital (#142835)
* Add number platform to eheimdigital

* Pylint

* Review

* Update homeassistant/components/eheimdigital/number.py

* Update homeassistant/components/eheimdigital/number.py

* Review

---------

Co-authored-by: Josef Zweck <josef@zweck.dev>
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-15 16:45:56 +02:00
Brian Choromanski
595508bf7d Check that time_pattern interval matcher is not zero (#142630)
Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-04-15 14:50:11 +01:00
starkillerOG
2074c7fcee Bump reolink-aio to 0.13.2 (#142985) 2025-04-15 15:03:47 +02:00
Simone Chemelli
759d8a3f90 Code optimization for UptimeRobot binary (#142986) 2025-04-15 12:07:48 +02:00
cdheiser
f2fa583101 Bump lutron's dependency on pylutron to 0.2.17 (#142953)
* Bump lutron's dependency on pylutron to 0.2.17

This fixes https://github.com/home-assistant/core/issues/127672

* Bump to pylutron 0.2.18 (0.2.17 has a bug with smartquotes that 0.2.18 fixes)

---------

Co-authored-by: cdheiser <cdheiser@users.noreply.github.com>
2025-04-15 10:41:56 +02:00
dependabot[bot]
18feb4bb81 Bump codecov/codecov-action from 5.4.0 to 5.4.2 (#142974)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 5.4.0 to 5.4.2.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v5.4.0...v5.4.2)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-version: 5.4.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-15 10:40:12 +02:00
Norbert Rittel
b49a60fa3e Use common state for "Auto" in roborock (#142972)
Also moved the "off" state to the top to group the common states a bit.
2025-04-15 09:56:40 +02:00
Simone Chemelli
fa81a83893 Fix switch state for Comelit (#142978) 2025-04-15 09:55:16 +02:00
Norbert Rittel
942bf2ef78 Use common state for "Auto" in lg_thinq (#142973) 2025-04-15 08:45:37 +02:00
J. Nick Koston
a9d4b1afe4 Bump zeroconf to 0.146.5 (#142962) 2025-04-15 08:19:48 +02:00
Norbert Rittel
cdd8ba78e7 Use common state for "Auto" in climate (#142948) 2025-04-15 08:18:08 +02:00
Norbert Rittel
254d4c6534 Use common state for "Auto" and fix sentence-casing in tado (#142969) 2025-04-15 08:17:03 +02:00
Norbert Rittel
33a0db3935 Use common state for "Auto" and fix sentence-casing in plugwise (#142970) 2025-04-15 08:16:27 +02:00
Norbert Rittel
514f83cc96 Use common state for "Auto" in reolink (#142971)
The common state replaces the internal references, too.
2025-04-15 08:12:30 +02:00
Marc Mueller
4950bda406 Fix homeaticip_cloud RuntimeWarnings (#142961) 2025-04-14 23:32:52 +02:00
Norbert Rittel
9e9be6055d Use common state for "Auto" in knx (#142959) 2025-04-14 23:19:25 +02:00
Norbert Rittel
c9ccc79789 Use common state for "Auto" in vesync (#142958) 2025-04-14 22:53:01 +02:00
G Johansson
3fab596518 Bump holidays to 0.70 (#142954) 2025-04-14 22:52:21 +02:00
Ville Skyttä
3378b8d7ce Simplify huawei_lte entities event setup (#142501) 2025-04-14 22:31:27 +02:00
Alex L
881079ccc1 Update UK Transport Integration URL (#142949) 2025-04-14 22:22:53 +02:00
starkillerOG
cf1cbc6d75 Add Reolink recording packing time (#142847) 2025-04-14 22:22:21 +02:00
Michael
e418491f19 Add support for device sub units in AVM Fritz!SmartHome (#142845) 2025-04-14 22:19:14 +02:00
Norbert Rittel
a4f75ca249 Use common states "Auto" and "Manual" in osoenergy (#142950) 2025-04-14 22:18:03 +02:00
Norbert Rittel
6ba2d0be31 Replace reference from climate with common "Auto" state in baf (#142936) 2025-04-14 22:17:21 +02:00
Norbert Rittel
fb2a671e86 Use common state for "Auto" in matter (#142947) 2025-04-14 21:42:35 +02:00
J. Nick Koston
8cb62341ef Fix race to rename entity (#142584) 2025-04-14 21:42:23 +02:00
Simon Lamon
074378bef6 Bump python-linkplay to 0.2.3 (#142571) 2025-04-14 21:40:32 +02:00
Guido Schmitz
a772832917 Bump devolo_plc_api to 1.5.1 (#142908) 2025-04-14 21:24:52 +02:00
Norbert Rittel
cf467b8593 Use common state for "Auto" in sensibo (#142941) 2025-04-14 20:57:15 +02:00
Norbert Rittel
b4a3470cb9 Use common states for "Auto" and "High" in palazzetti (#142945) 2025-04-14 20:50:59 +02:00
Norbert Rittel
e44d86479e Use common state for "Auto" in airzone_cloud (#142944) 2025-04-14 20:40:38 +02:00
Norbert Rittel
42345d9a06 Use common states for "Auto"/"Manual" in huawei_lte (#142943) 2025-04-14 18:21:40 +00:00
starkillerOG
40fd7cf852 Select correct Reolink device uid (#142864)
* Select correct device_uid

* Fix styling

* restructure

* Add test

* Update test_util.py

* Add explanation string
2025-04-14 20:12:34 +02:00
J. Nick Koston
870350b961 Add async_has_entity_registry_updated_listeners (#142772) 2025-04-14 19:45:09 +02:00
Simone Chemelli
198a6b2e8f Add missing strings to UptimeRobot (#142921) 2025-04-14 19:37:01 +02:00
Simone Chemelli
0479fc6f54 Remove redundant logging from UptimeRobot config_flow (#142940) 2025-04-14 19:35:30 +02:00
Norbert Rittel
be6e1e5e15 Use common states "Auto"/"Manual", fix sentence-casing in yamaha_musiccast (#142931) 2025-04-14 19:29:22 +02:00
J. Nick Koston
9ce44845fe Add a repair for ESPHome device conflicts (#142507) 2025-04-14 07:10:05 -10:00
Joost Lekkerkerker
1463f05d46 Restore python 3.13.2 requirement (#142932) 2025-04-14 18:56:54 +02:00
Norbert Rittel
49a9923b5c Use common state for "Auto" in humidifier (#142937) 2025-04-14 17:50:20 +01:00
Norbert Rittel
23844c0f1a Use common state for "Auto", fix sentence-casing in demo (#142934) 2025-04-14 17:41:20 +01:00
cdnninja
82efa0893f Vesync Display Switch Feature (#137493)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-14 17:26:21 +02:00
Simone Chemelli
9e93d1fd7e Introduce common base entity for Comelit bridge (#142855) 2025-04-14 17:17:06 +02:00
Norbert Rittel
0a424f53b1 Add common states for "Auto" and "Manual" (#142914) 2025-04-14 16:52:31 +03:00
Hervé Cauwelier
efc44d83bb Add wind gust attribute to Météo France weather entity (#136839) 2025-04-14 15:41:10 +02:00
Petro31
9b274a0bc4 Correct template fan optimistic mode and supported features (#142414) 2025-04-14 15:40:29 +02:00
Barry vd. Heuvel
aeca2842fe Add WeHeat Flow sensors for pumps (#139390)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-14 15:39:44 +02:00
Emily Love Watson
d44d07ffcf Kulersky refactor to new Bluetooth subsystem (#142309)
Co-authored-by: J. Nick Koston <nick@koston.org>
2025-04-14 15:38:34 +02:00
Lachlan Banks
bc683ce6ee Bump qbittorrent-api to 2024.9.67 (#142588) 2025-04-14 15:37:57 +02:00
Paulus Schoutsen
c6abe1d1bb Remove the word "node" from ESPHome texts (#142929) 2025-04-14 15:28:02 +02:00
karwosts
6a95abb831 Add effects translation/icon for Demo light (#142862) 2025-04-14 15:14:00 +02:00
hahn-th
6d74a6aa19 Refactor homematicip_cloud connection (#139081) 2025-04-14 15:01:55 +02:00
Joost Lekkerkerker
83c3275054 Remove deprecated state attributes in seventeentrack (#142622) 2025-04-14 14:40:08 +02:00
Joost Lekkerkerker
b3eb0301ae Remove YAML import in Point (#142627) 2025-04-14 14:37:45 +02:00
Joost Lekkerkerker
f00dfd32d4 Remove config import in EmonCMS (#142624) 2025-04-14 14:30:41 +02:00
Paul Bottein
8ec436423f Add template function: device_name (#142683) 2025-04-14 14:30:00 +02:00
Marc Mueller
5f2ae37ee5 Improve backup tests (#142785) 2025-04-14 14:26:29 +02:00
J. Nick Koston
514363f1c5 Use configured names in HomeKit for child accessories (#142531) 2025-04-14 14:24:43 +02:00
cdnninja
f84f6aa713 Fix vesync purifier 131 tests (#142860) 2025-04-14 13:58:54 +02:00
Thomas55555
b5f15b6d67 Bump aioautomower to 2025.4.0 (#142609) 2025-04-14 13:51:55 +02:00
Stefano Angeleri
c8972a2234 Fix powerwall display of actual remaining battery, instead of reserved capacity (#142391) 2025-04-14 12:59:28 +02:00
J. Nick Koston
1892c8fa62 Bump habluetooth to 3.38.1 (#142915) 2025-04-14 00:40:55 -10:00
Norbert Rittel
589633bc23 Fix spelling of "off-peak" in huisbaasje (#142810) 2025-04-14 12:38:26 +02:00
Mathijs van de Nes
458162c3f5 Fix typo in util.ssl test (#142799) 2025-04-14 12:31:44 +02:00
Joost Lekkerkerker
583eb1a80e Remove state attributes in Totalconnect (#142625) 2025-04-14 12:24:32 +02:00
Tsvi Mostovicz
1480b77461 Don't do I/O while getting Jewish calendar data schema (#142919) 2025-04-14 12:15:46 +02:00
J. Nick Koston
908a7c6991 Fix flakey bluetooth options flow tests (#142920) 2025-04-14 12:07:47 +02:00
J. Nick Koston
53b991fb54 Add preset modes to HKC fans (#142528) 2025-04-14 11:40:54 +02:00
Norbert Rittel
35187a4b52 Fix typo "Could not login …" and add common state in xiaomi_miio (#142648) 2025-04-14 11:39:19 +02:00
J. Nick Koston
621326f4e4 Small cleanups to the inkbird coordinator (#142911) 2025-04-13 23:27:46 -10:00
J. Nick Koston
a6643d8fb3 Add support for InkBird IAM-T1 (#142824) 2025-04-13 22:31:38 -10:00
Petar Petrov
9239ace1c8 Config flow progress in percent (#142737)
* Config flow progress in percent

* PR comments
2025-04-14 10:24:01 +02:00
Simone Chemelli
422bcecec1 Add quality scale to Comelit (#139743)
* Add quality scale to Comelit

* tweek

* updates

* update

* update manifest

* tweak

* update after latest merges

* update quality scale

* tweak

* apply review comments

* apply review comment

* one more review comment
2025-04-14 10:18:33 +02:00
J. Nick Koston
6f02550ac3 Include HKC BLE MAC in device info when available (#141900)
* Include HKC BLE MAC in device info when available

* update tests

* cover

* dry

* dry

* dry
2025-04-14 10:14:48 +02:00
J. Nick Koston
1aa996d5f0 Add debug logging to homekit when an sensor entity cannot be classified (#142707)
* Add debug logging to homekit when an sensor entity cannot be classified

In #132937 many hours were spent investigating an issue which
turned out to be that the entity did not have a device class
at startup because the group integration does not set the device
class if any of the underlying entities state is invalid.

closes #132937

* coverage

* Update tests/components/homekit/test_get_accessories.py
2025-04-14 10:12:27 +02:00
J. Nick Koston
a340646e1e Avoid starting ESPHome reauth when an unexpected device is found at the last address (#142814)
* Bump aioesphomeapi to 29.10.0

changelog: https://github.com/esphome/aioesphomeapi/compare/v29.9.0...v29.10.0

* Avoid starting ESPHome reauth when an unexpected device is found at the last address

fixes #133956

* coverage
2025-04-14 10:10:07 +02:00
Allen Porter
db043b26da Fix quality loss for LLM conversation agent question answering (#142873)
* Fix a bug parsing a streaming response with no json

* Remove debug lines

* Fix  quality loss for LLM conversation agent question answering

* Update tests
2025-04-14 10:05:34 +02:00
J. Nick Koston
8767599ad4 Validate ESPHome mac address before updating IP on discovery (#142878)
* Bump aioesphomeapi to 29.10.0

changelog: https://github.com/esphome/aioesphomeapi/compare/v29.9.0...v29.10.0

* Validate ESPHome mac address before updating IP on discovery

In some cases the data coming in from discovery may be
stale since there is a small race window if devices
get new IP allocations. Since some routers do not update
their names right away and zeroconf has a non-zero TTL
there is a small window where the discovery data can be
stale. This is a rare condition but it does happen. With
aioesphomeapi 29.10.0+ and ESPHome 2025.4.x+ we can validate
the mac address even without the correct encryption key
which allows us to be able to always validate the MAC
before updating the IP from any discovery method.

* tweaks

* fix test
2025-04-14 10:02:46 +02:00
Joost Lekkerkerker
6d5c000e1f Set entity categories for some entities in Syncthru (#142828)
Set entity categories for some entities
2025-04-14 09:51:41 +02:00
Simone Chemelli
2750535928 Use runtime_data in UptimeRobot (#142848)
* Use runtime_data in UptimeRobot

* fix unload
2025-04-14 09:51:06 +02:00
Simone Chemelli
1e31e2944b Add parallel updates to UptimeRobot (#142849) 2025-04-14 09:50:29 +02:00
J. Nick Koston
8bcc4f4c82 Avoid setting up ESPHome dashboard if its been uninstalled (#142904)
* Avoid setting up ESPHome dashboard if its been uninstalled

* tweaks

* coverage

* coverage

* fix
2025-04-14 09:49:21 +02:00
Norbert Rittel
bfc3080292 Use common states for "Low" / "Medium" / "High" in climate (#142842) 2025-04-14 09:42:05 +02:00
Mick Vleeshouwer
9bff86e7aa Bump pyOverkiz to 1.17.0 (#142854)
Bump pyoverkiz to 1.17.0
2025-04-14 09:41:07 +02:00
Retha Runolfsson
0689a6ed62 Bump PySwitchBot to 0.60.0 (#142905)
update pyswitchbot ver
2025-04-14 09:40:14 +02:00
starkillerOG
61f2251336 Fix Reolink Home Hub Pro playback (#142871)
Fix Home Hub Pro playback
2025-04-14 09:39:41 +02:00
Kevin Stillhammer
62a0932deb Only get tracked pairs for kraken (#142877)
Only get tracked pairs

Getting all available pairs leads to a too long request URL
2025-04-14 09:39:01 +02:00
J. Nick Koston
3389ee4b80 Bump inkbird-ble to 0.13.0 (#142885)
* Bump inkbird-ble to 0.12.0

changelog: https://github.com/Bluetooth-Devices/inkbird-ble/compare/v0.11.0...v0.12.0

* map discovery as well

* fix merge

* fix merge error

* bump again for more cleanups

* fix tests
2025-04-14 09:37:42 +02:00
Åke Strandberg
cc6e2ef3f7 Spelling corrections in miele integration (#142907)
Spelling corrections
2025-04-14 09:36:02 +02:00
Glenn Waters
1a1c95af12 Bump Environment Canada library to 0.10.1 (#142882) 2025-04-13 18:39:50 -10:00
Allen Porter
658299ee21 Strip whitespace from new todo list item names (#142889)
Strip whitspace from new todo list item names
2025-04-13 17:42:42 -07:00
Allen Porter
5b8ca8d0ed Improve local calendar error logging when uploading invalid .ics files (#142891) 2025-04-13 17:42:24 -07:00
Allen Porter
d91528648f Update ollama to allow selecting mutiple LLM APIs (#142445)
* Update ollama to allow selecting mutiple LLM APIs

* Update homeassistant/helpers/llm.py

* Avoid gather since these don't do I/O

---------

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2025-04-13 15:37:46 -07:00
J. Nick Koston
8b88272bc0 Add async_set_updated_data method to PassiveBluetoothProcessorCoordinator (#142879) 2025-04-13 11:08:22 -10:00
zry98
8ab59bee47 [xiaomi_ble] Support Body Composition Scale S400 (#142705) 2025-04-13 10:41:43 -10:00
J. Nick Koston
18c814d3dc Bump inkbird-ble to 0.11.0 (#142832) 2025-04-13 10:08:28 -10:00
Jan Bouwhuis
4f0928d93b Use existing translations for mqtt subentry platform selector (#142876) 2025-04-13 22:08:19 +02:00
J. Nick Koston
6c7865a247 Bump aioesphomeapi to 29.10.0 (#142813) 2025-04-13 10:08:01 -10:00
Jan Bouwhuis
7cf63d1985 Add transition and flash feature flags for MQTT JSON light (#142692) 2025-04-13 21:39:40 +02:00
Åke Strandberg
0b02b43b11 Add integration for Miele (#142498) 2025-04-13 21:09:41 +02:00
Simone Chemelli
b25a0e2272 Small cleanup for Vodafone Station (#142867) 2025-04-13 18:57:00 +02:00
Thomas55555
6d78c961d9 Bump colorlog to 6.9.0 (#142616) 2025-04-13 16:10:52 +02:00
Simone Chemelli
e370248c9e Use typed ConfigEntry in UptimeRobot (#142846) 2025-04-13 15:30:47 +02:00
Brett Adams
31c2d22912 Check Energy Live API works before creating the coordinator in Tessie (#142510)
* Check live API works before creating the coordinator

* Fix diag

* Fix mypy on entity

* is not None
2025-04-13 13:55:16 +02:00
Norbert Rittel
5eb25b2d4a Use common states for "Low"/"Medium"/"High" in sensibo (#142118) 2025-04-13 12:40:53 +02:00
Chase Mamatey
6737c51fca Fix duke_energy data retrieval to adhere to service start date (#136054) 2025-04-12 19:00:49 -04:00
Marc Mueller
d23c9f715e Update beautifulsoup4 to 4.13.3 (#142751) 2025-04-12 12:04:50 -10:00
Marc Mueller
03ccb529e4 Update pillow to 11.2.1 (#142811) 2025-04-12 12:03:28 -10:00
zry98
505e09242d Bump xiaomi-ble to 0.37.0 (#142812) 2025-04-12 12:03:01 -10:00
Mathijs van de Nes
d6b4f1c95d Ensure no ALPN is negotiated for SMTP (#142296) 2025-04-12 12:02:07 -10:00
Norbert Rittel
67c0af4c57 Fix spelling of "off-peak", add common state for "Normal" in plugwise (#142682) 2025-04-12 21:04:05 +02:00
Joost Lekkerkerker
cba0cf0609 Migrate Syncthru to runtime data (#142775) 2025-04-12 20:59:59 +02:00
Joost Lekkerkerker
b957017799 Clean up Syncthru unique id (#142778) 2025-04-12 20:50:37 +02:00
Joost Lekkerkerker
ebe71a1a38 Add diagnostics support to Syncthru (#142776) 2025-04-12 20:22:12 +02:00
Joost Lekkerkerker
6feb9d4b4e Add entity translations to Syncthru (#142774)
* Add entity translations to Syncthru

* Add entity translations to Syncthru

* Fix
2025-04-12 20:19:49 +02:00
Ernst Klamer
06d6155862 add support for quadruple button events for xiaomi-ble (#142760)
* bump xiaomi-ble to 0.36.0

* fix ruff

* fix ruff

* revert dependency bump
2025-04-12 20:18:26 +02:00
J. Nick Koston
f13bdd0da4 Add support for passing though description_placeholders to _abort_if_unique_id_configured (#142779) 2025-04-12 07:47:02 -10:00
Dionisis Toulatos
3489ea30dd Fix MQTT device discovery when using node_id (#142784)
* Fix device discovery when using node_id

* tests

---------

Co-authored-by: jbouwh <jan@jbsoft.nl>
Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
2025-04-12 19:30:06 +02:00
Marc Mueller
d218ac85f7 Update pytest warnings filter (#142797) 2025-04-12 19:15:38 +02:00
peteS-UK
5129c7521b Force Squeezebox item id to string (#142793)
force item_id to string
2025-04-12 17:09:17 +02:00
J. Diego Rodríguez Royo
eb19c7af32 Disable Home Connect appliance refresh when frequent disconnects are detected (#142615)
* Disable specific updates for an appliance when is done repeatedly

* Fix deprecation issues fix tests

* Fix message

* Avoid fetching appliance info also

* Apply suggestions

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

* Create specific RepairFlow for enabling appliance's updates

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-12 14:58:35 +02:00
J. Nick Koston
6b65b21ee0 Migrate inkbird to use entry.runtime_data (#142780) 2025-04-12 12:20:07 +02:00
Franck Nijhof
f7794ea6b5 2025.4.2 (#142755) 2025-04-12 11:43:50 +02:00
Erik Montnemery
4eda081574 Remove unnecessary error handling from backup onboarding (#142786) 2025-04-12 11:01:41 +02:00
Erik Montnemery
234c4c1958 Move backup backup onboarding API to an onboarding platform (#142713)
* Move backup backup onboarding API to an onboarding platform

* Move additional test from onboarding to backup

* Remove backup tests from onboarding
2025-04-12 09:41:54 +02:00
Marc Mueller
ad3c4d24b8 Update h2 to 4.2.0 (#142777) 2025-04-11 14:08:09 -10:00
J. Nick Koston
ee37b32ca1 Log lutron_caseta exception on pairing failure (#140776) 2025-04-11 13:57:47 -10:00
Ernst Klamer
49721a541a bump xiaomi-ble to 0.36.0 (#142761) 2025-04-12 01:16:14 +03:00
Robert Svensson
c18d96e2f5 UniFi redact WLAN password (#142767)
* Recact password key word in WLAN diagnostic data

* Fix testdata
2025-04-12 01:15:15 +03:00
Joost Lekkerkerker
3efb009e82 Introduce base entity in Syncthru (#142694) 2025-04-12 00:12:23 +02:00
Sanjay Govind
7a1bea7ff5 Add jaraco.itertools license exception as the classifier was removed but no SPDX expression was added (#142439) 2025-04-11 21:35:35 +00:00
Thomas55555
c7c645776d Bump ical to 9.1.0 (#142197) 2025-04-11 21:35:28 +00:00
Mathijs van de Nes
b20f46e8b9 Add non-shared ssl client_context (#142653) 2025-04-11 10:55:05 -10:00
Marc Mueller
4f0ece1bb4 Update uiprotect to 7.5.3 (#142766) 2025-04-11 22:37:15 +02:00
J. Nick Koston
2c316c5820 Ensure person loads after recorder (#142585)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2025-04-11 09:39:30 -10:00
Marc Mueller
9d10d8f55e Fix slack DeprecationWarnings (#142754) 2025-04-11 20:27:45 +02:00
Abílio Costa
0fcac987df Update strings for Whirlpool config flows (#142758) 2025-04-11 20:21:53 +02:00
Joost Lekkerkerker
ffcc2254ce Refactor Syncthru binary sensor (#142696) 2025-04-11 19:40:37 +02:00
Manu
b01eac3ba5 Fix error in recurrence calculation of Habitica integration (#142759)
Fix error in rrule calculation of Habitica integration
2025-04-11 19:39:40 +02:00
Simone Chemelli
a3341c4330 Add full test coverage for Comelit humidifier platform (#141852)
* Add full test coverage for Comelit humidifier platform

* clean

* update snapshot

* apply review comment
2025-04-11 18:23:03 +02:00
Franck Nijhof
667cb772e9 Bump version to 2025.4.2 2025-04-11 16:12:45 +00:00
Jeff Rescignano
933d008e52 Upgrade sharkiq depedency to 1.1.0 (#142746) 2025-04-11 16:12:06 +00:00
Jeff Rescignano
a4fac730d4 Upgrade sharkiq depedency to 1.1.0 (#142746) 2025-04-11 18:07:27 +02:00
Allen Porter
d868f39aea Fix Anthropic bug parsing a streaming response with no json (#142745) 2025-04-11 15:42:08 +00:00
Joost Lekkerkerker
28d776a0b0 Fix SmartThings gas meter (#142741) 2025-04-11 15:42:04 +00:00
Joost Lekkerkerker
b5d541b596 Bump pySmartThings to 3.0.4 (#142739) 2025-04-11 15:41:59 +00:00
Bram Kragten
4948499889 Update frontend to 20250411.0 (#142736) 2025-04-11 15:41:55 +00:00
starkillerOG
7696b101f6 Reolink migrate unique ID debugging (#142723)
* Filter out unexpected unique_ids

* correct

* Add test

* fix styling
2025-04-11 15:41:51 +00:00
starkillerOG
fd2987a9fd Bump reolink-aio 0.13.1 (#142719) 2025-04-11 15:41:47 +00:00
Christopher Fenner
4c1d32020a Bump PyViCare to 2.44.0 (#142701)
bump vicare to v2.44.0
2025-04-11 15:41:42 +00:00
Jan Bouwhuis
b40bdab0ae Fix EC certificate key not allowed in MQTT client setup (#142698) 2025-04-11 15:41:38 +00:00
Simone Chemelli
d192aecd3b Comelit config flow timeout error (#142667) 2025-04-11 15:41:34 +00:00
Thomas55555
d1781f5766 Bump livisi to 0.0.25 (#142638) 2025-04-11 15:41:29 +00:00
henryptung
2c4461457a Bump led_ble to 1.1.7 (#142629)
changelog: https://github.com/Bluetooth-Devices/led-ble/compare/v1.1.6...v1.1.7
2025-04-11 15:40:35 +00:00
J. Nick Koston
82959081de Pin multidict to >= 6.4.2 to resolve memory leaks (#142614)
* Pin multidict to >= 6.4.1 to resolve memory leaks

https://github.com/aio-libs/multidict/issues/1134
https://github.com/aio-libs/multidict/issues/1131
https://github.com/aio-libs/multidict/releases/tag/v6.4.1
https://github.com/aio-libs/multidict/releases/tag/v6.4.0

* Apply suggestions from code review
2025-04-11 15:39:38 +00:00
Thimo Seitz
acdac6d5e8 Update growatt server dependency to 1.6.0 (#142606)
* Update GrowattServer Dependency

* Update requirements_test_all.txt
2025-04-11 15:39:34 +00:00
Fredrik Erlandsson
d3d7889883 Fix ssl_cert load from config_flow (#142570)
fix ssl_cert load from config_flow
2025-04-11 15:39:29 +00:00
puddly
60ece3e1c9 Fix Core deadlock by ensuring only one ZHA log queue handler thread is running at a time (#142568)
Ensure only one log queue handler is running at a time
2025-04-11 15:39:25 +00:00
Christopher Fenner
a9f8529460 Fix Quickmode handling in ViCare integration (#142561)
* only check quickmode if supported

* update snapshot

* revert
2025-04-11 15:39:20 +00:00
Andrew Sayre
ec53b61f9e Bump pyheos to v1.0.5 (#142554)
Update pyheos
2025-04-11 15:39:16 +00:00
Thomas55555
e9f02edd8b Fix adding devices in Husqvarna Automower (#142549) 2025-04-11 15:39:12 +00:00
Marcel van der Veldt
d1b7898219 Fix small typo in Music Assistant integration causing unavailable players (#142535)
Fix small typo in Music Assistant integration causing issues with adding players
2025-04-11 15:39:08 +00:00
Jan Bouwhuis
8dc21ef619 Allow max to be equal with min for mqtt number config validation (#142522) 2025-04-11 15:39:03 +00:00
tronikos
d9f91598a5 Fix range of Google Generative AI temperature (#142513) 2025-04-11 15:34:29 +00:00
Ivan Lopez Hernandez
c540acf2bd Handle None on the response candidates in Google Generative AI (#142497)
* Added type checking on the candidates list

* Made error message a constant
2025-04-11 15:34:24 +00:00
Maciej Bieniek
f702f3efcd Fix Shelly initialization if device runs large script (#142487)
* Don't check the whole script to see if it generates events

* Fix tests

---------

Co-authored-by: Shay Levy <levyshay1@gmail.com>
2025-04-11 15:34:20 +00:00
Wilfred Ketelaar
9410061405 Fixed Renault charge state icon (#142478)
Fixed charge state icon (duplicate mdi prefix)
2025-04-11 15:34:15 +00:00
Maciej Bieniek
485b28d9ea Bump aioshelly to version 13.4.1 (#142477)
* Bymp aioshelly to 13.4.1

* Catch InvalidHostError

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2025-04-11 15:34:10 +00:00
epenet
d59200a9f5 Fix kelvin parameter in light action specifications (#142456) 2025-04-11 15:34:05 +00:00
starkillerOG
44a92ca81c Fix Reolink smart AI sensors (#142454) 2025-04-11 15:34:01 +00:00
J. Nick Koston
d39fa39a03 Fix HKC showing hvac_action as idle when fan is active and heat cool target is off (#142443)
* Fix HKC showing hvac_action as idle when fan is active and heat cool target is off

fixes #142442

* comment relocation
2025-04-11 15:33:56 +00:00
Michael
36ec857523 Fix reload of AVM FRITZ!Tools when new connected device is detected (#142430) 2025-04-11 15:33:51 +00:00
Simone Chemelli
fcb8cdc146 Add missing strings to Fritz (#142413)
* Add missing strings to Fritz

* update quality scale

* add common section

this avoids later re-structuring and re-translating

* fix strings

* fix strings

* apply review comment

---------

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
2025-04-11 15:33:46 +00:00
Simone Chemelli
2322b0b65f Add exceptions translation to SamsungTV (#142406)
* Add exceptions translation to SmasungTV

* Update strings.json

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

---------

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2025-04-11 15:33:42 +00:00
tronikos
87baaf4255 Bump opower to 0.11.1 (#142395)
* Bump opower to 0.10.1

* opower==0.11.0

* opower==0.11.1

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2025-04-11 15:33:37 +00:00
J. Nick Koston
b7f0e877f0 Bump aioesphomeapi to 29.9.0 (#142393)
changelog: https://github.com/esphome/aioesphomeapi/compare/v29.8.0...v29.9.0

fixes #142381
2025-04-11 15:33:33 +00:00
Jan-Philipp Benecke
5d92a04732 Only load files ending .metadata.json in WebDAV (#142388) 2025-04-11 15:33:29 +00:00
Álvaro Fernández Rojas
8ff879df22 Update aioairzone to v1.0.0 (#142385)
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2025-04-11 15:33:24 +00:00
J. Nick Koston
9fb7ee676e Bump flux_led to 1.2.0 (#142362)
changelog: https://github.com/lightinglibs/flux_led/compare/1.1.3...1.2.0
2025-04-11 15:33:20 +00:00
Jan Bouwhuis
2c855a3986 Limit mqtt info logging for discovery of new components (#142344)
* Limit mqtt info logging for discovery of new component

* Keep in bail out, when debug logging is not enabled
2025-04-11 15:33:14 +00:00
Luke Lashley
cdd4894e30 Check that the current roboorck map exists before updating it. (#142341)
* Check that the current map exists

* Add a few extra checks

* Update coordinator.py

Co-authored-by: Allen Porter <allen.porter@gmail.com>

* fixlint

---------

Co-authored-by: Allen Porter <allen.porter@gmail.com>
2025-04-11 15:33:09 +00:00
tronikos
5f26226712 Add a description for the enable_google_search_tool option in Google AI (#142322)
* Add a description for the enable_google_search_tool option in Google AI

* Use quotes
2025-04-11 15:33:05 +00:00
tronikos
8baf61031d Bump opower to 0.10.0 (#142321) 2025-04-11 15:33:00 +00:00
Andre Lengwenus
e90ba40553 Add SensorDeviceClass and unit for LCN CO2 sensor. (#142320)
Add SesnorDeviceClass and unit for LCN CO2 sensor.
2025-04-11 15:32:54 +00:00
Luke Lashley
b38016425f Update Roborock map more consistently on state change (#142228)
* update map more consistently on state change

* Makecoordinator keep track of last_updated_state
2025-04-11 15:32:49 +00:00
Thomas55555
ee5e3f7691 Add error details in remote calendar flow (#141753)
* Add error details in remote calendar flow

* no args

* adjust

* json

* Apply suggestions

* remove description placeholder
2025-04-11 15:32:41 +00:00
Allen Porter
ca07975ead Fix Anthropic bug parsing a streaming response with no json (#142745) 2025-04-11 17:30:12 +02:00
Michael
5a1a41beb1 Fix reload of AVM FRITZ!Tools when new connected device is detected (#142430) 2025-04-11 17:26:58 +02:00
Bram Kragten
20a3a061a1 Update frontend to 20250411.0 (#142736) 2025-04-11 17:25:26 +02:00
Joost Lekkerkerker
7b78f6db17 Fix SmartThings gas meter (#142741) 2025-04-11 17:24:39 +02:00
Simone Chemelli
5816a24577 Cleanup snapshot call in tests (#142750) 2025-04-11 17:21:12 +02:00
Joost Lekkerkerker
0e4f44b775 Bump pySmartThings to 3.0.4 (#142739) 2025-04-11 16:51:32 +02:00
Erik Montnemery
0105332476 Add WS command integration/wait (#142040)
* Add WS command integration/wait

* Add test

* Update homeassistant/components/websocket_api/commands.py

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

* Use helper setup.async_wait_component

* Add onboarding view

* Revert "Add onboarding view"

This reverts commit df3a1a0580.

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-11 16:09:15 +02:00
Erik Montnemery
4aca9cd66b Move cloud onboarding API to an onboarding platform (#141978)
* Move cloud onboarding API to an onboarding platform

* Address review comments

* Add tests

* Move cloud onboarding tests to the cloud integration

* Address review comments

* Don't wait for platforms

* Add test

* Remove useless check for CLOUD_DATA
2025-04-11 16:02:27 +02:00
Norbert Rittel
a4234bf80e Add more state references to shelly (#142716)
- replace "Normal" with common state
- replace `self_test` state attributes with references
2025-04-11 16:39:44 +03:00
Norbert Rittel
f42f698dbc Fix missing sentence-casing in a few plex strings (#142720) 2025-04-11 16:38:07 +03:00
Martin Hjelmare
cd45c5d886 Avoid Z-Wave config entry unload in test teardown (#142732) 2025-04-11 16:37:47 +03:00
Simone Chemelli
2af6ee7584 Add missing typed to SamsungTV (#142738) 2025-04-11 15:19:21 +02:00
Erik Montnemery
3b437c9b84 Add onboarding view /api/onboarding/integration/wait (#142688) 2025-04-11 13:43:18 +02:00
Martin Hjelmare
af8ecdd48d Improve Z-Wave reconfigure flow (#142475) 2025-04-11 12:15:11 +02:00
starkillerOG
16d9ccd423 Reolink migrate unique ID debugging (#142723)
* Filter out unexpected unique_ids

* correct

* Add test

* fix styling
2025-04-11 11:42:18 +02:00
Simone Chemelli
e1d223f726 Add exceptions translation to SamsungTV (#142406)
* Add exceptions translation to SmasungTV

* Update strings.json

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

---------

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2025-04-11 11:32:19 +02:00
Stefan Agner
a4904a3f2d Bump aiohasupervisor from version 0.3.0 to version 0.3.1b1 (#142721) 2025-04-11 10:14:07 +01:00
Christopher Fenner
dff7b30405 Bump PyViCare to 2.44.0 (#142701)
bump vicare to v2.44.0
2025-04-11 10:32:54 +02:00
starkillerOG
a06cd770a4 Bump reolink-aio 0.13.1 (#142719) 2025-04-11 10:22:30 +02:00
Joost Lekkerkerker
56c4121eb2 Refactor Syncthru sensor platform (#142704) 2025-04-11 08:12:59 +02:00
Christopher Fenner
f519b20495 Add device error sensor to ViCare integration (#142605)
* add error sensor

* remove translation
2025-04-11 08:11:53 +02:00
Jan Bouwhuis
32da8c52f7 Add test to assert different private key types are accepted and stored correctly in MQTT config flow (#142703) 2025-04-11 00:58:48 +02:00
Hugo van Rijswijk
c6994731b1 Add Buienradar apparent temperature and forecast rain chance & wind gust (#135287)
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2025-04-11 00:24:59 +02:00
Renier Moorcroft
2eb1041f4b Use sub stream as default option for EZVIZ (#136023) 2025-04-11 00:07:03 +02:00
Jan Bouwhuis
4ad5eb5a82 Fix EC certificate key not allowed in MQTT client setup (#142698) 2025-04-10 23:11:35 +02:00
Jan Bouwhuis
ea38639395 Validate MQTT device tracker location data before assigning (#141980)
* Validate MQTT device tracker location data before assigning

* Log warning for invalid gps_accuracy
2025-04-10 22:32:17 +02:00
Joost Lekkerkerker
bf0d2e9bd2 Extract Syncthru coordinator in separate file (#142620) 2025-04-10 21:24:38 +02:00
Simone Chemelli
bb3c2175bc Comelit config flow timeout error (#142667) 2025-04-10 21:16:53 +02:00
Joost Lekkerkerker
6fafafbed0 Improve Syncthru config flow tests (#142618) 2025-04-10 21:16:12 +02:00
Norbert Rittel
8f73c53d26 Replace "Setup your …" with correct "Set up your …" in iometer (#142685) 2025-04-10 21:12:39 +02:00
Erik Montnemery
5a09847596 Add backup support to the hassio OS update entity (#142580)
* Add backup support to the hassio OS update entity

* Remove meaningless assert
2025-04-10 20:56:02 +02:00
Erik Montnemery
cf63175232 Abort reauth flows on config entry reload (#140931)
* Abort reauth flows on config entry reload

* Don't cancel reauth when reload is triggered by a reauth flow

* Revert "Don't cancel reauth when reload is triggered by a reauth flow"

This reverts commit f37c75621e.

* Don't fail in FlowManager._async_handle_step when the flow was aborted

* Update tplink config flow

* Add tests

* Don't allow create_entry from an aborted flow

* Add comment

* Adjust after merge with dev
2025-04-10 20:55:34 +02:00
Thimo Seitz
88428fc772 Update growatt server dependency to 1.6.0 (#142606)
* Update GrowattServer Dependency

* Update requirements_test_all.txt
2025-04-10 20:14:30 +02:00
Jan Bouwhuis
505dfcbcd9 Use shorthand attributes for MQTT device tracker entity (#142671) 2025-04-10 19:51:36 +02:00
Erik Montnemery
7cbcb21e80 Revert "Don't create repairs asking user to remove duplicate flipr config entries" (#142647)
Revert "Don't create repairs asking user to remove duplicate flipr config ent…"

This reverts commit 536e686892.
2025-04-10 19:50:50 +02:00
Erik Montnemery
d4dbd76a0a Revert "Add onboarding view /api/onboarding/integration/wait" (#142680)
This reverts commit 956cac8f1a.
2025-04-10 19:15:54 +02:00
Norbert Rittel
1d9343df7f Fixes to user-facing strings of rfxtrx integration (#142677)
- consistently use "RFXtrx" for the friendly name of the integration
- apply sentence-casing to all strings
- use the common state for "Normal"
2025-04-10 18:00:37 +02:00
Norbert Rittel
c7ca88e666 Use common state for "Normal" in onedrive (#142673) 2025-04-10 17:47:02 +02:00
Artur Pragacz
efbb94a1b1 Use common helper function in resolve integration dependencies (#140989)
Extract to helper function in resolve integration dependencies
2025-04-10 17:41:06 +02:00
Franck Nijhof
7af6a4f493 2025.4.1 (#142299)
* Fix blocking event loop - daikin (#141442)

* fix blocking event loop

* create ssl_context directly

* update manifest

* update manifest.json

* Made Google Search enable dependent on Assist availability (#141712)

* Made Google Search enable dependent on Assist availability

* Show error instead of rendering again

* Cleanup test code

* Fix humidifier platform for Comelit (#141854)

* Fix humidifier platform for Comelit

* apply review comment

* Bump evohome-async to 1.0.5 (#141871)

bump client to 1.0.5

* Replace "to log into" with "to log in to" in `incomfort` (#142060)

* Replace "to log into" with "to log in to" in `incomfort`

Also fix one missing sentence-casing of "gateway".

* Replace duplicate "data_description" strings with references

* Avoid unnecessary reload in apple_tv reauth flow (#142079)

* Add translation for hassio update entity name (#142090)

* Bump pyenphase to 1.25.5 (#142107)

* Hide broken ZBT-1 config entries on the hardware page (#142110)

* Hide bad ZBT-1 config entries on the hardware page

* Set up the bad config entry in the unit test

* Roll into a list comprehension

* Remove constant changes

* Fix condition in unit test

* Bump pysmhi to 1.0.1 (#142111)

* Avoid logging a warning when replacing an ignored config entry (#142114)

Replacing an ignored config entry with one from the user
flow should not generate a warning. We should only warn
if we are replacing a usable config entry.

Followup to adjust the warning added in #130567
cc @epenet

* Slow down polling in Tesla Fleet (#142130)

* Slow down polling

* Fix tests

* Bump tesla-fleet-api to v1.0.17 (#142131)

bump

* Tado bump to 0.18.11 (#142175)

* Bump to version 0.18.11

* Adding hassfest files

* Add preset mode to SmartThings climate (#142180)

* Add preset mode to SmartThings climate

* Add preset mode to SmartThings climate

* Do not create a HA mediaplayer for the builtin Music Assistant player (#142192)

Do not create a HA mediaplayer for the builtin Music player

* Do not fetch disconnected Home Connect appliances (#142200)

* Do not fetch disconnected Home Connect appliances

* Apply suggestions

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

* Update docstring

---------

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

* Fix fibaro setup (#142201)

* Fix circular mean by always storing and using the weighted one (#142208)

* Fix circular mean by always storing and using the weighted one

* fix

* Fix test

* Bump pySmartThings to 3.0.2 (#142257)

Co-authored-by: Robert Resch <robert@resch.dev>

* Update frontend to 20250404.0 (#142274)

* Bump forecast-solar lib to v4.1.0 (#142280)

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

* Bump version to 2025.4.1

* Fix skyconnect tests (#142262)

fix tests

* Fix empty actions (#142292)

* Apply fix

* Add tests for alarm button cover lock

* update light

* add number tests

* test select

* add switch tests

* test vacuum

* update lock test

---------

Co-authored-by: Fredrik Erlandsson <fredrik.e@gmail.com>
Co-authored-by: Ivan Lopez Hernandez <ivan.lh.94@outlook.com>
Co-authored-by: Simone Chemelli <simone.chemelli@gmail.com>
Co-authored-by: David Bonnes <zxdavb@bonnes.me>
Co-authored-by: Norbert Rittel <norbert@rittel.de>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
Co-authored-by: Paul Bottein <paul.bottein@gmail.com>
Co-authored-by: Arie Catsman <120491684+catsmanac@users.noreply.github.com>
Co-authored-by: puddly <32534428+puddly@users.noreply.github.com>
Co-authored-by: G Johansson <goran.johansson@shiftit.se>
Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Brett Adams <Bre77@users.noreply.github.com>
Co-authored-by: Erwin Douna <e.douna@gmail.com>
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Co-authored-by: Marcel van der Veldt <m.vanderveldt@outlook.com>
Co-authored-by: J. Diego Rodríguez Royo <jdrr1998@hotmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: rappenze <rappenze@yahoo.com>
Co-authored-by: Robert Resch <robert@resch.dev>
Co-authored-by: Bram Kragten <mail@bramkragten.nl>
Co-authored-by: Klaas Schoute <klaas_schoute@hotmail.com>
Co-authored-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
Co-authored-by: Josef Zweck <josef@zweck.dev>
Co-authored-by: Petro31 <35082313+Petro31@users.noreply.github.com>
2025-04-04 22:59:10 +02:00
Petro31
c25f26a290 Fix empty actions (#142292)
* Apply fix

* Add tests for alarm button cover lock

* update light

* add number tests

* test select

* add switch tests

* test vacuum

* update lock test
2025-04-04 20:18:31 +00:00
Josef Zweck
8d62cb60a6 Fix skyconnect tests (#142262)
fix tests
2025-04-04 20:18:27 +00:00
Franck Nijhof
4f799069ea Bump version to 2025.4.1 2025-04-04 19:24:45 +00:00
Klaas Schoute
af708b78e0 Bump forecast-solar lib to v4.1.0 (#142280)
Co-authored-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
2025-04-04 19:24:30 +00:00
Bram Kragten
f46e659740 Update frontend to 20250404.0 (#142274) 2025-04-04 19:24:27 +00:00
Joost Lekkerkerker
7bd517e6ff Bump pySmartThings to 3.0.2 (#142257)
Co-authored-by: Robert Resch <robert@resch.dev>
2025-04-04 19:24:23 +00:00
Robert Resch
e9abdab1f5 Fix circular mean by always storing and using the weighted one (#142208)
* Fix circular mean by always storing and using the weighted one

* fix

* Fix test
2025-04-04 19:24:20 +00:00
rappenze
86eee4f041 Fix fibaro setup (#142201) 2025-04-04 19:24:17 +00:00
J. Diego Rodríguez Royo
9db60c830c Do not fetch disconnected Home Connect appliances (#142200)
* Do not fetch disconnected Home Connect appliances

* Apply suggestions

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

* Update docstring

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-04 19:24:13 +00:00
Marcel van der Veldt
c43a4682b9 Do not create a HA mediaplayer for the builtin Music Assistant player (#142192)
Do not create a HA mediaplayer for the builtin Music player
2025-04-04 19:24:10 +00:00
Joost Lekkerkerker
2a4996055a Add preset mode to SmartThings climate (#142180)
* Add preset mode to SmartThings climate

* Add preset mode to SmartThings climate
2025-04-04 19:24:07 +00:00
Erwin Douna
4643fc2c14 Tado bump to 0.18.11 (#142175)
* Bump to version 0.18.11

* Adding hassfest files
2025-04-04 19:24:04 +00:00
Brett Adams
6410b90d82 Bump tesla-fleet-api to v1.0.17 (#142131)
bump
2025-04-04 19:24:00 +00:00
Brett Adams
e5c00eceae Slow down polling in Tesla Fleet (#142130)
* Slow down polling

* Fix tests
2025-04-04 19:23:55 +00:00
J. Nick Koston
fe65579df8 Avoid logging a warning when replacing an ignored config entry (#142114)
Replacing an ignored config entry with one from the user
flow should not generate a warning. We should only warn
if we are replacing a usable config entry.

Followup to adjust the warning added in #130567
cc @epenet
2025-04-04 19:23:52 +00:00
G Johansson
281beecb05 Bump pysmhi to 1.0.1 (#142111) 2025-04-04 19:23:48 +00:00
puddly
7546b5d269 Hide broken ZBT-1 config entries on the hardware page (#142110)
* Hide bad ZBT-1 config entries on the hardware page

* Set up the bad config entry in the unit test

* Roll into a list comprehension

* Remove constant changes

* Fix condition in unit test
2025-04-04 19:23:45 +00:00
Arie Catsman
490e3201b9 Bump pyenphase to 1.25.5 (#142107) 2025-04-04 19:23:42 +00:00
Paul Bottein
04be575139 Add translation for hassio update entity name (#142090) 2025-04-04 19:23:39 +00:00
Erik Montnemery
854cae7f12 Avoid unnecessary reload in apple_tv reauth flow (#142079) 2025-04-04 19:23:35 +00:00
Norbert Rittel
109d20978f Replace "to log into" with "to log in to" in incomfort (#142060)
* Replace "to log into" with "to log in to" in `incomfort`

Also fix one missing sentence-casing of "gateway".

* Replace duplicate "data_description" strings with references
2025-04-04 19:23:32 +00:00
David Bonnes
f8d284ec4b Bump evohome-async to 1.0.5 (#141871)
bump client to 1.0.5
2025-04-04 19:23:28 +00:00
Simone Chemelli
06ebe0810f Fix humidifier platform for Comelit (#141854)
* Fix humidifier platform for Comelit

* apply review comment
2025-04-04 19:23:25 +00:00
Ivan Lopez Hernandez
802ad2ff51 Made Google Search enable dependent on Assist availability (#141712)
* Made Google Search enable dependent on Assist availability

* Show error instead of rendering again

* Cleanup test code
2025-04-04 19:23:22 +00:00
Fredrik Erlandsson
9070a8d579 Fix blocking event loop - daikin (#141442)
* fix blocking event loop

* create ssl_context directly

* update manifest

* update manifest.json
2025-04-04 19:23:18 +00:00
Franck Nijhof
e8b2a3de8b 2025.4.0 (#141505) 2025-04-02 18:47:40 +02:00
Joost Lekkerkerker
39549d5dd4 Fix switch name Unknown in SmartThings (#142081)
Fix switch name Unknown
2025-04-02 15:16:50 +00:00
Franck Nijhof
0c19e47bd4 Bump version to 2025.4.0 2025-04-02 15:02:28 +00:00
Michael
05507d77e3 Fix state class for battery sensors in AVM Fritz!SmartHome (#142078)
* set proper state class for battery sensor

* fix tests
2025-04-02 15:02:04 +00:00
Franck Nijhof
94558e2d40 Bump version to 2025.4.0b15 2025-04-02 14:19:49 +00:00
puddly
4f22fe8f7f Translation key for ZBT-1 integration failing due to disconnection (#142077)
Translation key for device disconnected
2025-04-02 14:19:41 +00:00
Marcel van der Veldt
9e7dfbb857 Deprecate None effect instead of breaking it for Hue (#142073)
* Deprecate effect none instead of breaking it for Hue

* add guard for unknown effect value

* revert guard

* Fix

* Add test

* Add test

* Add test

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-04-02 14:19:38 +00:00
Joost Lekkerkerker
02d182239a Improve SmartThings switch deprecation (#142072) 2025-04-02 14:19:35 +00:00
Joost Lekkerkerker
4e0f581747 Improve SmartThings sensor deprecation (#142070)
* Improve SmartThings sensor deprecation

* Improve SmartThings sensor deprecation

* Improve SmartThings sensor deprecation
2025-04-02 14:19:32 +00:00
Joost Lekkerkerker
42d97d348c Add Eve brand (#142067) 2025-04-02 14:19:29 +00:00
Robert Resch
69380c85ca Bump deebot-client to 12.5.0 (#142046) 2025-04-02 14:19:25 +00:00
Abílio Costa
b38c647830 Allow excluding modules from noisy logs check (#142020)
* Allow excluding modules from noisy logs check

* Cache non-excluded modules; hardcode self module name; optimize call

* Address review comments
2025-04-02 14:19:22 +00:00
Petro31
2396fd1090 Fix weather templates using new style configuration (#136677) 2025-04-02 14:19:19 +00:00
Franck Nijhof
aa4eb89eee Bump version to 2025.4.0b14 2025-04-02 09:44:23 +00:00
J. Nick Koston
1b1bc6af95 Bump bluetooth-data-tools to 1.26.5 (#142045)
changelog: https://github.com/Bluetooth-Devices/bluetooth-data-tools/compare/v1.26.1...v1.26.5
2025-04-02 09:36:51 +00:00
J. Nick Koston
f17003a79c Bump aiohttp to 3.11.16 (#142034)
changelog: https://github.com/aio-libs/aiohttp/compare/v3.11.15...v3.11.16
2025-04-02 09:34:14 +00:00
TheJulianJES
ec70e8b0cd Bump ZHA to 0.0.55 (#142031) 2025-04-02 08:29:26 +00:00
puddly
d888c70ff0 Fix entity names for HA hardware firmware update entities (#142029)
* Fix entity names for HA hardware firmware update entities

* Fix unit tests
2025-04-02 08:29:23 +00:00
puddly
f29444002e Skip firmware config flow confirmation if the hardware is in use (#142017)
* Auto-confirm the discovery if we detect that the device is already in use

* Add a unit test
2025-04-02 08:29:20 +00:00
Tomek Wasilczyk
fc66997a36 Fix warning about unfinished oauth tasks on shutdown (#141969)
* Don't wait for OAuth token task on shutdown

To reproduce the warning:
1. Start authentication with integration using OAuth (e.g. SmartThings)
2. When redirected to external login site, just close the page
3. Settings -> Restart Home Assistant

* Clarify comment

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-04-02 08:29:16 +00:00
Erik Montnemery
35513ae072 Remove unused mypy ignore from google_generative_ai_conversation (#141549) 2025-04-02 08:29:13 +00:00
Franck Nijhof
cd363d48c3 Bump version to 2025.4.0b13 2025-04-01 19:12:16 +00:00
G Johansson
d47ef835d7 Fix train to for multiple stations in Trafikverket Train (#142016) 2025-04-01 19:11:51 +00:00
Bram Kragten
00177c699e Update frontend to 20250401.0 (#142010) 2025-04-01 19:11:48 +00:00
Joost Lekkerkerker
11b0086a01 Add LG ThinQ event bus listener to lifecycle hooks (#142006) 2025-04-01 19:11:44 +00:00
J. Nick Koston
ceb177f80e Bump aiohttp to 3.11.15 (#141967)
changelog: https://github.com/aio-libs/aiohttp/compare/v3.11.14...v3.11.15

fixes #141855
fixes #141146
2025-04-01 19:10:28 +00:00
Jan Bouwhuis
fa3832fbd7 Improve error handling and logging on MQTT update entity state updates when template rederings fails (#141960) 2025-04-01 19:07:10 +00:00
puddly
2b9c903429 Fix data in old SkyConnect integration config entries or delete them (#141959)
* Delete old SkyConnect integration config entries

* Try migrating, if possible

* Do not delete config entries, log a failure
2025-04-01 19:07:07 +00:00
puddly
a7c43f9b49 Reload the ZBT-1 integration on USB state changes (#141287)
* Reload the config entry when the ZBT-1 is unplugged

* Register the USB event handler globally to react better to re-plugs

* Fix existing unit tests

* Add an empty `CONFIG_SCHEMA`

* Add a unit test

* Fix unit tests

* Fix unit tests for Linux

* Address most review comments

* Address remaining review comments
2025-04-01 19:07:03 +00:00
Joost Lekkerkerker
b428196149 Improve SmartThings deprecation (#141939)
* Improve SmartThings deprecation

* Improve SmartThings deprecation
2025-04-01 19:01:43 +00:00
Erik Montnemery
e23da1a90f Fix import issues related to onboarding views (#141919)
* Fix import issues related to onboarding views

* Add ha-intents and numpy to pyproject.toml

* Add more requirements to pyproject.toml

* Add more requirements to pyproject.toml
2025-04-01 19:00:24 +00:00
Ben Jones
3951c2ea66 Handle empty or missing state values for MQTT light entities using 'template' schema (#141177)
* check for empty or missing values when processing state messages for MQTT light entities using 'template' schema

* normalise warning logs

* add tests (one is still failing and I can't work out why)

* fix test

* improve test coverage after PR review

* improve test coverage after PR review
2025-04-01 18:32:50 +00:00
Louis Christ
fee152654d Use saved volume when selecting preset in bluesound integration (#141079)
* Use load_preset to select preset as source

* Add tests

* Fix

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-04-01 18:32:47 +00:00
Mikko Koo
51073c948c Fix nordpool Not to return Unknown if price is exactly 0 (#140647)
* now the price will return even if it is exactly 0

* now the price will return even if it is exactly 0

* now the price will return even if it is exactly 0

* clean code

* clean code

* update testing code coverage

* change zero testing to SE4

* remove row duplicate

* fix date comments

* improve testing

* simplify if-return-0

* remove unnecessary tests

* order testing rows

* restore test_sensor_no_next_price

* remove_average_price_test

* fix test name
2025-04-01 18:32:44 +00:00
aaronburt
91438088a0 Correct unit conversion for OneDrive quota display (#140337)
* Correct unit conversion for OneDrive quota display

* Convert OneDrive quota values from bytes to GiB in coordinator and update strings
2025-04-01 18:32:39 +00:00
Franck Nijhof
427e1abdae Bump version to 2025.4.0b12 2025-03-31 20:12:58 +00:00
Steven Looman
6e7ac45ac0 Bump async-upnp-client to 0.44.0 (#141946) 2025-03-31 20:12:48 +00:00
Bram Kragten
4b3b9ebc29 Update frontend to 20250331.0 (#141943) 2025-03-31 20:12:43 +00:00
Franck Nijhof
649d8638ed Bump version to 2025.4.0b11 2025-03-31 18:34:34 +00:00
Jan-Philipp Benecke
12c4152dbe Bump aiowebdav2 to 0.4.5 (#141934) 2025-03-31 18:34:25 +00:00
Michael Hansen
8f9572bb05 Add preannounce boolean for announce/start conversation (#141930)
* Add preannounce boolean

* Fix disabling preannounce in wizard

* Fix casing

* Fix type of preannounce_media_id

* Adjust description of preannounce_media_id
2025-03-31 18:34:22 +00:00
Erik Montnemery
6d022ff4e0 Revert PR 136314 (Cleanup map references in lovelace) (#141928)
* Revert PR 136314 (Cleanup map references in lovelace)

* Update homeassistant/components/lovelace/__init__.py

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

* Fix dashboard creation

* Update homeassistant/components/lovelace/__init__.py

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

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-03-31 18:34:19 +00:00
Josef Zweck
c0c2edb90a Add None check to azure_storage (#141922) 2025-03-31 18:34:16 +00:00
Michael
b014219fdd Correct further sensor categorizations in AVM Fritz!Box tools (#141911)
mark margin and attenuation as diagnostic and disable them by default
2025-03-31 18:34:13 +00:00
Joost Lekkerkerker
216b8ef400 Don't create SmartThings entities for disabled components (#141909) 2025-03-31 18:34:10 +00:00
Joost Lekkerkerker
f2ccd46267 Fix SmartThings being able to understand incomplete DRLC (#141907) 2025-03-31 18:34:06 +00:00
Dan Raper
e16ba27ce8 Bump ohmepy to 1.5.1 (#141879)
* Bump ohmepy to 1.5.1

* Fix types for ohmepy version change
2025-03-31 18:34:03 +00:00
Thomas55555
506526a6a2 Handle 403 error in remote calendar (#141839)
* Handle 403 error in remote calendar

* tests
2025-03-31 18:34:00 +00:00
Franck Nijhof
a88678cf42 Fix SmartThings climate entity missing off HAVC mode (#141700)
* Fix smartthing climate entity missing off HAVC mode:

* Fix tests

* Fix test

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-03-31 18:33:57 +00:00
Retha Runolfsson
d0b61af7ec Add switchbot cover unit tests (#140265)
* add cover unit tests

* Add unit test for SwitchBot cover

* fix: use mock_restore_cache to mock the last state

* modify unit tests

* modify scripts as suggest

* improve readability

* adjust patch target per review comments

* adjust patch target per review comments

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2025-03-31 18:33:53 +00:00
Franck Nijhof
04f5315ab2 Bump version to 2025.4.0b10 2025-03-31 08:09:39 +00:00
Paulus Schoutsen
7f9e4ba39e Ensure user always has first turn for Google Gen AI (#141893) 2025-03-31 08:09:10 +00:00
J. Nick Koston
06aaf188ea Fix duplicate call to async_write_ha_state when adding elkm1 entities (#141890)
When an entity is added state is always written in
add_to_platform_finish:

7336178e03/homeassistant/helpers/entity.py (L1384)

We should not do it in async_added_to_hass as well
2025-03-31 08:09:06 +00:00
J. Nick Koston
627f994872 Bump aioesphomeapi to 29.8.0 (#141888)
changelog: https://github.com/esphome/aioesphomeapi/compare/v29.7.0...v29.8.0
2025-03-31 08:09:03 +00:00
J. Nick Koston
9e81ec5aae Handle encryption being disabled on an ESPHome device (#141887)
fixes #121442
2025-03-31 08:09:00 +00:00
Franck Nijhof
69753fca1d Update pvo to v2.2.1 (#141847) 2025-03-31 08:08:57 +00:00
Michael
7773cc121e Fix the entity category for max throughput sensors in AVM Fritz!Box Tools (#141838)
correct the entity category for max throughput sensors
2025-03-31 08:08:54 +00:00
Michael
3aa56936ad Move setup messages from info to debug level (#141834)
move info to debug level
2025-03-31 08:08:51 +00:00
Franck Nijhof
e66416c23d Fix hardcoded UoM for total power sensor for Tuya zndb devices (#141822) 2025-03-31 08:08:48 +00:00
Jan Bouwhuis
a592feae3d Correct spelling for 'availability` in MQTT translation strings (#141818) 2025-03-31 08:08:45 +00:00
Aidan Timson
fc0d71e891 Fix System Bridge wait timeout wait condition (#141811)
* Fix System Bridge wait timeout wait condition

* Add DataMissingException as a timeout condition

* Add tests
2025-03-31 08:08:42 +00:00
Thomas55555
d4640f1d24 Bump ical to 9.0.3 (#141805) 2025-03-31 08:08:39 +00:00
Michael
6fe158836e Add boost preset to AVM Fritz!SmartHome climate entities (#141802)
* add boost preset to climate entities

* add set boost preset test
2025-03-31 08:08:36 +00:00
J. Nick Koston
629c0087f4 Bump PyISY to 3.1.15 (#141778)
changelog: https://github.com/automicus/PyISY/compare/v3.1.14...v3.1.15

fixes #141517
fixes #132279
2025-03-31 08:08:33 +00:00
J. Nick Koston
363bd75129 Fix blocking late import of httpcore from httpx (#141771)
There is a late import that blocks the event loop
in newer version
9e8ab40369/httpx/_transports/default.py (L75)
2025-03-31 08:08:30 +00:00
J. Nick Koston
7592d350a8 Bump aiohomekit to 3.2.13 (#141764)
changelog: https://github.com/Jc2k/aiohomekit/compare/3.2.8...3.2.13
2025-03-31 08:08:27 +00:00
puddly
8ac8401b4e Add helper methods to simplify USB integration testing (#141733)
* Add some helper methods to simplify USB integration testing

* Re-export `usb_device_from_port`
2025-03-31 08:08:24 +00:00
Joost Lekkerkerker
eed075dbfa Bump pySmartThings to 3.0.1 (#141722) 2025-03-31 08:08:21 +00:00
Florent Thoumie
23dbdedfb6 Bump iaqualink to 0.5.3 (#141709)
* Update to iaqualink 0.5.3 and silence warning

* Update to iaqualink 0.5.3 and silence warning

* Re-add via_device line
2025-03-31 08:08:18 +00:00
Franck Nijhof
85ad29e28e Ensure EcoNet operation modes are unique (#141689) 2025-03-31 08:08:15 +00:00
Michal Schwarz
35fc81b038 Fix order of palettes, presets and playlists in WLED integration (#132207)
* Fix order of palettes, presets and playlists in WLED integration

* fix tests: update palette items order

---------

Co-authored-by: Franck Nijhof <git@frenck.dev>
2025-03-31 08:08:11 +00:00
Lucas Mindêllo de Andrade
5d45b84cd2 Remove sunweg integration (#124230)
* chore(sunweg): remove sunweg integration

* Update homeassistant/components/sunweg/strings.json

Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>

* Update homeassistant/components/sunweg/manifest.json

Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>

* feat: added async remove entry

* Clean setup_entry; add tests

---------

Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
Co-authored-by: abmantis <amfcalt@gmail.com>
2025-03-31 08:06:54 +00:00
Franck Nijhof
7766649304 Bump version to 2025.4.0b9 2025-03-29 17:50:46 +00:00
Simone Chemelli
07e9020dfa Fix immediate state update for Comelit (#141735) 2025-03-29 17:50:36 +00:00
J. Diego Rodríguez Royo
f504a759e0 Set Home Connect program action field as not required (#141729)
* Set Home Connect program action field as not required

* Remove required field

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

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2025-03-29 17:50:32 +00:00
Joost Lekkerkerker
9927de4801 Only trigger events on button updates in SmartThings (#141720)
Only trigger events on button updates
2025-03-29 17:50:29 +00:00
Joost Lekkerkerker
1244fc4682 Only link the parent device if known in SmartThings (#141719)
Only link the parent device if we know the parent device
2025-03-29 17:50:26 +00:00
Norbert Rittel
e77a1b12f7 Sentence-case "Medium type" in mopeka (#141718) 2025-03-29 17:50:22 +00:00
J. Nick Koston
5459daaa10 Fix ESPHome entities not being removed when the ESPHome config removes an entire platform (#141708)
* Fix old ESPHome entities not being removed when configuration changes

fixes #140756

* make sure all callbacks fire

* make sure all callbacks fire

* make sure all callbacks fire

* make sure all callbacks fire

* revert

* cover
2025-03-29 17:50:18 +00:00
J. Nick Koston
400131df78 Fix ESPHome update entities being loaded before device_info is available (#141704)
* Fix ESPHome update entities being loaded before device_info is available

Since we load platforms when restoring config, the update
platform could be loaded before the connection to the
device was finished which meant device_info could still
be empty. Wait until device_info is available to
load the update platform.

fixes #135906

* Apply suggestions from code review

* move comment

* Update entry_data.py

Co-authored-by: TheJulianJES <TheJulianJES@users.noreply.github.com>

---------

Co-authored-by: TheJulianJES <TheJulianJES@users.noreply.github.com>
2025-03-29 17:50:15 +00:00
Franck Nijhof
28e1843ff9 Fix Tuya tdq category to pick up temp & humid (#141698) 2025-03-29 17:50:12 +00:00
Franck Nijhof
df777318d1 Handle invalid JSON errors in AirNow (#141695) 2025-03-29 17:50:08 +00:00
Jan Bouwhuis
6ad5e9e89c Improve MQTT translation strings (#141691)
* Improve MQTT options translation string

* more improvements
2025-03-29 17:50:05 +00:00
Norbert Rittel
a0bd8deee9 Replace "country" with common string in holiday (#141687) 2025-03-29 17:50:01 +00:00
Marcel van der Veldt
405cbd6a00 Always set pause feature on Music Assistant mediaplayers (#141686) 2025-03-29 17:49:58 +00:00
Marcel van der Veldt
3e0eb5ab2c Bump music assistant client to 1.2.0 (#141668)
* Bump music assistant client to 1.2.0

* Update test fixtures
2025-03-29 17:49:55 +00:00
Norbert Rittel
fad75a70b6 Add a common string for "country" (#141653) 2025-03-29 17:49:52 +00:00
Josef Zweck
d9720283df Add unkown to uncalibrated state for tedee (#141262) 2025-03-29 17:49:46 +00:00
Franck Nijhof
14eed1778b Bump version to 2025.4.0b8 2025-03-28 20:46:26 +00:00
Norbert Rittel
049aaa7e8b Fix grammar / sentence-casing in workday (#141682)
* Fix grammar / sentence-casing in `workday`

Also replace "country" with common string.

* Add two more references

* Fix second data description reference

* Add "given" to action description for better translations
2025-03-28 20:46:17 +00:00
J. Nick Koston
35717e8216 Increase websocket_api allowed peak time to 10s (#141680)
* Increase websocket_api allowed peak time to 10s

fixes #141624

During integration reload or startup, we can end up sending a message for
each entity being created for integrations that create them from an external
source (ie MQTT) because the messages come in one at a time. This can overload
the loop and/or client for more than 5s. While we have done significant work
to optimize for this path, we are at the limit at what we can expect clients
to be able to process in the time window, so increase the time window.

* adjust test
2025-03-28 20:46:13 +00:00
Franck Nijhof
2a081abc18 Fix camera proxy with sole image quality settings (#141676) 2025-03-28 20:46:10 +00:00
puddly
b7f29c7358 Handle all firmware types for ZBT-1 and Yellow update entities (#141674)
Handle other firmware types
2025-03-28 20:46:06 +00:00
Jason Hunter
3bb6373df5 Update Duke Energy package to fix integration (#141669)
* Update Duke Energy package to fix integration

* fix tests
2025-03-28 20:46:03 +00:00
Michael Hansen
e1b4edec50 Bump intents and always prefer more literal text (#141663) 2025-03-28 20:46:00 +00:00
puddly
147bee57e1 Include ZBT-1 and Yellow in device registry (#141623)
* Add the Yellow and ZBT-1 to the device registry

* Unload platforms

* Fix unit tests

* Rename the Yellow update entity to `Radio firmware`

* Rename `EmberZNet` to `EmberZNet Zigbee`

* Prefix the `sw_version` with the firmware type and clean up

* Fix unit tests

* Remove unnecessary `always_update=False` from data update coordinator
2025-03-28 20:45:56 +00:00
Erwin Douna
fcdaea64da Tado add proper off state (#135480)
* Add proper off state

* Remove current temp

* Add default frost temp
2025-03-28 20:45:53 +00:00
Franck Nijhof
d1512d46be Bump version to 2025.4.0b7 2025-03-28 16:00:45 +00:00
Bram Kragten
0be7db6270 Update frontend to 20250328.0 (#141659) 2025-03-28 15:09:56 +00:00
Paulus Schoutsen
2af0282725 Enable the message box on default for satelitte announcement actions (#141654) 2025-03-28 15:09:51 +00:00
Franck Nijhof
ff458c8417 Bump version to 2025.4.0b6 2025-03-28 15:04:34 +00:00
Franck Nijhof
cc93152ff0 Fix ESPHome event entity staying unavailable (#141650) 2025-03-28 14:05:40 +00:00
Paulus Schoutsen
9965f01609 Ensure connection test sound has no preannouncement (#141647) 2025-03-28 14:05:37 +00:00
Jan Bouwhuis
e9c76ce694 Fix duplicate 'device' term in MQTT translation strings (#141646)
* Fix duplicate 'device' from MQTT translation strings

* Update homeassistant/components/mqtt/strings.json
2025-03-28 14:05:34 +00:00
Norbert Rittel
58ab7d350d Fix sentence-casing in airvisual user strings (#141632) 2025-03-28 14:05:30 +00:00
Nick Pesce
e4d6e20ebd Use correct default value for multi press buttons in the Matter integration (#141630)
* Respect the min 2 constraint for the switch MultiPressMax attribute

* Update test_event.py

* Update generic_switch_multi.json

* Fix issue and update tests
2025-03-28 14:05:27 +00:00
Tsvi Mostovicz
45e273897a Jewish calendar match omer service variables requirement to documentation (#141620)
The documentation and the omer schema require a Nusach to be specified, but the YAML misses that requirement
2025-03-28 14:05:23 +00:00
Jan Bouwhuis
d9ec7142d7 Fix volatile_organic_compounds_parts translation string to be referenced for MQTT subentries device class selector (#141618)
* Fix ` volatile_organic_compounds_parts` translation string to be referenced for MQTT subentries device class selector

* Fix tests
2025-03-28 14:05:20 +00:00
Petro31
e162499267 Fix an issue with the switch preview in beta (#141617)
Fix an issue with the switch preview
2025-03-28 14:05:16 +00:00
Jan-Philipp Benecke
67f21429e3 Bump aiowebdav2 to 0.4.4 (#141615) 2025-03-28 14:05:12 +00:00
J. Nick Koston
a0563f06c9 Fix zeroconf logging level not being respected (#141601)
Removes an old logging workaround that is no longer needed

fixes #141558
2025-03-28 14:05:05 +00:00
Luke Lashley
e7c4fdc8bb Bump Python-Snoo to 0.6.5 (#141599)
* Bump Python-Snoo to 0.6.5

* add to event_types
2025-03-28 14:05:00 +00:00
Norbert Rittel
c490e350bc Make names of switch entities in gree consistent with docs (#141580) 2025-03-28 14:04:56 +00:00
Robert Resch
e11409ef99 Reverts #141363 "Deprecate SmartThings machine state sensors" (#141573)
Reverts #141363
2025-03-28 14:04:52 +00:00
Joost Lekkerkerker
5c8e415a76 Add default string and icon for light effect off (#141567) 2025-03-28 14:04:49 +00:00
alorente
e795fb9497 Fix missing response for queued mode scripts (#141460) 2025-03-28 14:04:45 +00:00
Norbert Rittel
d0afabb85c Fix misleading friendly names of pvoutput sensors (#141312)
* Fix misleading friendly names of `pvoutput` sensors

* Update test_sensor.py

* Update test_sensor.py - prettier
2025-03-28 14:04:41 +00:00
Franck Nijhof
4f3e8e9b94 Bump version to 2025.4.0b5 2025-03-27 20:03:14 +00:00
Paul Bottein
46c1cbbc9c Update frontend to 20250327.1 (#141596) 2025-03-27 20:03:01 +00:00
Simon Lamon
8d9a4ea278 Fix typing error in NMBS (#141589)
Fix typing error
2025-03-27 20:02:58 +00:00
Jan-Philipp Benecke
22c83e2393 Bump aiowebdav2 to 0.4.3 (#141586) 2025-03-27 20:02:55 +00:00
Joost Lekkerkerker
c83a75f6f9 Add brand for Bosch (#141561) 2025-03-27 20:02:51 +00:00
Franck Nijhof
841c727112 Bump version to 2025.4.0b4 2025-03-27 16:59:36 +00:00
Bram Kragten
d8c9655bfd Update frontend to 20250327.0 (#141585) 2025-03-27 16:59:29 +00:00
Erik Montnemery
942ed89cc4 Revert "Promote after dependencies in bootstrap" (#141584)
Revert "Promote after dependencies in bootstrap (#140352)"

This reverts commit 3766040960.
2025-03-27 16:59:25 +00:00
Franck Nijhof
a1fe6b9cf3 Bump version to 2025.4.0b3 2025-03-27 15:38:31 +00:00
Luke Lashley
2567181cc2 Better handle Roborock discovery (#141575) 2025-03-27 15:38:24 +00:00
Joost Lekkerkerker
028e4f6029 Also migrate completion time entities in SmartThings (#141572) 2025-03-27 15:38:21 +00:00
Martin Hjelmare
b82e1a9bef Handle cloud subscription expired for backup upload (#141564)
Handle cloud backup subscription expired for upload
2025-03-27 15:38:18 +00:00
Joost Lekkerkerker
438f226c31 Add icons to hue effects (#141559) 2025-03-27 15:38:15 +00:00
Erwin Douna
2f139e3cb1 Tado fix HomeKit flow (#141525)
* Initial commit

* Fix

* Fix

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
2025-03-27 15:38:07 +00:00
Franck Nijhof
5d75e96fbf Bump version to 2025.4.0b2 2025-03-27 10:19:35 +00:00
Norbert Rittel
dcf2ec5c37 Fix sentence-casing in konnected strings, replace "override" with "custom" (#141553)
Fix sentence-casing in `konnected`strings, replace "Override" with "Custom"

Make string consistent with HA standards.

As "Override" can be misunderstood as the verb, replace it with "Custom".
2025-03-27 10:19:22 +00:00
Simon Lamon
2431e1ba98 Bump linkplay to v0.2.2 (#141542)
Bump linkplay
2025-03-27 10:19:18 +00:00
Thomas55555
4ead108c15 Handle webcal prefix in remote calendar (#141541)
Handel webcal prefix in remote calendar
2025-03-27 10:19:14 +00:00
Michael Hansen
ec8363fa49 Add default preannounce sound to Assist satellites (#141522)
* Add default preannounce sound

* Allow None to disable sound

* Register static path instead of HTTP view

* Fix path

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2025-03-27 10:19:09 +00:00
J. Diego Rodríguez Royo
e7ff0a3f8b Improve some Home Connect deprecations (#141508) 2025-03-27 10:19:06 +00:00
Ivan Lopez Hernandez
f4c0eb4189 Initialize google.genai.Client in the executor (#141432)
* Intialize the client on an executor thread

* Fix MyPy error

* MyPy error

* Exception error

* Fix ruff

* Update __init__.py

---------

Co-authored-by: tronikos <tronikos@users.noreply.github.com>
2025-03-27 10:19:02 +00:00
Manu
b1ee5a76e1 Support for upcoming pyLoad-ng release in pyLoad integration (#141297)
Fix extra key `proxy` in pyLoad
2025-03-27 10:18:58 +00:00
Norbert Rittel
6b9e8c301b Fix wrong friendly name for storage_power in solaredge (#141269)
* Fix wrong friendly name for `storage_power` in `solaredge`

"Stored power" is a contradiction in itself.
You can only store energy.

* Two additional spelling fixes

* Sentence-case "site"
2025-03-27 10:18:53 +00:00
Franck Nijhof
89c3266c7e Bump version to 2025.4.0b1 2025-03-26 23:21:26 +00:00
Jan Bouwhuis
cff0a632e8 Fix QoS schema issue in MQTT subentries (#141531) 2025-03-26 23:21:17 +00:00
Jan Bouwhuis
e04d8557ae Fix MQTT options flow QoS selector can not serialize (#141528) 2025-03-26 23:21:14 +00:00
Thomas55555
ca6286f241 Fix work area sensor for Husqvarna Automower (#141527)
* Fix work area sensor for Husqvarna Automower

* simplify
2025-03-26 23:21:10 +00:00
Robert Resch
35bcc9d5af Show box for Smartthings rise number entity (#141526) 2025-03-26 23:21:07 +00:00
Joost Lekkerkerker
25b45ce867 Sort SmartThings devices to be created by parent device id (#141515) 2025-03-26 23:21:03 +00:00
Robert Resch
d568209bd5 Bump deebot-client to 12.4.0 (#141501) 2025-03-26 23:21:00 +00:00
Simone Chemelli
8a43e8af9e Fix refresh state for Comelit alarm (#141370) 2025-03-26 23:20:56 +00:00
Franck Nijhof
785e5b2c16 Bump version to 2025.4.0b0 2025-03-26 17:41:03 +00:00
1387 changed files with 66415 additions and 22849 deletions

View File

@@ -1,5 +1,6 @@
name: Report an issue with Home Assistant Core
description: Report an issue with Home Assistant Core.
type: Bug
body:
- type: markdown
attributes:

View File

@@ -32,7 +32,7 @@ jobs:
fetch-depth: 0
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
@@ -116,7 +116,7 @@ jobs:
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
if: needs.init.outputs.channel == 'dev'
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
@@ -175,7 +175,7 @@ jobs:
sed -i "s|pykrakenapi|# pykrakenapi|g" requirements_all.txt
- name: Download translations
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: translations
@@ -324,7 +324,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Install Cosign
uses: sigstore/cosign-installer@v3.8.1
uses: sigstore/cosign-installer@v3.8.2
with:
cosign-release: "v2.2.3"
@@ -457,12 +457,12 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Download translations
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: translations
@@ -509,7 +509,7 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build Docker image
uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
uses: docker/build-push-action@14487ce63c7a62a4a324b0bfb37086795e31c6c1 # v6.16.0
with:
context: . # So action will not pull the repository again
file: ./script/hassfest/docker/Dockerfile
@@ -522,7 +522,7 @@ jobs:
- name: Push Docker image
if: needs.init.outputs.channel != 'dev' && needs.init.outputs.publish == 'true'
id: push
uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
uses: docker/build-push-action@14487ce63c7a62a4a324b0bfb37086795e31c6c1 # v6.16.0
with:
context: . # So action will not pull the repository again
file: ./script/hassfest/docker/Dockerfile
@@ -531,7 +531,7 @@ jobs:
- name: Generate artifact attestation
if: needs.init.outputs.channel != 'dev' && needs.init.outputs.publish == 'true'
uses: actions/attest-build-provenance@c074443f1aee8d4aeeae555aebba3282517141b2 # v2.2.3
uses: actions/attest-build-provenance@db473fddc028af60658334401dc6fa3ffd8669fd # v2.3.0
with:
subject-name: ${{ env.HASSFEST_IMAGE_NAME }}
subject-digest: ${{ steps.push.outputs.digest }}

View File

@@ -249,7 +249,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -294,7 +294,7 @@ jobs:
- name: Check out code from GitHub
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
@@ -334,7 +334,7 @@ jobs:
- name: Check out code from GitHub
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
@@ -374,7 +374,7 @@ jobs:
- name: Check out code from GitHub
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
@@ -484,7 +484,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
@@ -587,7 +587,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -620,7 +620,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -677,7 +677,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
@@ -720,7 +720,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -767,7 +767,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -812,7 +812,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -889,7 +889,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -949,7 +949,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
@@ -968,7 +968,7 @@ jobs:
run: |
echo "::add-matcher::.github/workflows/matchers/pytest-slow.json"
- name: Download pytest_buckets
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: pytest_buckets
- name: Compile English translations
@@ -1074,7 +1074,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
@@ -1208,7 +1208,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
@@ -1312,12 +1312,12 @@ jobs:
- name: Check out code from GitHub
uses: actions/checkout@v4.2.2
- name: Download all coverage artifacts
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
pattern: coverage-*
- name: Upload coverage to Codecov
if: needs.info.outputs.test_full_suite == 'true'
uses: codecov/codecov-action@v5.4.0
uses: codecov/codecov-action@v5.4.2
with:
fail_ci_if_error: true
flags: full-suite
@@ -1359,7 +1359,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ matrix.python-version }}
check-latest: true
@@ -1454,12 +1454,12 @@ jobs:
- name: Check out code from GitHub
uses: actions/checkout@v4.2.2
- name: Download all coverage artifacts
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
pattern: coverage-*
- name: Upload coverage to Codecov
if: needs.info.outputs.test_full_suite == 'false'
uses: codecov/codecov-action@v5.4.0
uses: codecov/codecov-action@v5.4.2
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
@@ -1479,7 +1479,7 @@ jobs:
timeout-minutes: 10
steps:
- name: Download all coverage artifacts
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
pattern: test-results-*
- name: Upload test results to Codecov

View File

@@ -24,11 +24,11 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Initialize CodeQL
uses: github/codeql-action/init@v3.28.15
uses: github/codeql-action/init@v3.28.16
with:
languages: python
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3.28.15
uses: github/codeql-action/analyze@v3.28.16
with:
category: "/language:python"

View File

@@ -22,7 +22,7 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}

View File

@@ -36,7 +36,7 @@ jobs:
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
id: python
uses: actions/setup-python@v5.5.0
uses: actions/setup-python@v5.6.0
with:
python-version: ${{ env.DEFAULT_PYTHON }}
check-latest: true
@@ -138,17 +138,17 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Download env_file
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: env_file
- name: Download build_constraints
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: build_constraints
- name: Download requirements_diff
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: requirements_diff
@@ -187,22 +187,22 @@ jobs:
uses: actions/checkout@v4.2.2
- name: Download env_file
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: env_file
- name: Download build_constraints
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: build_constraints
- name: Download requirements_diff
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: requirements_diff
- name: Download requirements_all_wheels
uses: actions/download-artifact@v4.2.1
uses: actions/download-artifact@v4.3.0
with:
name: requirements_all_wheels

View File

@@ -291,6 +291,7 @@ homeassistant.components.kaleidescape.*
homeassistant.components.knocki.*
homeassistant.components.knx.*
homeassistant.components.kraken.*
homeassistant.components.kulersky.*
homeassistant.components.lacrosse.*
homeassistant.components.lacrosse_view.*
homeassistant.components.lamarzocco.*
@@ -362,6 +363,7 @@ homeassistant.components.no_ip.*
homeassistant.components.nordpool.*
homeassistant.components.notify.*
homeassistant.components.notion.*
homeassistant.components.ntfy.*
homeassistant.components.number.*
homeassistant.components.nut.*
homeassistant.components.ohme.*
@@ -384,6 +386,7 @@ homeassistant.components.pandora.*
homeassistant.components.panel_custom.*
homeassistant.components.peblar.*
homeassistant.components.peco.*
homeassistant.components.pegel_online.*
homeassistant.components.persistent_notification.*
homeassistant.components.person.*
homeassistant.components.pi_hole.*
@@ -460,6 +463,7 @@ homeassistant.components.slack.*
homeassistant.components.sleepiq.*
homeassistant.components.smhi.*
homeassistant.components.smlight.*
homeassistant.components.smtp.*
homeassistant.components.snooz.*
homeassistant.components.solarlog.*
homeassistant.components.sonarr.*

16
CODEOWNERS generated
View File

@@ -432,7 +432,7 @@ build.json @home-assistant/supervisor
/homeassistant/components/entur_public_transport/ @hfurubotten
/homeassistant/components/environment_canada/ @gwww @michaeldavie
/tests/components/environment_canada/ @gwww @michaeldavie
/homeassistant/components/ephember/ @ttroy50
/homeassistant/components/ephember/ @ttroy50 @roberty99
/homeassistant/components/epic_games_store/ @hacf-fr @Quentame
/tests/components/epic_games_store/ @hacf-fr @Quentame
/homeassistant/components/epion/ @lhgravendeel
@@ -937,6 +937,8 @@ build.json @home-assistant/supervisor
/tests/components/metoffice/ @MrHarcombe @avee87
/homeassistant/components/microbees/ @microBeesTech
/tests/components/microbees/ @microBeesTech
/homeassistant/components/miele/ @astrandb
/tests/components/miele/ @astrandb
/homeassistant/components/mikrotik/ @engrbm87
/tests/components/mikrotik/ @engrbm87
/homeassistant/components/mill/ @danielhiversen
@@ -1049,6 +1051,8 @@ build.json @home-assistant/supervisor
/tests/components/nsw_fuel_station/ @nickw444
/homeassistant/components/nsw_rural_fire_service_feed/ @exxamalte
/tests/components/nsw_rural_fire_service_feed/ @exxamalte
/homeassistant/components/ntfy/ @tr4nt0r
/tests/components/ntfy/ @tr4nt0r
/homeassistant/components/nuheat/ @tstabrawa
/tests/components/nuheat/ @tstabrawa
/homeassistant/components/nuki/ @pschmitt @pvizeli @pree
@@ -1314,6 +1318,8 @@ build.json @home-assistant/supervisor
/tests/components/ruuvitag_ble/ @akx
/homeassistant/components/rympro/ @OnFreund @elad-bar @maorcc
/tests/components/rympro/ @OnFreund @elad-bar @maorcc
/homeassistant/components/s3/ @tomasbedrich
/tests/components/s3/ @tomasbedrich
/homeassistant/components/sabnzbd/ @shaiu @jpbede
/tests/components/sabnzbd/ @shaiu @jpbede
/homeassistant/components/saj/ @fredericvl
@@ -1389,7 +1395,6 @@ build.json @home-assistant/supervisor
/homeassistant/components/siren/ @home-assistant/core @raman325
/tests/components/siren/ @home-assistant/core @raman325
/homeassistant/components/sisyphus/ @jkeljo
/homeassistant/components/sky_hub/ @rogerselwyn
/homeassistant/components/sky_remote/ @dunnmj @saty9
/tests/components/sky_remote/ @dunnmj @saty9
/homeassistant/components/skybell/ @tkdrob
@@ -1436,8 +1441,8 @@ build.json @home-assistant/supervisor
/tests/components/solarlog/ @Ernst79 @dontinelli
/homeassistant/components/solax/ @squishykid @Darsstar
/tests/components/solax/ @squishykid @Darsstar
/homeassistant/components/soma/ @ratsept @sebfortier2288
/tests/components/soma/ @ratsept @sebfortier2288
/homeassistant/components/soma/ @ratsept
/tests/components/soma/ @ratsept
/homeassistant/components/sonarr/ @ctalkington
/tests/components/sonarr/ @ctalkington
/homeassistant/components/songpal/ @rytilahti @shenxn
@@ -1469,7 +1474,8 @@ build.json @home-assistant/supervisor
/tests/components/steam_online/ @tkdrob
/homeassistant/components/steamist/ @bdraco
/tests/components/steamist/ @bdraco
/homeassistant/components/stiebel_eltron/ @fucm
/homeassistant/components/stiebel_eltron/ @fucm @ThyMYthOS
/tests/components/stiebel_eltron/ @fucm @ThyMYthOS
/homeassistant/components/stookwijzer/ @fwestenberg
/tests/components/stookwijzer/ @fwestenberg
/homeassistant/components/stream/ @hunterjm @uvjustin @allenporter

View File

@@ -53,6 +53,7 @@ from .components import (
logbook as logbook_pre_import, # noqa: F401
lovelace as lovelace_pre_import, # noqa: F401
onboarding as onboarding_pre_import, # noqa: F401
person as person_pre_import, # noqa: F401
recorder as recorder_import, # noqa: F401 - not named pre_import since it has requirements
repairs as repairs_pre_import, # noqa: F401
search as search_pre_import, # noqa: F401

View File

@@ -6,5 +6,5 @@
"documentation": "https://www.home-assistant.io/integrations/airzone_cloud",
"iot_class": "cloud_push",
"loggers": ["aioairzone_cloud"],
"requirements": ["aioairzone-cloud==0.6.11"]
"requirements": ["aioairzone-cloud==0.6.12"]
}

View File

@@ -34,7 +34,7 @@
"state": {
"off": "[%key:common::state::off%]",
"on": "[%key:common::state::on%]",
"auto": "Auto"
"auto": "[%key:common::state::auto%]"
}
},
"modes": {

View File

@@ -719,7 +719,7 @@ class LockCapabilities(AlexaEntity):
yield Alexa(self.entity)
@ENTITY_ADAPTERS.register(media_player.const.DOMAIN)
@ENTITY_ADAPTERS.register(media_player.DOMAIN)
class MediaPlayerCapabilities(AlexaEntity):
"""Class to represent MediaPlayer capabilities."""
@@ -757,9 +757,7 @@ class MediaPlayerCapabilities(AlexaEntity):
if supported & media_player.MediaPlayerEntityFeature.SELECT_SOURCE:
inputs = AlexaInputController.get_valid_inputs(
self.entity.attributes.get(
media_player.const.ATTR_INPUT_SOURCE_LIST, []
)
self.entity.attributes.get(media_player.ATTR_INPUT_SOURCE_LIST, [])
)
if len(inputs) > 0:
yield AlexaInputController(self.entity)
@@ -776,8 +774,7 @@ class MediaPlayerCapabilities(AlexaEntity):
and domain != "denonavr"
):
inputs = AlexaEqualizerController.get_valid_inputs(
self.entity.attributes.get(media_player.const.ATTR_SOUND_MODE_LIST)
or []
self.entity.attributes.get(media_player.ATTR_SOUND_MODE_LIST) or []
)
if len(inputs) > 0:
yield AlexaEqualizerController(self.entity)

View File

@@ -566,7 +566,7 @@ async def async_api_set_volume(
data: dict[str, Any] = {
ATTR_ENTITY_ID: entity.entity_id,
media_player.const.ATTR_MEDIA_VOLUME_LEVEL: volume,
media_player.ATTR_MEDIA_VOLUME_LEVEL: volume,
}
await hass.services.async_call(
@@ -589,7 +589,7 @@ async def async_api_select_input(
# Attempt to map the ALL UPPERCASE payload name to a source.
# Strips trailing 1 to match single input devices.
source_list = entity.attributes.get(media_player.const.ATTR_INPUT_SOURCE_LIST) or []
source_list = entity.attributes.get(media_player.ATTR_INPUT_SOURCE_LIST) or []
for source in source_list:
formatted_source = (
source.lower().replace("-", "").replace("_", "").replace(" ", "")
@@ -611,7 +611,7 @@ async def async_api_select_input(
data: dict[str, Any] = {
ATTR_ENTITY_ID: entity.entity_id,
media_player.const.ATTR_INPUT_SOURCE: media_input,
media_player.ATTR_INPUT_SOURCE: media_input,
}
await hass.services.async_call(
@@ -636,7 +636,7 @@ async def async_api_adjust_volume(
volume_delta = int(directive.payload["volume"])
entity = directive.entity
current_level = entity.attributes[media_player.const.ATTR_MEDIA_VOLUME_LEVEL]
current_level = entity.attributes[media_player.ATTR_MEDIA_VOLUME_LEVEL]
# read current state
try:
@@ -648,7 +648,7 @@ async def async_api_adjust_volume(
data: dict[str, Any] = {
ATTR_ENTITY_ID: entity.entity_id,
media_player.const.ATTR_MEDIA_VOLUME_LEVEL: volume,
media_player.ATTR_MEDIA_VOLUME_LEVEL: volume,
}
await hass.services.async_call(
@@ -709,7 +709,7 @@ async def async_api_set_mute(
entity = directive.entity
data: dict[str, Any] = {
ATTR_ENTITY_ID: entity.entity_id,
media_player.const.ATTR_MEDIA_VOLUME_MUTED: mute,
media_player.ATTR_MEDIA_VOLUME_MUTED: mute,
}
await hass.services.async_call(
@@ -1708,15 +1708,13 @@ async def async_api_changechannel(
data: dict[str, Any] = {
ATTR_ENTITY_ID: entity.entity_id,
media_player.const.ATTR_MEDIA_CONTENT_ID: channel,
media_player.const.ATTR_MEDIA_CONTENT_TYPE: (
media_player.const.MEDIA_TYPE_CHANNEL
),
media_player.ATTR_MEDIA_CONTENT_ID: channel,
media_player.ATTR_MEDIA_CONTENT_TYPE: (media_player.MediaType.CHANNEL),
}
await hass.services.async_call(
entity.domain,
media_player.const.SERVICE_PLAY_MEDIA,
media_player.SERVICE_PLAY_MEDIA,
data,
blocking=False,
context=context,
@@ -1825,13 +1823,13 @@ async def async_api_set_eq_mode(
context: ha.Context,
) -> AlexaResponse:
"""Process a SetMode request for EqualizerController."""
mode = directive.payload["mode"]
mode: str = directive.payload["mode"]
entity = directive.entity
data: dict[str, Any] = {ATTR_ENTITY_ID: entity.entity_id}
sound_mode_list = entity.attributes.get(media_player.const.ATTR_SOUND_MODE_LIST)
sound_mode_list = entity.attributes.get(media_player.ATTR_SOUND_MODE_LIST)
if sound_mode_list and mode.lower() in sound_mode_list:
data[media_player.const.ATTR_SOUND_MODE] = mode.lower()
data[media_player.ATTR_SOUND_MODE] = mode.lower()
else:
msg = f"failed to map sound mode {mode} to a mode on {entity.entity_id}"
raise AlexaInvalidValueError(msg)

View File

@@ -3,10 +3,10 @@
from __future__ import annotations
from asyncio import timeout
from collections.abc import Mapping
from http import HTTPStatus
import json
import logging
from types import MappingProxyType
from typing import TYPE_CHECKING, Any, cast
from uuid import uuid4
@@ -260,10 +260,10 @@ async def async_enable_proactive_mode(
def extra_significant_check(
hass: HomeAssistant,
old_state: str,
old_attrs: dict[Any, Any] | MappingProxyType[Any, Any],
old_attrs: Mapping[Any, Any],
old_extra_arg: Any,
new_state: str,
new_attrs: dict[str, Any] | MappingProxyType[Any, Any],
new_attrs: Mapping[Any, Any],
new_extra_arg: Any,
) -> bool:
"""Check if the serialized data has changed."""

View File

@@ -3,12 +3,12 @@
"step": {
"user": {
"data": {
"tracked_addons": "Addons",
"tracked_addons": "Add-ons",
"tracked_integrations": "Integrations",
"tracked_custom_integrations": "Custom integrations"
},
"data_description": {
"tracked_addons": "Select the addons you want to track",
"tracked_addons": "Select the add-ons you want to track",
"tracked_integrations": "Select the integrations you want to track",
"tracked_custom_integrations": "Select the custom integrations you want to track"
}

View File

@@ -2,6 +2,7 @@
from __future__ import annotations
from collections.abc import Mapping
from functools import partial
import logging
from types import MappingProxyType
@@ -52,7 +53,7 @@ STEP_USER_DATA_SCHEMA = vol.Schema(
RECOMMENDED_OPTIONS = {
CONF_RECOMMENDED: True,
CONF_LLM_HASS_API: llm.LLM_API_ASSIST,
CONF_LLM_HASS_API: [llm.LLM_API_ASSIST],
CONF_PROMPT: llm.DEFAULT_INSTRUCTIONS_PROMPT,
}
@@ -134,9 +135,8 @@ class AnthropicOptionsFlow(OptionsFlow):
if user_input is not None:
if user_input[CONF_RECOMMENDED] == self.last_rendered_recommended:
if user_input[CONF_LLM_HASS_API] == "none":
user_input.pop(CONF_LLM_HASS_API)
if not user_input.get(CONF_LLM_HASS_API):
user_input.pop(CONF_LLM_HASS_API, None)
if user_input.get(
CONF_THINKING_BUDGET, RECOMMENDED_THINKING_BUDGET
) >= user_input.get(CONF_MAX_TOKENS, RECOMMENDED_MAX_TOKENS):
@@ -151,12 +151,16 @@ class AnthropicOptionsFlow(OptionsFlow):
options = {
CONF_RECOMMENDED: user_input[CONF_RECOMMENDED],
CONF_PROMPT: user_input[CONF_PROMPT],
CONF_LLM_HASS_API: user_input[CONF_LLM_HASS_API],
CONF_LLM_HASS_API: user_input.get(CONF_LLM_HASS_API),
}
suggested_values = options.copy()
if not suggested_values.get(CONF_PROMPT):
suggested_values[CONF_PROMPT] = llm.DEFAULT_INSTRUCTIONS_PROMPT
if (
suggested_llm_apis := suggested_values.get(CONF_LLM_HASS_API)
) and isinstance(suggested_llm_apis, str):
suggested_values[CONF_LLM_HASS_API] = [suggested_llm_apis]
schema = self.add_suggested_values_to_schema(
vol.Schema(anthropic_config_option_schema(self.hass, options)),
@@ -172,28 +176,22 @@ class AnthropicOptionsFlow(OptionsFlow):
def anthropic_config_option_schema(
hass: HomeAssistant,
options: dict[str, Any] | MappingProxyType[str, Any],
options: Mapping[str, Any],
) -> dict:
"""Return a schema for Anthropic completion options."""
hass_apis: list[SelectOptionDict] = [
SelectOptionDict(
label="No control",
value="none",
)
]
hass_apis.extend(
SelectOptionDict(
label=api.name,
value=api.id,
)
for api in llm.async_get_apis(hass)
)
]
schema = {
vol.Optional(CONF_PROMPT): TemplateSelector(),
vol.Optional(CONF_LLM_HASS_API, default="none"): SelectSelector(
SelectSelectorConfig(options=hass_apis)
),
vol.Optional(
CONF_LLM_HASS_API,
): SelectSelector(SelectSelectorConfig(options=hass_apis, multiple=True)),
vol.Required(
CONF_RECOMMENDED, default=options.get(CONF_RECOMMENDED, False)
): bool,

View File

@@ -9,11 +9,13 @@ from anthropic import AsyncStream
from anthropic._types import NOT_GIVEN
from anthropic.types import (
InputJSONDelta,
MessageDeltaUsage,
MessageParam,
MessageStreamEvent,
RawContentBlockDeltaEvent,
RawContentBlockStartEvent,
RawContentBlockStopEvent,
RawMessageDeltaEvent,
RawMessageStartEvent,
RawMessageStopEvent,
RedactedThinkingBlock,
@@ -31,6 +33,7 @@ from anthropic.types import (
ToolResultBlockParam,
ToolUseBlock,
ToolUseBlockParam,
Usage,
)
from voluptuous_openapi import convert
@@ -162,7 +165,8 @@ def _convert_content(
return messages
async def _transform_stream(
async def _transform_stream( # noqa: C901 - This is complex, but better to have it in one place
chat_log: conversation.ChatLog,
result: AsyncStream[MessageStreamEvent],
messages: list[MessageParam],
) -> AsyncGenerator[conversation.AssistantContentDeltaDict]:
@@ -207,6 +211,7 @@ async def _transform_stream(
| None
) = None
current_tool_args: str
input_usage: Usage | None = None
async for response in result:
LOGGER.debug("Received response: %s", response)
@@ -215,6 +220,7 @@ async def _transform_stream(
if response.message.role != "assistant":
raise ValueError("Unexpected message role")
current_message = MessageParam(role=response.message.role, content=[])
input_usage = response.message.usage
elif isinstance(response, RawContentBlockStartEvent):
if isinstance(response.content_block, ToolUseBlock):
current_block = ToolUseBlockParam(
@@ -265,32 +271,54 @@ async def _transform_stream(
if current_block is None:
raise ValueError("Unexpected stop event without a current block")
if current_block["type"] == "tool_use":
tool_block = cast(ToolUseBlockParam, current_block)
tool_args = json.loads(current_tool_args)
tool_block["input"] = tool_args
# tool block
tool_args = json.loads(current_tool_args) if current_tool_args else {}
current_block["input"] = tool_args
yield {
"tool_calls": [
llm.ToolInput(
id=tool_block["id"],
tool_name=tool_block["name"],
id=current_block["id"],
tool_name=current_block["name"],
tool_args=tool_args,
)
]
}
elif current_block["type"] == "thinking":
thinking_block = cast(ThinkingBlockParam, current_block)
LOGGER.debug("Thinking: %s", thinking_block["thinking"])
# thinking block
LOGGER.debug("Thinking: %s", current_block["thinking"])
if current_message is None:
raise ValueError("Unexpected stop event without a current message")
current_message["content"].append(current_block) # type: ignore[union-attr]
current_block = None
elif isinstance(response, RawMessageDeltaEvent):
if (usage := response.usage) is not None:
chat_log.async_trace(_create_token_stats(input_usage, usage))
elif isinstance(response, RawMessageStopEvent):
if current_message is not None:
messages.append(current_message)
current_message = None
def _create_token_stats(
input_usage: Usage | None, response_usage: MessageDeltaUsage
) -> dict[str, Any]:
"""Create token stats for conversation agent tracing."""
input_tokens = 0
cached_input_tokens = 0
if input_usage:
input_tokens = input_usage.input_tokens
cached_input_tokens = input_usage.cache_creation_input_tokens or 0
output_tokens = response_usage.output_tokens
return {
"stats": {
"input_tokens": input_tokens,
"cached_input_tokens": cached_input_tokens,
"output_tokens": output_tokens,
}
}
class AnthropicConversationEntity(
conversation.ConversationEntity, conversation.AbstractConversationAgent
):
@@ -393,7 +421,8 @@ class AnthropicConversationEntity(
[
content
async for content in chat_log.async_add_delta_content_stream(
user_input.agent_id, _transform_stream(stream, messages)
user_input.agent_id,
_transform_stream(chat_log, stream, messages),
)
if not isinstance(content, conversation.AssistantContent)
]

View File

@@ -113,4 +113,7 @@ class APCUPSdCoordinator(DataUpdateCoordinator[APCUPSdData]):
data = await aioapcaccess.request_status(self._host, self._port)
return APCUPSdData(data)
except (OSError, asyncio.IncompleteReadError) as error:
raise UpdateFailed(error) from error
raise UpdateFailed(
translation_domain=DOMAIN,
translation_key="cannot_connect",
) from error

View File

@@ -93,7 +93,7 @@
"name": "Internal temperature"
},
"last_self_test": {
"name": "Last self test"
"name": "Last self-test"
},
"last_transfer": {
"name": "Last transfer"
@@ -177,7 +177,7 @@
"name": "Restore requirement"
},
"self_test_result": {
"name": "Self test result"
"name": "Self-test result"
},
"sensitivity": {
"name": "Sensitivity"
@@ -195,7 +195,7 @@
"name": "Status"
},
"self_test_interval": {
"name": "Self test interval"
"name": "Self-test interval"
},
"time_left": {
"name": "Time left"
@@ -219,5 +219,10 @@
"name": "Transfer to battery"
}
}
},
"exceptions": {
"cannot_connect": {
"message": "Cannot connect to APC UPS Daemon."
}
}
}

View File

@@ -120,6 +120,7 @@ class AppleTvMediaPlayer(
"""Initialize the Apple TV media player."""
super().__init__(name, identifier, manager)
self._playing: Playing | None = None
self._playing_last_updated: datetime | None = None
self._app_list: dict[str, str] = {}
@callback
@@ -209,6 +210,7 @@ class AppleTvMediaPlayer(
This is a callback function from pyatv.interface.PushListener.
"""
self._playing = playstatus
self._playing_last_updated = dt_util.utcnow()
self.async_write_ha_state()
@callback
@@ -316,7 +318,7 @@ class AppleTvMediaPlayer(
def media_position_updated_at(self) -> datetime | None:
"""Last valid time of media position."""
if self.state in {MediaPlayerState.PLAYING, MediaPlayerState.PAUSED}:
return dt_util.utcnow()
return self._playing_last_updated
return None
async def async_play_media(

View File

@@ -6,5 +6,6 @@
"documentation": "https://www.home-assistant.io/integrations/apsystems",
"integration_type": "device",
"iot_class": "local_polling",
"requirements": ["apsystems-ez1==2.5.0"]
"loggers": ["APsystemsEZ1"],
"requirements": ["apsystems-ez1==2.6.0"]
}

View File

@@ -21,7 +21,7 @@
"entity": {
"binary_sensor": {
"off_grid_status": {
"name": "Off grid status"
"name": "Off-grid status"
},
"dc_1_short_circuit_error_status": {
"name": "DC 1 short circuit error status"

View File

@@ -26,7 +26,7 @@
"sensor": {
"threshold": {
"state": {
"error": "Error",
"error": "[%key:common::state::error%]",
"green": "Green",
"yellow": "Yellow",
"red": "Red"

View File

@@ -20,9 +20,6 @@ import hass_nabucasa
import voluptuous as vol
from homeassistant.components import conversation, stt, tts, wake_word, websocket_api
from homeassistant.components.tts import (
generate_media_source_id as tts_generate_media_source_id,
)
from homeassistant.const import ATTR_SUPPORTED_FEATURES, MATCH_ALL
from homeassistant.core import Context, HomeAssistant, callback
from homeassistant.exceptions import HomeAssistantError
@@ -1276,33 +1273,19 @@ class PipelineRun:
)
)
try:
# Synthesize audio and get URL
tts_media_id = tts_generate_media_source_id(
self.hass,
tts_input,
engine=self.tts_stream.engine,
language=self.tts_stream.language,
options=self.tts_stream.options,
)
except Exception as src_error:
_LOGGER.exception("Unexpected error during text-to-speech")
raise TextToSpeechError(
code="tts-failed",
message="Unexpected error during text-to-speech",
) from src_error
self.tts_stream.async_set_message(tts_input)
tts_output = {
"media_id": tts_media_id,
"token": self.tts_stream.token,
"url": self.tts_stream.url,
"mime_type": self.tts_stream.content_type,
}
self.process_event(
PipelineEvent(PipelineEventType.TTS_END, {"tts_output": tts_output})
PipelineEvent(
PipelineEventType.TTS_END,
{
"tts_output": {
"token": self.tts_stream.token,
"url": self.tts_stream.url,
"mime_type": self.tts_stream.content_type,
}
},
)
)
def _capture_chunk(self, audio_bytes: bytes | None) -> None:

View File

@@ -2,10 +2,9 @@
from __future__ import annotations
from collections.abc import Callable
from collections.abc import Callable, Mapping
from datetime import datetime, timedelta
import logging
from types import MappingProxyType
from typing import Any
from pyasuswrt import AsusWrtError
@@ -363,7 +362,7 @@ class AsusWrtRouter:
"""Add a function to call when router is closed."""
self._on_close.append(func)
def update_options(self, new_options: MappingProxyType[str, Any]) -> bool:
def update_options(self, new_options: Mapping[str, Any]) -> bool:
"""Update router options."""
req_reload = False
for name, new_opt in new_options.items():

View File

@@ -28,5 +28,5 @@
"documentation": "https://www.home-assistant.io/integrations/august",
"iot_class": "cloud_push",
"loggers": ["pubnub", "yalexs"],
"requirements": ["yalexs==8.10.0", "yalexs-ble==2.5.7"]
"requirements": ["yalexs==8.10.0", "yalexs-ble==2.6.0"]
}

View File

@@ -18,6 +18,7 @@ from homeassistant.const import (
ATTR_ENTITY_ID,
ATTR_MODE,
ATTR_NAME,
CONF_ACTIONS,
CONF_ALIAS,
CONF_CONDITIONS,
CONF_DEVICE_ID,
@@ -27,6 +28,7 @@ from homeassistant.const import (
CONF_MODE,
CONF_PATH,
CONF_PLATFORM,
CONF_TRIGGERS,
CONF_VARIABLES,
CONF_ZONE,
EVENT_HOMEASSISTANT_STARTED,
@@ -86,11 +88,9 @@ from homeassistant.util.hass_dict import HassKey
from .config import AutomationConfig, ValidationStatus
from .const import (
CONF_ACTIONS,
CONF_INITIAL_STATE,
CONF_TRACE,
CONF_TRIGGER_VARIABLES,
CONF_TRIGGERS,
DEFAULT_INITIAL_STATE,
DOMAIN,
LOGGER,

View File

@@ -14,11 +14,15 @@ from homeassistant.components import blueprint
from homeassistant.components.trace import TRACE_CONFIG_SCHEMA
from homeassistant.config import config_per_platform, config_without_domain
from homeassistant.const import (
CONF_ACTION,
CONF_ACTIONS,
CONF_ALIAS,
CONF_CONDITION,
CONF_CONDITIONS,
CONF_DESCRIPTION,
CONF_ID,
CONF_TRIGGER,
CONF_TRIGGERS,
CONF_VARIABLES,
)
from homeassistant.core import HomeAssistant
@@ -30,14 +34,10 @@ from homeassistant.helpers.typing import ConfigType
from homeassistant.util.yaml.input import UndefinedSubstitution
from .const import (
CONF_ACTION,
CONF_ACTIONS,
CONF_HIDE_ENTITY,
CONF_INITIAL_STATE,
CONF_TRACE,
CONF_TRIGGER,
CONF_TRIGGER_VARIABLES,
CONF_TRIGGERS,
DOMAIN,
LOGGER,
)
@@ -58,34 +58,9 @@ _MINIMAL_PLATFORM_SCHEMA = vol.Schema(
def _backward_compat_schema(value: Any | None) -> Any:
"""Backward compatibility for automations."""
if not isinstance(value, dict):
return value
# `trigger` has been renamed to `triggers`
if CONF_TRIGGER in value:
if CONF_TRIGGERS in value:
raise vol.Invalid(
"Cannot specify both 'trigger' and 'triggers'. Please use 'triggers' only."
)
value[CONF_TRIGGERS] = value.pop(CONF_TRIGGER)
# `condition` has been renamed to `conditions`
if CONF_CONDITION in value:
if CONF_CONDITIONS in value:
raise vol.Invalid(
"Cannot specify both 'condition' and 'conditions'. Please use 'conditions' only."
)
value[CONF_CONDITIONS] = value.pop(CONF_CONDITION)
# `action` has been renamed to `actions`
if CONF_ACTION in value:
if CONF_ACTIONS in value:
raise vol.Invalid(
"Cannot specify both 'action' and 'actions'. Please use 'actions' only."
)
value[CONF_ACTIONS] = value.pop(CONF_ACTION)
return value
value = cv.renamed(CONF_TRIGGER, CONF_TRIGGERS)(value)
value = cv.renamed(CONF_ACTION, CONF_ACTIONS)(value)
return cv.renamed(CONF_CONDITION, CONF_CONDITIONS)(value)
PLATFORM_SCHEMA = vol.All(

View File

@@ -2,10 +2,6 @@
import logging
CONF_ACTION = "action"
CONF_ACTIONS = "actions"
CONF_TRIGGER = "trigger"
CONF_TRIGGERS = "triggers"
CONF_TRIGGER_VARIABLES = "trigger_variables"
DOMAIN = "automation"

View File

@@ -4,7 +4,6 @@ from __future__ import annotations
from collections.abc import Mapping
from ipaddress import ip_address
from types import MappingProxyType
from typing import Any
from urllib.parse import urlsplit
@@ -88,7 +87,7 @@ class AxisFlowHandler(ConfigFlow, domain=AXIS_DOMAIN):
if user_input is not None:
try:
api = await get_axis_api(self.hass, MappingProxyType(user_input))
api = await get_axis_api(self.hass, user_input)
except AuthenticationRequired:
errors["base"] = "invalid_auth"

View File

@@ -1,7 +1,7 @@
"""Axis network device abstraction."""
from asyncio import timeout
from types import MappingProxyType
from collections.abc import Mapping
from typing import Any
import axis
@@ -23,7 +23,7 @@ from ..errors import AuthenticationRequired, CannotConnect
async def get_axis_api(
hass: HomeAssistant,
config: MappingProxyType[str, Any],
config: Mapping[str, Any],
) -> axis.AxisDevice:
"""Create a Axis device API."""
session = get_async_client(hass, verify_ssl=False)

View File

@@ -3,11 +3,10 @@
from __future__ import annotations
import asyncio
from collections.abc import Callable
from collections.abc import Callable, Mapping
from datetime import datetime
import json
import logging
from types import MappingProxyType
from typing import Any
from azure.eventhub import EventData, EventDataBatch
@@ -179,7 +178,7 @@ class AzureEventHub:
await self.async_send(None)
await self._queue.join()
def update_options(self, new_options: MappingProxyType[str, Any]) -> None:
def update_options(self, new_options: Mapping[str, Any]) -> None:
"""Update options."""
self._send_interval = new_options[CONF_SEND_INTERVAL]

View File

@@ -2,6 +2,7 @@
from __future__ import annotations
from collections import defaultdict
from dataclasses import dataclass, field, replace
import datetime as dt
from datetime import datetime, timedelta
@@ -87,12 +88,26 @@ class BackupConfigData:
else:
time = None
days = [Day(day) for day in data["schedule"]["days"]]
agents = {}
for agent_id, agent_data in data["agents"].items():
protected = agent_data["protected"]
stored_retention = agent_data["retention"]
agent_retention: AgentRetentionConfig | None
if stored_retention:
agent_retention = AgentRetentionConfig(
copies=stored_retention["copies"],
days=stored_retention["days"],
)
else:
agent_retention = None
agent_config = AgentConfig(
protected=protected,
retention=agent_retention,
)
agents[agent_id] = agent_config
return cls(
agents={
agent_id: AgentConfig(protected=agent_data["protected"])
for agent_id, agent_data in data["agents"].items()
},
agents=agents,
automatic_backups_configured=data["automatic_backups_configured"],
create_backup=CreateBackupConfig(
agent_ids=data["create_backup"]["agent_ids"],
@@ -176,12 +191,36 @@ class BackupConfig:
"""Update config."""
if agents is not UNDEFINED:
for agent_id, agent_config in agents.items():
if agent_id not in self.data.agents:
self.data.agents[agent_id] = AgentConfig(**agent_config)
agent_retention = agent_config.get("retention")
if agent_retention is None:
new_agent_retention = None
else:
self.data.agents[agent_id] = replace(
self.data.agents[agent_id], **agent_config
new_agent_retention = AgentRetentionConfig(
copies=agent_retention.get("copies"),
days=agent_retention.get("days"),
)
if agent_id not in self.data.agents:
old_agent_retention = None
self.data.agents[agent_id] = AgentConfig(
protected=agent_config.get("protected", False),
retention=new_agent_retention,
)
else:
new_agent_config = self.data.agents[agent_id]
old_agent_retention = new_agent_config.retention
if "protected" in agent_config:
new_agent_config = replace(
new_agent_config, protected=agent_config["protected"]
)
if "retention" in agent_config:
new_agent_config = replace(
new_agent_config, retention=new_agent_retention
)
self.data.agents[agent_id] = new_agent_config
if new_agent_retention != old_agent_retention:
# There's a single retention application method
# for both global and agent retention settings.
self.data.retention.apply(self._manager)
if automatic_backups_configured is not UNDEFINED:
self.data.automatic_backups_configured = automatic_backups_configured
if create_backup is not UNDEFINED:
@@ -207,11 +246,24 @@ class AgentConfig:
"""Represent the config for an agent."""
protected: bool
"""Agent protected configuration.
If True, the agent backups are password protected.
"""
retention: AgentRetentionConfig | None = None
"""Agent retention configuration.
If None, the global retention configuration is used.
If not None, the global retention configuration is ignored for this agent.
If an agent retention configuration is set and both copies and days are None,
backups will be kept forever for that agent.
"""
def to_dict(self) -> StoredAgentConfig:
"""Convert agent config to a dict."""
return {
"protected": self.protected,
"retention": self.retention.to_dict() if self.retention else None,
}
@@ -219,24 +271,46 @@ class StoredAgentConfig(TypedDict):
"""Represent the stored config for an agent."""
protected: bool
retention: StoredRetentionConfig | None
class AgentParametersDict(TypedDict, total=False):
"""Represent the parameters for an agent."""
protected: bool
retention: RetentionParametersDict | None
@dataclass(kw_only=True)
class RetentionConfig:
"""Represent the backup retention configuration."""
class BaseRetentionConfig:
"""Represent the base backup retention configuration."""
copies: int | None = None
days: int | None = None
def to_dict(self) -> StoredRetentionConfig:
"""Convert backup retention configuration to a dict."""
return StoredRetentionConfig(
copies=self.copies,
days=self.days,
)
@dataclass(kw_only=True)
class RetentionConfig(BaseRetentionConfig):
"""Represent the backup retention configuration."""
def apply(self, manager: BackupManager) -> None:
"""Apply backup retention configuration."""
if self.days is not None:
agents_retention = {
agent_id: agent_config.retention
for agent_id, agent_config in manager.config.data.agents.items()
}
if self.days is not None or any(
agent_retention and agent_retention.days is not None
for agent_retention in agents_retention.values()
):
LOGGER.debug(
"Scheduling next automatic delete of backups older than %s in 1 day",
self.days,
@@ -246,13 +320,6 @@ class RetentionConfig:
LOGGER.debug("Unscheduling next automatic delete")
self._unschedule_next(manager)
def to_dict(self) -> StoredRetentionConfig:
"""Convert backup retention configuration to a dict."""
return StoredRetentionConfig(
copies=self.copies,
days=self.days,
)
@callback
def _schedule_next(
self,
@@ -271,16 +338,81 @@ class RetentionConfig:
"""Return backups older than days to delete."""
# we need to check here since we await before
# this filter is applied
if self.days is None:
return {}
now = dt_util.utcnow()
return {
backup_id: backup
for backup_id, backup in backups.items()
if dt_util.parse_datetime(backup.date, raise_on_error=True)
+ timedelta(days=self.days)
< now
agents_retention = {
agent_id: agent_config.retention
for agent_id, agent_config in manager.config.data.agents.items()
}
has_agents_retention = any(
agent_retention for agent_retention in agents_retention.values()
)
has_agents_retention_days = any(
agent_retention and agent_retention.days is not None
for agent_retention in agents_retention.values()
)
if (global_days := self.days) is None and not has_agents_retention_days:
# No global retention days and no agent retention days
return {}
now = dt_util.utcnow()
if global_days is not None and not has_agents_retention:
# Return early to avoid the longer filtering below.
return {
backup_id: backup
for backup_id, backup in backups.items()
if dt_util.parse_datetime(backup.date, raise_on_error=True)
+ timedelta(days=global_days)
< now
}
# If there are any agent retention settings, we need to check
# the retention settings, for every backup and agent combination.
backups_to_delete = {}
for backup_id, backup in backups.items():
backup_date = dt_util.parse_datetime(
backup.date, raise_on_error=True
)
delete_from_agents = set(backup.agents)
for agent_id in backup.agents:
agent_retention = agents_retention.get(agent_id)
if agent_retention is None:
# This agent does not have a retention setting,
# so the global retention setting should be used.
if global_days is None:
# This agent does not have a retention setting
# and the global retention days setting is None,
# so this backup should not be deleted.
delete_from_agents.discard(agent_id)
continue
days = global_days
elif (agent_days := agent_retention.days) is None:
# This agent has a retention setting
# where days is set to None,
# so the backup should not be deleted.
delete_from_agents.discard(agent_id)
continue
else:
# This agent has a retention setting
# where days is set to a number,
# so that setting should be used.
days = agent_days
if backup_date + timedelta(days=days) >= now:
# This backup is not older than the retention days,
# so this agent should not be deleted.
delete_from_agents.discard(agent_id)
filtered_backup = replace(
backup,
agents={
agent_id: agent_backup_status
for agent_id, agent_backup_status in backup.agents.items()
if agent_id in delete_from_agents
},
)
backups_to_delete[backup_id] = filtered_backup
return backups_to_delete
await manager.async_delete_filtered_backups(
include_filter=_automatic_backups_filter, delete_filter=_delete_filter
@@ -312,6 +444,10 @@ class RetentionParametersDict(TypedDict, total=False):
days: int | None
class AgentRetentionConfig(BaseRetentionConfig):
"""Represent an agent retention configuration."""
class StoredBackupSchedule(TypedDict):
"""Represent the stored backup schedule configuration."""
@@ -554,16 +690,87 @@ async def delete_backups_exceeding_configured_count(manager: BackupManager) -> N
backups: dict[str, ManagerBackup],
) -> dict[str, ManagerBackup]:
"""Return oldest backups more numerous than copies to delete."""
agents_retention = {
agent_id: agent_config.retention
for agent_id, agent_config in manager.config.data.agents.items()
}
has_agents_retention = any(
agent_retention for agent_retention in agents_retention.values()
)
has_agents_retention_copies = any(
agent_retention and agent_retention.copies is not None
for agent_retention in agents_retention.values()
)
# we need to check here since we await before
# this filter is applied
if manager.config.data.retention.copies is None:
if (
global_copies := manager.config.data.retention.copies
) is None and not has_agents_retention_copies:
# No global retention copies and no agent retention copies
return {}
return dict(
sorted(
backups.items(),
key=lambda backup_item: backup_item[1].date,
)[: max(len(backups) - manager.config.data.retention.copies, 0)]
if global_copies is not None and not has_agents_retention:
# Return early to avoid the longer filtering below.
return dict(
sorted(
backups.items(),
key=lambda backup_item: backup_item[1].date,
)[: max(len(backups) - global_copies, 0)]
)
backups_by_agent: dict[str, dict[str, ManagerBackup]] = defaultdict(dict)
for backup_id, backup in backups.items():
for agent_id in backup.agents:
backups_by_agent[agent_id][backup_id] = backup
backups_to_delete_by_agent: dict[str, dict[str, ManagerBackup]] = defaultdict(
dict
)
for agent_id, agent_backups in backups_by_agent.items():
agent_retention = agents_retention.get(agent_id)
if agent_retention is None:
# This agent does not have a retention setting,
# so the global retention setting should be used.
if global_copies is None:
# This agent does not have a retention setting
# and the global retention copies setting is None,
# so backups should not be deleted.
continue
# The global retention setting will be used.
copies = global_copies
elif (agent_copies := agent_retention.copies) is None:
# This agent has a retention setting
# where copies is set to None,
# so backups should not be deleted.
continue
else:
# This agent retention setting will be used.
copies = agent_copies
backups_to_delete_by_agent[agent_id] = dict(
sorted(
agent_backups.items(),
key=lambda backup_item: backup_item[1].date,
)[: max(len(agent_backups) - copies, 0)]
)
backup_ids_to_delete: dict[str, set[str]] = defaultdict(set)
for agent_id, to_delete in backups_to_delete_by_agent.items():
for backup_id in to_delete:
backup_ids_to_delete[backup_id].add(agent_id)
backups_to_delete: dict[str, ManagerBackup] = {}
for backup_id, agent_ids in backup_ids_to_delete.items():
backup = backups[backup_id]
# filter the backup to only include the agents that should be deleted
filtered_backup = replace(
backup,
agents={
agent_id: agent_backup_status
for agent_id, agent_backup_status in backup.agents.items()
if agent_id in agent_ids
},
)
backups_to_delete[backup_id] = filtered_backup
return backups_to_delete
await manager.async_delete_filtered_backups(
include_filter=_automatic_backups_filter, delete_filter=_delete_filter

View File

@@ -0,0 +1,136 @@
"""Backup onboarding views."""
from __future__ import annotations
from collections.abc import Callable, Coroutine
from functools import wraps
from http import HTTPStatus
from typing import TYPE_CHECKING, Any, Concatenate
from aiohttp import web
from aiohttp.web_exceptions import HTTPUnauthorized
import voluptuous as vol
from homeassistant.components.http import KEY_HASS
from homeassistant.components.http.data_validator import RequestDataValidator
from homeassistant.components.onboarding import (
BaseOnboardingView,
NoAuthBaseOnboardingView,
)
from homeassistant.core import HomeAssistant
from homeassistant.exceptions import HomeAssistantError
from homeassistant.helpers.backup import async_get_manager as async_get_backup_manager
from . import BackupManager, Folder, IncorrectPasswordError, http as backup_http
if TYPE_CHECKING:
from homeassistant.components.onboarding import OnboardingStoreData
async def async_setup_views(hass: HomeAssistant, data: OnboardingStoreData) -> None:
"""Set up the backup views."""
hass.http.register_view(BackupInfoView(data))
hass.http.register_view(RestoreBackupView(data))
hass.http.register_view(UploadBackupView(data))
def with_backup_manager[_ViewT: BaseOnboardingView, **_P](
func: Callable[
Concatenate[_ViewT, BackupManager, web.Request, _P],
Coroutine[Any, Any, web.Response],
],
) -> Callable[Concatenate[_ViewT, web.Request, _P], Coroutine[Any, Any, web.Response]]:
"""Home Assistant API decorator to check onboarding and inject manager."""
@wraps(func)
async def with_backup(
self: _ViewT,
request: web.Request,
*args: _P.args,
**kwargs: _P.kwargs,
) -> web.Response:
"""Check admin and call function."""
if self._data["done"]:
raise HTTPUnauthorized
manager = await async_get_backup_manager(request.app[KEY_HASS])
return await func(self, manager, request, *args, **kwargs)
return with_backup
class BackupInfoView(NoAuthBaseOnboardingView):
"""Get backup info view."""
url = "/api/onboarding/backup/info"
name = "api:onboarding:backup:info"
@with_backup_manager
async def get(self, manager: BackupManager, request: web.Request) -> web.Response:
"""Return backup info."""
backups, _ = await manager.async_get_backups()
return self.json(
{
"backups": list(backups.values()),
"state": manager.state,
"last_action_event": manager.last_action_event,
}
)
class RestoreBackupView(NoAuthBaseOnboardingView):
"""Restore backup view."""
url = "/api/onboarding/backup/restore"
name = "api:onboarding:backup:restore"
@RequestDataValidator(
vol.Schema(
{
vol.Required("backup_id"): str,
vol.Required("agent_id"): str,
vol.Optional("password"): str,
vol.Optional("restore_addons"): [str],
vol.Optional("restore_database", default=True): bool,
vol.Optional("restore_folders"): [vol.Coerce(Folder)],
}
)
)
@with_backup_manager
async def post(
self, manager: BackupManager, request: web.Request, data: dict[str, Any]
) -> web.Response:
"""Restore a backup."""
try:
await manager.async_restore_backup(
data["backup_id"],
agent_id=data["agent_id"],
password=data.get("password"),
restore_addons=data.get("restore_addons"),
restore_database=data["restore_database"],
restore_folders=data.get("restore_folders"),
restore_homeassistant=True,
)
except IncorrectPasswordError:
return self.json(
{"code": "incorrect_password"}, status_code=HTTPStatus.BAD_REQUEST
)
except HomeAssistantError as err:
return self.json(
{"code": "restore_failed", "message": str(err)},
status_code=HTTPStatus.BAD_REQUEST,
)
return web.Response(status=HTTPStatus.OK)
class UploadBackupView(NoAuthBaseOnboardingView, backup_http.UploadBackupView):
"""Upload backup view."""
url = "/api/onboarding/backup/upload"
name = "api:onboarding:backup:upload"
@with_backup_manager
async def post(self, manager: BackupManager, request: web.Request) -> web.Response:
"""Upload a backup file."""
return await self._post(request)

View File

@@ -16,7 +16,7 @@ if TYPE_CHECKING:
STORE_DELAY_SAVE = 30
STORAGE_KEY = DOMAIN
STORAGE_VERSION = 1
STORAGE_VERSION_MINOR = 5
STORAGE_VERSION_MINOR = 6
class StoredBackupData(TypedDict):
@@ -72,6 +72,10 @@ class _BackupStore(Store[StoredBackupData]):
data["config"]["automatic_backups_configured"] = (
data["config"]["create_backup"]["password"] is not None
)
if old_minor_version < 6:
# Version 1.6 adds agent retention settings
for agent in data["config"]["agents"]:
data["config"]["agents"][agent]["retention"] = None
# Note: We allow reading data with major version 2.
# Reject if major version is higher than 2.

View File

@@ -346,7 +346,28 @@ async def handle_config_info(
@websocket_api.websocket_command(
{
vol.Required("type"): "backup/config/update",
vol.Optional("agents"): vol.Schema({str: {"protected": bool}}),
vol.Optional("agents"): vol.Schema(
{
str: {
vol.Optional("protected"): bool,
vol.Optional("retention"): vol.Any(
vol.Schema(
{
# Note: We can't use cv.positive_int because it allows 0 even
# though 0 is not positive.
vol.Optional("copies"): vol.Any(
vol.All(int, vol.Range(min=1)), None
),
vol.Optional("days"): vol.Any(
vol.All(int, vol.Range(min=1)), None
),
},
),
None,
),
}
}
),
vol.Optional("automatic_backups_configured"): bool,
vol.Optional("create_backup"): vol.Schema(
{

View File

@@ -31,7 +31,7 @@
"state_attributes": {
"preset_mode": {
"state": {
"auto": "[%key:component::climate::entity_component::_::state_attributes::fan_mode::state::auto%]"
"auto": "[%key:common::state::auto%]"
}
}
}

View File

@@ -30,7 +30,7 @@
"available": "Available",
"charging": "[%key:common::state::charging%]",
"unavailable": "Unavailable",
"error": "Error",
"error": "[%key:common::state::error%]",
"offline": "Offline"
}
},
@@ -41,7 +41,7 @@
"vehicle_detected": "Detected",
"ready": "Ready",
"no_power": "No power",
"vehicle_error": "Error"
"vehicle_error": "[%key:common::state::error%]"
}
},
"actual_v1": {

View File

@@ -12,5 +12,5 @@
"dependencies": ["bluetooth_adapters"],
"documentation": "https://www.home-assistant.io/integrations/bluemaestro",
"iot_class": "local_push",
"requirements": ["bluemaestro-ble==0.2.3"]
"requirements": ["bluemaestro-ble==0.3.0"]
}

View File

@@ -6,7 +6,7 @@
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/bluesound",
"iot_class": "local_polling",
"requirements": ["pyblu==2.0.0"],
"requirements": ["pyblu==2.0.1"],
"zeroconf": [
{
"type": "_musc._tcp.local."

View File

@@ -330,7 +330,12 @@ class BluesoundPlayer(CoordinatorEntity[BluesoundCoordinator], MediaPlayerEntity
if self._status.input_id is not None:
for input_ in self._inputs:
if input_.id == self._status.input_id:
# the input might not have an id => also try to match on the stream_url/url
# we have to use both because neither matches all the time
if (
input_.id == self._status.input_id
or input_.url == self._status.stream_url
):
return input_.text
for preset in self._presets:

View File

@@ -19,8 +19,8 @@
"bleak-retry-connector==3.9.0",
"bluetooth-adapters==0.21.4",
"bluetooth-auto-recovery==1.4.5",
"bluetooth-data-tools==1.27.0",
"bluetooth-data-tools==1.28.1",
"dbus-fast==2.43.0",
"habluetooth==3.37.0"
"habluetooth==3.45.0"
]
}

View File

@@ -374,6 +374,27 @@ class PassiveBluetoothProcessorCoordinator[_DataT](BasePassiveBluetoothCoordinat
self.logger.exception("Unexpected error updating %s data", self.name)
return
self._process_update(update, was_available)
@callback
def async_set_updated_data(self, update: _DataT) -> None:
"""Manually update the processor with new data.
If the data comes in via a different method, like a
notification, this method can be used to update the
processor with the new data.
This is useful for devices that retrieve
some of their data via notifications.
"""
was_available = self._available
self._available = True
self._process_update(update, was_available)
def _process_update(
self, update: _DataT, was_available: bool | None = None
) -> None:
"""Process the update from the bluetooth device."""
if not self.last_update_success:
self.last_update_success = True
self.logger.info("Coordinator %s recovered", self.name)

View File

@@ -2,7 +2,7 @@
from __future__ import annotations
from bluetooth_adapters import (
from habluetooth import (
DiscoveredDeviceAdvertisementData,
DiscoveredDeviceAdvertisementDataDict,
DiscoveryStorageType,

View File

@@ -139,7 +139,7 @@
"state": {
"default": "Default",
"charging": "[%key:common::state::charging%]",
"error": "Error",
"error": "[%key:common::state::error%]",
"complete": "Complete",
"fully_charged": "Fully charged",
"finished_fully_charged": "Finished, fully charged",

View File

@@ -12,6 +12,7 @@ from buienradar.constants import (
CONDITION,
CONTENT,
DATA,
FEELTEMPERATURE,
FORECAST,
HUMIDITY,
MESSAGE,
@@ -22,6 +23,7 @@ from buienradar.constants import (
TEMPERATURE,
VISIBILITY,
WINDAZIMUTH,
WINDGUST,
WINDSPEED,
)
from buienradar.urls import JSON_FEED_URL, json_precipitation_forecast_url
@@ -200,6 +202,14 @@ class BrData:
except (ValueError, TypeError):
return None
@property
def feeltemperature(self):
"""Return the feeltemperature, or None."""
try:
return float(self.data.get(FEELTEMPERATURE))
except (ValueError, TypeError):
return None
@property
def pressure(self):
"""Return the pressure, or None."""
@@ -224,6 +234,14 @@ class BrData:
except (ValueError, TypeError):
return None
@property
def wind_gust(self):
"""Return the windgust, or None."""
try:
return float(self.data.get(WINDGUST))
except (ValueError, TypeError):
return None
@property
def wind_speed(self):
"""Return the windspeed, or None."""

View File

@@ -9,6 +9,7 @@ from buienradar.constants import (
MAX_TEMP,
MIN_TEMP,
RAIN,
RAIN_CHANCE,
WINDAZIMUTH,
WINDSPEED,
)
@@ -33,6 +34,7 @@ from homeassistant.components.weather import (
ATTR_FORECAST_NATIVE_TEMP,
ATTR_FORECAST_NATIVE_TEMP_LOW,
ATTR_FORECAST_NATIVE_WIND_SPEED,
ATTR_FORECAST_PRECIPITATION_PROBABILITY,
ATTR_FORECAST_TIME,
ATTR_FORECAST_WIND_BEARING,
Forecast,
@@ -153,7 +155,9 @@ class BrWeather(WeatherEntity):
)
self._attr_native_pressure = data.pressure
self._attr_native_temperature = data.temperature
self._attr_native_apparent_temperature = data.feeltemperature
self._attr_native_visibility = data.visibility
self._attr_native_wind_gust_speed = data.wind_gust
self._attr_native_wind_speed = data.wind_speed
self._attr_wind_bearing = data.wind_bearing
@@ -188,6 +192,7 @@ class BrWeather(WeatherEntity):
ATTR_FORECAST_NATIVE_TEMP_LOW: data_in.get(MIN_TEMP),
ATTR_FORECAST_NATIVE_TEMP: data_in.get(MAX_TEMP),
ATTR_FORECAST_NATIVE_PRECIPITATION: data_in.get(RAIN),
ATTR_FORECAST_PRECIPITATION_PROBABILITY: data_in.get(RAIN_CHANCE),
ATTR_FORECAST_WIND_BEARING: data_in.get(WINDAZIMUTH),
ATTR_FORECAST_NATIVE_WIND_SPEED: data_in.get(WINDSPEED),
}

View File

@@ -8,46 +8,18 @@ from typing import Final
from canary.api import Api
from requests.exceptions import ConnectTimeout, HTTPError
import voluptuous as vol
from homeassistant.components.camera import DOMAIN as CAMERA_DOMAIN
from homeassistant.config_entries import SOURCE_IMPORT
from homeassistant.const import CONF_PASSWORD, CONF_TIMEOUT, CONF_USERNAME, Platform
from homeassistant.core import HomeAssistant
from homeassistant.exceptions import ConfigEntryNotReady
from homeassistant.helpers import config_validation as cv
from homeassistant.helpers.typing import ConfigType
from .const import (
CONF_FFMPEG_ARGUMENTS,
DEFAULT_FFMPEG_ARGUMENTS,
DEFAULT_TIMEOUT,
DOMAIN,
)
from .const import CONF_FFMPEG_ARGUMENTS, DEFAULT_FFMPEG_ARGUMENTS, DEFAULT_TIMEOUT
from .coordinator import CanaryConfigEntry, CanaryDataUpdateCoordinator
_LOGGER: Final = logging.getLogger(__name__)
MIN_TIME_BETWEEN_UPDATES: Final = timedelta(seconds=30)
CONFIG_SCHEMA: Final = vol.Schema(
vol.All(
cv.deprecated(DOMAIN),
{
DOMAIN: vol.Schema(
{
vol.Required(CONF_USERNAME): cv.string,
vol.Required(CONF_PASSWORD): cv.string,
vol.Optional(
CONF_TIMEOUT, default=DEFAULT_TIMEOUT
): cv.positive_int,
}
)
},
),
extra=vol.ALLOW_EXTRA,
)
PLATFORMS: Final[list[Platform]] = [
Platform.ALARM_CONTROL_PANEL,
Platform.CAMERA,
@@ -55,37 +27,6 @@ PLATFORMS: Final[list[Platform]] = [
]
async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
"""Set up the Canary integration."""
if hass.config_entries.async_entries(DOMAIN):
return True
ffmpeg_arguments = DEFAULT_FFMPEG_ARGUMENTS
if CAMERA_DOMAIN in config:
camera_config = next(
(item for item in config[CAMERA_DOMAIN] if item["platform"] == DOMAIN),
None,
)
if camera_config:
ffmpeg_arguments = camera_config.get(
CONF_FFMPEG_ARGUMENTS, DEFAULT_FFMPEG_ARGUMENTS
)
if DOMAIN in config:
if ffmpeg_arguments != DEFAULT_FFMPEG_ARGUMENTS:
config[DOMAIN][CONF_FFMPEG_ARGUMENTS] = ffmpeg_arguments
hass.async_create_task(
hass.config_entries.flow.async_init(
DOMAIN,
context={"source": SOURCE_IMPORT},
data=config[DOMAIN],
)
)
return True
async def async_setup_entry(hass: HomeAssistant, entry: CanaryConfigEntry) -> bool:
"""Set up Canary from a config entry."""
if not entry.options:

View File

@@ -54,10 +54,6 @@ class CanaryConfigFlow(ConfigFlow, domain=DOMAIN):
"""Get the options flow for this handler."""
return CanaryOptionsFlowHandler()
async def async_step_import(self, import_data: dict[str, Any]) -> ConfigFlowResult:
"""Handle a flow initiated by configuration file."""
return await self.async_step_user(import_data)
async def async_step_user(
self, user_input: dict[str, Any] | None = None
) -> ConfigFlowResult:

View File

@@ -6,5 +6,5 @@
"documentation": "https://www.home-assistant.io/integrations/chacon_dio",
"iot_class": "cloud_push",
"loggers": ["dio_chacon_api"],
"requirements": ["dio-chacon-wifi-api==1.2.1"]
"requirements": ["dio-chacon-wifi-api==1.2.2"]
}

View File

@@ -28,10 +28,10 @@
"name": "Thermostat",
"state": {
"off": "[%key:common::state::off%]",
"auto": "[%key:common::state::auto%]",
"heat": "Heat",
"cool": "Cool",
"heat_cool": "Heat/Cool",
"auto": "Auto",
"dry": "Dry",
"fan_only": "Fan only"
},
@@ -50,10 +50,10 @@
"state": {
"off": "[%key:common::state::off%]",
"on": "[%key:common::state::on%]",
"auto": "Auto",
"low": "Low",
"medium": "Medium",
"high": "High",
"auto": "[%key:common::state::auto%]",
"low": "[%key:common::state::low%]",
"medium": "[%key:common::state::medium%]",
"high": "[%key:common::state::high%]",
"top": "Top",
"middle": "Middle",
"focus": "Focus",
@@ -69,13 +69,13 @@
"hvac_action": {
"name": "Current action",
"state": {
"off": "[%key:common::state::off%]",
"idle": "[%key:common::state::idle%]",
"cooling": "Cooling",
"defrosting": "Defrosting",
"drying": "Drying",
"fan": "Fan",
"heating": "Heating",
"idle": "[%key:common::state::idle%]",
"off": "[%key:common::state::off%]",
"preheating": "Preheating"
}
},
@@ -258,7 +258,7 @@
"hvac_mode": {
"options": {
"off": "[%key:common::state::off%]",
"auto": "Auto",
"auto": "[%key:common::state::auto%]",
"cool": "Cool",
"dry": "Dry",
"fan_only": "Fan only",

View File

@@ -93,3 +93,5 @@ STT_ENTITY_UNIQUE_ID = "cloud-speech-to-text"
TTS_ENTITY_UNIQUE_ID = "cloud-text-to-speech"
LOGIN_MFA_TIMEOUT = 60
VOICE_STYLE_SEPERATOR = "||"

View File

@@ -18,7 +18,7 @@ from aiohttp import web
import attr
from hass_nabucasa import AlreadyConnectedError, Cloud, auth, thingtalk
from hass_nabucasa.const import STATE_DISCONNECTED
from hass_nabucasa.voice import TTS_VOICES
from hass_nabucasa.voice_data import TTS_VOICES
import voluptuous as vol
from homeassistant.components import websocket_api
@@ -57,6 +57,7 @@ from .const import (
PREF_REMOTE_ALLOW_REMOTE_ENABLE,
PREF_TTS_DEFAULT_VOICE,
REQUEST_TIMEOUT,
VOICE_STYLE_SEPERATOR,
)
from .google_config import CLOUD_GOOGLE
from .repairs import async_manage_legacy_subscription_issue
@@ -591,10 +592,21 @@ async def websocket_subscription(
def validate_language_voice(value: tuple[str, str]) -> tuple[str, str]:
"""Validate language and voice."""
language, voice = value
style: str | None
voice, _, style = voice.partition(VOICE_STYLE_SEPERATOR)
if not style:
style = None
if language not in TTS_VOICES:
raise vol.Invalid(f"Invalid language {language}")
if voice not in TTS_VOICES[language]:
if voice not in (language_info := TTS_VOICES[language]):
raise vol.Invalid(f"Invalid voice {voice} for language {language}")
voice_info = language_info[voice]
if style and (
isinstance(voice_info, str) or style not in voice_info.get("variants", [])
):
raise vol.Invalid(
f"Invalid style {style} for voice {voice} in language {language}"
)
return value
@@ -1012,13 +1024,24 @@ def tts_info(
msg: dict[str, Any],
) -> None:
"""Fetch available tts info."""
connection.send_result(
msg["id"],
{
"languages": [
(language, voice)
for language, voices in TTS_VOICES.items()
for voice in voices
]
},
)
result = []
for language, voices in TTS_VOICES.items():
for voice_id, voice_info in voices.items():
if isinstance(voice_info, str):
result.append((language, voice_id, voice_info))
continue
name = voice_info["name"]
result.append((language, voice_id, name))
result.extend(
[
(
language,
f"{voice_id}{VOICE_STYLE_SEPERATOR}{variant}",
f"{name} ({variant})",
)
for variant in voice_info.get("variants", [])
]
)
connection.send_result(msg["id"], {"languages": result})

View File

@@ -13,6 +13,6 @@
"integration_type": "system",
"iot_class": "cloud_push",
"loggers": ["acme", "hass_nabucasa", "snitun"],
"requirements": ["hass-nabucasa==0.94.0"],
"requirements": ["hass-nabucasa==0.96.0"],
"single_config_entry": true
}

View File

@@ -0,0 +1,110 @@
"""Cloud onboarding views."""
from __future__ import annotations
from collections.abc import Callable, Coroutine
from functools import wraps
from typing import TYPE_CHECKING, Any, Concatenate
from aiohttp import web
from aiohttp.web_exceptions import HTTPUnauthorized
from homeassistant.components.http import KEY_HASS
from homeassistant.components.onboarding import (
BaseOnboardingView,
NoAuthBaseOnboardingView,
)
from homeassistant.core import HomeAssistant
from . import http_api as cloud_http
from .const import DATA_CLOUD
if TYPE_CHECKING:
from homeassistant.components.onboarding import OnboardingStoreData
async def async_setup_views(hass: HomeAssistant, data: OnboardingStoreData) -> None:
"""Set up the cloud views."""
hass.http.register_view(CloudForgotPasswordView(data))
hass.http.register_view(CloudLoginView(data))
hass.http.register_view(CloudLogoutView(data))
hass.http.register_view(CloudStatusView(data))
def ensure_not_done[_ViewT: BaseOnboardingView, **_P](
func: Callable[
Concatenate[_ViewT, web.Request, _P],
Coroutine[Any, Any, web.Response],
],
) -> Callable[Concatenate[_ViewT, web.Request, _P], Coroutine[Any, Any, web.Response]]:
"""Home Assistant API decorator to check onboarding and cloud."""
@wraps(func)
async def _ensure_not_done(
self: _ViewT,
request: web.Request,
*args: _P.args,
**kwargs: _P.kwargs,
) -> web.Response:
"""Check onboarding status, cloud and call function."""
if self._data["done"]:
# If at least one onboarding step is done, we don't allow accessing
# the cloud onboarding views.
raise HTTPUnauthorized
return await func(self, request, *args, **kwargs)
return _ensure_not_done
class CloudForgotPasswordView(
NoAuthBaseOnboardingView, cloud_http.CloudForgotPasswordView
):
"""View to start Forgot Password flow."""
url = "/api/onboarding/cloud/forgot_password"
name = "api:onboarding:cloud:forgot_password"
@ensure_not_done
async def post(self, request: web.Request) -> web.Response:
"""Handle forgot password request."""
return await super()._post(request)
class CloudLoginView(NoAuthBaseOnboardingView, cloud_http.CloudLoginView):
"""Login to Home Assistant Cloud."""
url = "/api/onboarding/cloud/login"
name = "api:onboarding:cloud:login"
@ensure_not_done
async def post(self, request: web.Request) -> web.Response:
"""Handle login request."""
return await super()._post(request)
class CloudLogoutView(NoAuthBaseOnboardingView, cloud_http.CloudLogoutView):
"""Log out of the Home Assistant cloud."""
url = "/api/onboarding/cloud/logout"
name = "api:onboarding:cloud:logout"
@ensure_not_done
async def post(self, request: web.Request) -> web.Response:
"""Handle logout request."""
return await super()._post(request)
class CloudStatusView(NoAuthBaseOnboardingView):
"""Get cloud status view."""
url = "/api/onboarding/cloud/status"
name = "api:onboarding:cloud:status"
@ensure_not_done
async def get(self, request: web.Request) -> web.Response:
"""Return cloud status."""
hass = request.app[KEY_HASS]
cloud = hass.data[DATA_CLOUD]
return self.json({"logged_in": cloud.is_logged_in})

View File

@@ -6,7 +6,8 @@ import logging
from typing import Any
from hass_nabucasa import Cloud
from hass_nabucasa.voice import MAP_VOICE, TTS_VOICES, AudioOutput, Gender, VoiceError
from hass_nabucasa.voice import MAP_VOICE, AudioOutput, Gender, VoiceError
from hass_nabucasa.voice_data import TTS_VOICES
import voluptuous as vol
from homeassistant.components.tts import (
@@ -30,7 +31,13 @@ from homeassistant.setup import async_when_setup
from .assist_pipeline import async_migrate_cloud_pipeline_engine
from .client import CloudClient
from .const import DATA_CLOUD, DATA_PLATFORMS_SETUP, DOMAIN, TTS_ENTITY_UNIQUE_ID
from .const import (
DATA_CLOUD,
DATA_PLATFORMS_SETUP,
DOMAIN,
TTS_ENTITY_UNIQUE_ID,
VOICE_STYLE_SEPERATOR,
)
from .prefs import CloudPreferences
ATTR_GENDER = "gender"
@@ -57,6 +64,7 @@ DEFAULT_VOICES = {
"ar-SY": "AmanyNeural",
"ar-TN": "ReemNeural",
"ar-YE": "MaryamNeural",
"as-IN": "PriyomNeural",
"az-AZ": "BabekNeural",
"bg-BG": "KalinaNeural",
"bn-BD": "NabanitaNeural",
@@ -126,6 +134,8 @@ DEFAULT_VOICES = {
"id-ID": "GadisNeural",
"is-IS": "GudrunNeural",
"it-IT": "ElsaNeural",
"iu-Cans-CA": "SiqiniqNeural",
"iu-Latn-CA": "SiqiniqNeural",
"ja-JP": "NanamiNeural",
"jv-ID": "SitiNeural",
"ka-GE": "EkaNeural",
@@ -147,6 +157,8 @@ DEFAULT_VOICES = {
"ne-NP": "HemkalaNeural",
"nl-BE": "DenaNeural",
"nl-NL": "ColetteNeural",
"or-IN": "SubhasiniNeural",
"pa-IN": "OjasNeural",
"pl-PL": "AgnieszkaNeural",
"ps-AF": "LatifaNeural",
"pt-BR": "FranciscaNeural",
@@ -158,6 +170,7 @@ DEFAULT_VOICES = {
"sl-SI": "PetraNeural",
"so-SO": "UbaxNeural",
"sq-AL": "AnilaNeural",
"sr-Latn-RS": "NicholasNeural",
"sr-RS": "SophieNeural",
"su-ID": "TutiNeural",
"sv-SE": "SofieNeural",
@@ -177,12 +190,9 @@ DEFAULT_VOICES = {
"vi-VN": "HoaiMyNeural",
"wuu-CN": "XiaotongNeural",
"yue-CN": "XiaoMinNeural",
"zh-CN": "XiaoxiaoNeural",
"zh-CN-henan": "YundengNeural",
"zh-CN-liaoning": "XiaobeiNeural",
"zh-CN-shaanxi": "XiaoniNeural",
"zh-CN-shandong": "YunxiangNeural",
"zh-CN-sichuan": "YunxiNeural",
"zh-CN": "XiaoxiaoNeural",
"zh-HK": "HiuMaanNeural",
"zh-TW": "HsiaoChenNeural",
"zu-ZA": "ThandoNeural",
@@ -191,6 +201,39 @@ DEFAULT_VOICES = {
_LOGGER = logging.getLogger(__name__)
@callback
def _prepare_voice_args(
*,
hass: HomeAssistant,
language: str,
voice: str,
gender: str | None,
) -> dict:
"""Prepare voice arguments."""
gender = handle_deprecated_gender(hass, gender)
style: str | None
original_voice, _, style = voice.partition(VOICE_STYLE_SEPERATOR)
if not style:
style = None
updated_voice = handle_deprecated_voice(hass, original_voice)
if updated_voice not in TTS_VOICES[language]:
default_voice = DEFAULT_VOICES[language]
_LOGGER.debug(
"Unsupported voice %s detected, falling back to default %s for %s",
voice,
default_voice,
language,
)
updated_voice = default_voice
return {
"language": language,
"voice": updated_voice,
"gender": gender,
"style": style,
}
def _deprecated_platform(value: str) -> str:
"""Validate if platform is deprecated."""
if value == DOMAIN:
@@ -328,36 +371,59 @@ class CloudTTSEntity(TextToSpeechEntity):
"""Return a list of supported voices for a language."""
if not (voices := TTS_VOICES.get(language)):
return None
return [Voice(voice, voice) for voice in voices]
result = []
for voice_id, voice_info in voices.items():
if isinstance(voice_info, str):
result.append(
Voice(
voice_id,
voice_info,
)
)
continue
name = voice_info["name"]
result.append(
Voice(
voice_id,
name,
)
)
result.extend(
[
Voice(
f"{voice_id}{VOICE_STYLE_SEPERATOR}{variant}",
f"{name} ({variant})",
)
for variant in voice_info.get("variants", [])
]
)
return result
async def async_get_tts_audio(
self, message: str, language: str, options: dict[str, Any]
) -> TtsAudioType:
"""Load TTS from Home Assistant Cloud."""
gender: Gender | str | None = options.get(ATTR_GENDER)
gender = handle_deprecated_gender(self.hass, gender)
original_voice: str = options.get(
ATTR_VOICE,
self._voice if language == self._language else DEFAULT_VOICES[language],
)
voice = handle_deprecated_voice(self.hass, original_voice)
if voice not in TTS_VOICES[language]:
default_voice = DEFAULT_VOICES[language]
_LOGGER.debug(
"Unsupported voice %s detected, falling back to default %s for %s",
voice,
default_voice,
language,
)
voice = default_voice
# Process TTS
try:
data = await self.cloud.voice.process_tts(
text=message,
language=language,
gender=gender,
voice=voice,
output=options[ATTR_AUDIO_OUTPUT],
**_prepare_voice_args(
hass=self.hass,
language=language,
voice=options.get(
ATTR_VOICE,
self._voice
if language == self._language
else DEFAULT_VOICES[language],
),
gender=options.get(ATTR_GENDER),
),
)
except VoiceError as err:
_LOGGER.error("Voice error: %s", err)
@@ -401,7 +467,38 @@ class CloudProvider(Provider):
"""Return a list of supported voices for a language."""
if not (voices := TTS_VOICES.get(language)):
return None
return [Voice(voice, voice) for voice in voices]
result = []
for voice_id, voice_info in voices.items():
if isinstance(voice_info, str):
result.append(
Voice(
voice_id,
voice_info,
)
)
continue
name = voice_info["name"]
result.append(
Voice(
voice_id,
name,
)
)
result.extend(
[
Voice(
f"{voice_id}{VOICE_STYLE_SEPERATOR}{variant}",
f"{name} ({variant})",
)
for variant in voice_info.get("variants", [])
]
)
return result
@property
def default_options(self) -> dict[str, str]:
@@ -415,30 +512,22 @@ class CloudProvider(Provider):
) -> TtsAudioType:
"""Load TTS from Home Assistant Cloud."""
assert self.hass is not None
gender: Gender | str | None = options.get(ATTR_GENDER)
gender = handle_deprecated_gender(self.hass, gender)
original_voice: str = options.get(
ATTR_VOICE,
self._voice if language == self._language else DEFAULT_VOICES[language],
)
voice = handle_deprecated_voice(self.hass, original_voice)
if voice not in TTS_VOICES[language]:
default_voice = DEFAULT_VOICES[language]
_LOGGER.debug(
"Unsupported voice %s detected, falling back to default %s for %s",
voice,
default_voice,
language,
)
voice = default_voice
# Process TTS
try:
data = await self.cloud.voice.process_tts(
text=message,
language=language,
gender=gender,
voice=voice,
output=options[ATTR_AUDIO_OUTPUT],
**_prepare_voice_args(
hass=self.hass,
language=language,
voice=options.get(
ATTR_VOICE,
self._voice
if language == self._language
else DEFAULT_VOICES[language],
),
gender=options.get(ATTR_GENDER),
),
)
except VoiceError as err:
_LOGGER.error("Voice error: %s", err)

View File

@@ -12,6 +12,7 @@ from .coordinator import (
ComelitSerialBridge,
ComelitVedoSystem,
)
from .utils import async_client_session
BRIDGE_PLATFORMS = [
Platform.CLIMATE,
@@ -32,6 +33,9 @@ async def async_setup_entry(hass: HomeAssistant, entry: ComelitConfigEntry) -> b
"""Set up Comelit platform."""
coordinator: ComelitBaseCoordinator
session = await async_client_session(hass)
if entry.data.get(CONF_TYPE, BRIDGE) == BRIDGE:
coordinator = ComelitSerialBridge(
hass,
@@ -39,6 +43,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ComelitConfigEntry) -> b
entry.data[CONF_HOST],
entry.data.get(CONF_PORT, DEFAULT_PORT),
entry.data[CONF_PIN],
session,
)
platforms = BRIDGE_PLATFORMS
else:
@@ -48,6 +53,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ComelitConfigEntry) -> b
entry.data[CONF_HOST],
entry.data.get(CONF_PORT, DEFAULT_PORT),
entry.data[CONF_PIN],
session,
)
platforms = VEDO_PLATFORMS

View File

@@ -83,7 +83,6 @@ class ComelitAlarmEntity(CoordinatorEntity[ComelitVedoSystem], AlarmControlPanel
config_entry_entry_id: str,
) -> None:
"""Initialize the alarm panel."""
self._api = coordinator.api
self._area_index = area.index
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
@@ -137,30 +136,38 @@ class ComelitAlarmEntity(CoordinatorEntity[ComelitVedoSystem], AlarmControlPanel
async def async_alarm_disarm(self, code: str | None = None) -> None:
"""Send disarm command."""
if code != str(self._api.device_pin):
if code != str(self.coordinator.api.device_pin):
return
await self._api.set_zone_status(self._area.index, ALARM_ACTIONS[DISABLE])
await self.coordinator.api.set_zone_status(
self._area.index, ALARM_ACTIONS[DISABLE]
)
await self._async_update_state(
AlarmAreaState.DISARMED, ALARM_AREA_ARMED_STATUS[DISABLE]
)
async def async_alarm_arm_away(self, code: str | None = None) -> None:
"""Send arm away command."""
await self._api.set_zone_status(self._area.index, ALARM_ACTIONS[AWAY])
await self.coordinator.api.set_zone_status(
self._area.index, ALARM_ACTIONS[AWAY]
)
await self._async_update_state(
AlarmAreaState.ARMED, ALARM_AREA_ARMED_STATUS[AWAY]
)
async def async_alarm_arm_home(self, code: str | None = None) -> None:
"""Send arm home command."""
await self._api.set_zone_status(self._area.index, ALARM_ACTIONS[HOME])
await self.coordinator.api.set_zone_status(
self._area.index, ALARM_ACTIONS[HOME]
)
await self._async_update_state(
AlarmAreaState.ARMED, ALARM_AREA_ARMED_STATUS[HOME_P1]
)
async def async_alarm_arm_night(self, code: str | None = None) -> None:
"""Send arm night command."""
await self._api.set_zone_status(self._area.index, ALARM_ACTIONS[NIGHT])
await self.coordinator.api.set_zone_status(
self._area.index, ALARM_ACTIONS[NIGHT]
)
await self._async_update_state(
AlarmAreaState.ARMED, ALARM_AREA_ARMED_STATUS[NIGHT]
)

View File

@@ -50,7 +50,6 @@ class ComelitVedoBinarySensorEntity(
config_entry_entry_id: str,
) -> None:
"""Init sensor entity."""
self._api = coordinator.api
self._zone_index = zone.index
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id

View File

@@ -19,10 +19,10 @@ from homeassistant.const import ATTR_TEMPERATURE, PRECISION_TENTHS
from homeassistant.core import HomeAssistant, callback
from homeassistant.exceptions import HomeAssistantError
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .const import DOMAIN
from .coordinator import ComelitConfigEntry, ComelitSerialBridge
from .entity import ComelitBridgeBaseEntity
# Coordinator is used to centralize the data updates
PARALLEL_UPDATES = 0
@@ -89,7 +89,7 @@ async def async_setup_entry(
)
class ComelitClimateEntity(CoordinatorEntity[ComelitSerialBridge], ClimateEntity):
class ComelitClimateEntity(ComelitBridgeBaseEntity, ClimateEntity):
"""Climate device."""
_attr_hvac_modes = [HVACMode.AUTO, HVACMode.COOL, HVACMode.HEAT, HVACMode.OFF]
@@ -102,7 +102,6 @@ class ComelitClimateEntity(CoordinatorEntity[ComelitSerialBridge], ClimateEntity
)
_attr_target_temperature_step = PRECISION_TENTHS
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_has_entity_name = True
_attr_name = None
def __init__(
@@ -112,13 +111,7 @@ class ComelitClimateEntity(CoordinatorEntity[ComelitSerialBridge], ClimateEntity
config_entry_entry_id: str,
) -> None:
"""Init light entity."""
self._api = coordinator.api
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
self._attr_unique_id = f"{config_entry_entry_id}-{device.index}"
self._attr_device_info = coordinator.platform_device_info(device, device.type)
super().__init__(coordinator, device, config_entry_entry_id)
self._update_attributes()
def _update_attributes(self) -> None:

View File

@@ -2,6 +2,7 @@
from __future__ import annotations
from asyncio.exceptions import TimeoutError
from collections.abc import Mapping
from typing import Any
@@ -21,6 +22,7 @@ from homeassistant.exceptions import HomeAssistantError
from homeassistant.helpers import config_validation as cv
from .const import _LOGGER, DEFAULT_PORT, DEVICE_TYPE_LIST, DOMAIN
from .utils import async_client_session
DEFAULT_HOST = "192.168.1.252"
DEFAULT_PIN = 111111
@@ -46,17 +48,29 @@ async def validate_input(hass: HomeAssistant, data: dict[str, Any]) -> dict[str,
"""Validate the user input allows us to connect."""
api: ComelitCommonApi
session = await async_client_session(hass)
if data.get(CONF_TYPE, BRIDGE) == BRIDGE:
api = ComeliteSerialBridgeApi(data[CONF_HOST], data[CONF_PORT], data[CONF_PIN])
api = ComeliteSerialBridgeApi(
data[CONF_HOST], data[CONF_PORT], data[CONF_PIN], session
)
else:
api = ComelitVedoApi(data[CONF_HOST], data[CONF_PORT], data[CONF_PIN])
api = ComelitVedoApi(data[CONF_HOST], data[CONF_PORT], data[CONF_PIN], session)
try:
await api.login()
except aiocomelit_exceptions.CannotConnect as err:
raise CannotConnect from err
except (aiocomelit_exceptions.CannotConnect, TimeoutError) as err:
raise CannotConnect(
translation_domain=DOMAIN,
translation_key="cannot_connect",
translation_placeholders={"error": repr(err)},
) from err
except aiocomelit_exceptions.CannotAuthenticate as err:
raise InvalidAuth from err
raise InvalidAuth(
translation_domain=DOMAIN,
translation_key="cannot_authenticate",
translation_placeholders={"error": repr(err)},
) from err
finally:
await api.logout()
await api.close()

View File

@@ -15,6 +15,7 @@ from aiocomelit.api import (
)
from aiocomelit.const import BRIDGE, VEDO
from aiocomelit.exceptions import CannotAuthenticate, CannotConnect, CannotRetrieveData
from aiohttp import ClientSession
from homeassistant.config_entries import ConfigEntry
from homeassistant.core import HomeAssistant
@@ -95,9 +96,16 @@ class ComelitBaseCoordinator(DataUpdateCoordinator[T]):
await self.api.login()
return await self._async_update_system_data()
except (CannotConnect, CannotRetrieveData) as err:
raise UpdateFailed(repr(err)) from err
raise UpdateFailed(
translation_domain=DOMAIN,
translation_key="update_failed",
translation_placeholders={"error": repr(err)},
) from err
except CannotAuthenticate as err:
raise ConfigEntryAuthFailed from err
raise ConfigEntryAuthFailed(
translation_domain=DOMAIN,
translation_key="cannot_authenticate",
) from err
@abstractmethod
async def _async_update_system_data(self) -> T:
@@ -119,9 +127,10 @@ class ComelitSerialBridge(
host: str,
port: int,
pin: int,
session: ClientSession,
) -> None:
"""Initialize the scanner."""
self.api = ComeliteSerialBridgeApi(host, port, pin)
self.api = ComeliteSerialBridgeApi(host, port, pin, session)
super().__init__(hass, entry, BRIDGE, host)
async def _async_update_system_data(
@@ -144,9 +153,10 @@ class ComelitVedoSystem(ComelitBaseCoordinator[AlarmDataObject]):
host: str,
port: int,
pin: int,
session: ClientSession,
) -> None:
"""Initialize the scanner."""
self.api = ComelitVedoApi(host, port, pin)
self.api = ComelitVedoApi(host, port, pin, session)
super().__init__(hass, entry, VEDO, host)
async def _async_update_system_data(

View File

@@ -11,9 +11,9 @@ from homeassistant.components.cover import CoverDeviceClass, CoverEntity, CoverS
from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
from homeassistant.helpers.restore_state import RestoreEntity
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .coordinator import ComelitConfigEntry, ComelitSerialBridge
from .entity import ComelitBridgeBaseEntity
# Coordinator is used to centralize the data updates
PARALLEL_UPDATES = 0
@@ -34,13 +34,10 @@ async def async_setup_entry(
)
class ComelitCoverEntity(
CoordinatorEntity[ComelitSerialBridge], RestoreEntity, CoverEntity
):
class ComelitCoverEntity(ComelitBridgeBaseEntity, RestoreEntity, CoverEntity):
"""Cover device."""
_attr_device_class = CoverDeviceClass.SHUTTER
_attr_has_entity_name = True
_attr_name = None
def __init__(
@@ -50,13 +47,7 @@ class ComelitCoverEntity(
config_entry_entry_id: str,
) -> None:
"""Init cover entity."""
self._api = coordinator.api
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
self._attr_unique_id = f"{config_entry_entry_id}-{device.index}"
self._attr_device_info = coordinator.platform_device_info(device, device.type)
super().__init__(coordinator, device, config_entry_entry_id)
# Device doesn't provide a status so we assume UNKNOWN at first startup
self._last_action: int | None = None
self._last_state: str | None = None
@@ -101,7 +92,7 @@ class ComelitCoverEntity(
async def _cover_set_state(self, action: int, state: int) -> None:
"""Set desired cover state."""
self._last_state = self.state
await self._api.set_device_status(COVER, self._device.index, action)
await self.coordinator.api.set_device_status(COVER, self._device.index, action)
self.coordinator.data[COVER][self._device.index].status = state
self.async_write_ha_state()

View File

@@ -0,0 +1,29 @@
"""Base entity for Comelit."""
from __future__ import annotations
from aiocomelit import ComelitSerialBridgeObject
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .coordinator import ComelitSerialBridge
class ComelitBridgeBaseEntity(CoordinatorEntity[ComelitSerialBridge]):
"""Comelit Bridge base entity."""
_attr_has_entity_name = True
def __init__(
self,
coordinator: ComelitSerialBridge,
device: ComelitSerialBridgeObject,
config_entry_entry_id: str,
) -> None:
"""Init cover entity."""
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
self._attr_unique_id = f"{config_entry_entry_id}-{device.index}"
self._attr_device_info = coordinator.platform_device_info(device, device.type)

View File

@@ -19,10 +19,10 @@ from homeassistant.components.humidifier import (
from homeassistant.core import HomeAssistant, callback
from homeassistant.exceptions import HomeAssistantError, ServiceValidationError
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .const import DOMAIN
from .coordinator import ComelitConfigEntry, ComelitSerialBridge
from .entity import ComelitBridgeBaseEntity
# Coordinator is used to centralize the data updates
PARALLEL_UPDATES = 0
@@ -92,14 +92,13 @@ async def async_setup_entry(
async_add_entities(entities)
class ComelitHumidifierEntity(CoordinatorEntity[ComelitSerialBridge], HumidifierEntity):
class ComelitHumidifierEntity(ComelitBridgeBaseEntity, HumidifierEntity):
"""Humidifier device."""
_attr_supported_features = HumidifierEntityFeature.MODES
_attr_available_modes = [MODE_NORMAL, MODE_AUTO]
_attr_min_humidity = 10
_attr_max_humidity = 90
_attr_has_entity_name = True
def __init__(
self,
@@ -112,13 +111,8 @@ class ComelitHumidifierEntity(CoordinatorEntity[ComelitSerialBridge], Humidifier
device_class: HumidifierDeviceClass,
) -> None:
"""Init light entity."""
self._api = coordinator.api
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
super().__init__(coordinator, device, config_entry_entry_id)
self._attr_unique_id = f"{config_entry_entry_id}-{device.index}-{device_class}"
self._attr_device_info = coordinator.platform_device_info(device, device_class)
self._attr_device_class = device_class
self._attr_translation_key = device_class.value
self._active_mode = active_mode

View File

@@ -4,15 +4,14 @@ from __future__ import annotations
from typing import Any, cast
from aiocomelit import ComelitSerialBridgeObject
from aiocomelit.const import LIGHT, STATE_OFF, STATE_ON
from homeassistant.components.light import ColorMode, LightEntity
from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .coordinator import ComelitConfigEntry, ComelitSerialBridge
from .entity import ComelitBridgeBaseEntity
# Coordinator is used to centralize the data updates
PARALLEL_UPDATES = 0
@@ -33,29 +32,13 @@ async def async_setup_entry(
)
class ComelitLightEntity(CoordinatorEntity[ComelitSerialBridge], LightEntity):
class ComelitLightEntity(ComelitBridgeBaseEntity, LightEntity):
"""Light device."""
_attr_color_mode = ColorMode.ONOFF
_attr_has_entity_name = True
_attr_name = None
_attr_supported_color_modes = {ColorMode.ONOFF}
def __init__(
self,
coordinator: ComelitSerialBridge,
device: ComelitSerialBridgeObject,
config_entry_entry_id: str,
) -> None:
"""Init light entity."""
self._api = coordinator.api
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
self._attr_unique_id = f"{config_entry_entry_id}-{device.index}"
self._attr_device_info = coordinator.platform_device_info(device, device.type)
async def _light_set_state(self, state: int) -> None:
"""Set desired light state."""
await self.coordinator.api.set_device_status(LIGHT, self._device.index, state)

View File

@@ -7,5 +7,6 @@
"integration_type": "hub",
"iot_class": "local_polling",
"loggers": ["aiocomelit"],
"requirements": ["aiocomelit==0.11.3"]
"quality_scale": "bronze",
"requirements": ["aiocomelit==0.12.0"]
}

View File

@@ -0,0 +1,88 @@
rules:
# Bronze
action-setup:
status: exempt
comment: no actions
appropriate-polling: done
brands: done
common-modules: done
config-flow-test-coverage: done
config-flow: done
dependency-transparency: done
docs-actions:
status: exempt
comment: no actions
docs-high-level-description: done
docs-installation-instructions: done
docs-removal-instructions: done
entity-event-setup:
status: exempt
comment: no events
entity-unique-id: done
has-entity-name: done
runtime-data: done
test-before-configure: done
test-before-setup: done
unique-config-entry: done
# Silver
action-exceptions:
status: todo
comment: wrap api calls in try block
config-entry-unloading: done
docs-configuration-parameters:
status: exempt
comment: no configuration parameters
docs-installation-parameters: done
entity-unavailable: done
integration-owner: done
log-when-unavailable: done
parallel-updates: done
reauthentication-flow: done
test-coverage: done
# Gold
devices: done
diagnostics: done
discovery-update-info:
status: exempt
comment: device not discoverable
discovery:
status: exempt
comment: device not discoverable
docs-data-update: done
docs-examples: done
docs-known-limitations:
status: exempt
comment: no known limitations, yet
docs-supported-devices:
status: todo
comment: review and complete missing ones
docs-supported-functions: todo
docs-troubleshooting: done
docs-use-cases: done
dynamic-devices:
status: todo
comment: missing implementation
entity-category:
status: todo
comment: PR in progress
entity-device-class: done
entity-disabled-by-default: done
entity-translations: done
exception-translations: done
icon-translations: done
reconfiguration-flow:
status: todo
comment: PR in progress
repair-issues:
status: exempt
comment: no known use cases for repair issues or flows, yet
stale-devices:
status: todo
comment: missing implementation
# Platinum
async-dependency: done
inject-websession: done
strict-typing: done

View File

@@ -19,6 +19,7 @@ from homeassistant.helpers.typing import StateType
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .coordinator import ComelitConfigEntry, ComelitSerialBridge, ComelitVedoSystem
from .entity import ComelitBridgeBaseEntity
# Coordinator is used to centralize the data updates
PARALLEL_UPDATES = 0
@@ -95,10 +96,9 @@ async def async_setup_vedo_entry(
async_add_entities(entities)
class ComelitBridgeSensorEntity(CoordinatorEntity[ComelitSerialBridge], SensorEntity):
class ComelitBridgeSensorEntity(ComelitBridgeBaseEntity, SensorEntity):
"""Sensor device."""
_attr_has_entity_name = True
_attr_name = None
def __init__(
@@ -109,13 +109,7 @@ class ComelitBridgeSensorEntity(CoordinatorEntity[ComelitSerialBridge], SensorEn
description: SensorEntityDescription,
) -> None:
"""Init sensor entity."""
self._api = coordinator.api
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
self._attr_unique_id = f"{config_entry_entry_id}-{device.index}"
self._attr_device_info = coordinator.platform_device_info(device, device.type)
super().__init__(coordinator, device, config_entry_entry_id)
self.entity_description = description
@@ -144,7 +138,6 @@ class ComelitVedoSensorEntity(CoordinatorEntity[ComelitVedoSystem], SensorEntity
description: SensorEntityDescription,
) -> None:
"""Init sensor entity."""
self._api = coordinator.api
self._zone_index = zone.index
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id

View File

@@ -69,6 +69,15 @@
},
"invalid_clima_data": {
"message": "Invalid 'clima' data"
},
"cannot_connect": {
"message": "Error connecting: {error}"
},
"cannot_authenticate": {
"message": "Error authenticating"
},
"updated_failed": {
"message": "Failed to update data: {error}"
}
}
}

View File

@@ -10,9 +10,9 @@ from aiocomelit.const import IRRIGATION, OTHER, STATE_OFF, STATE_ON
from homeassistant.components.switch import SwitchDeviceClass, SwitchEntity
from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .coordinator import ComelitConfigEntry, ComelitSerialBridge
from .entity import ComelitBridgeBaseEntity
# Coordinator is used to centralize the data updates
PARALLEL_UPDATES = 0
@@ -39,10 +39,9 @@ async def async_setup_entry(
async_add_entities(entities)
class ComelitSwitchEntity(CoordinatorEntity[ComelitSerialBridge], SwitchEntity):
class ComelitSwitchEntity(ComelitBridgeBaseEntity, SwitchEntity):
"""Switch device."""
_attr_has_entity_name = True
_attr_name = None
def __init__(
@@ -52,13 +51,8 @@ class ComelitSwitchEntity(CoordinatorEntity[ComelitSerialBridge], SwitchEntity):
config_entry_entry_id: str,
) -> None:
"""Init switch entity."""
self._api = coordinator.api
self._device = device
super().__init__(coordinator)
# Use config_entry.entry_id as base for unique_id
# because no serial number or mac is available
super().__init__(coordinator, device, config_entry_entry_id)
self._attr_unique_id = f"{config_entry_entry_id}-{device.type}-{device.index}"
self._attr_device_info = coordinator.platform_device_info(device, device.type)
if device.type == OTHER:
self._attr_device_class = SwitchDeviceClass.OUTLET
@@ -81,4 +75,7 @@ class ComelitSwitchEntity(CoordinatorEntity[ComelitSerialBridge], SwitchEntity):
@property
def is_on(self) -> bool:
"""Return True if switch is on."""
return self.coordinator.data[OTHER][self._device.index].status == STATE_ON
return (
self.coordinator.data[self._device.type][self._device.index].status
== STATE_ON
)

View File

@@ -0,0 +1,13 @@
"""Utils for Comelit."""
from aiohttp import ClientSession, CookieJar
from homeassistant.core import HomeAssistant
from homeassistant.helpers import aiohttp_client
async def async_client_session(hass: HomeAssistant) -> ClientSession:
"""Return a new aiohttp session."""
return aiohttp_client.async_create_clientsession(
hass, verify_ssl=False, cookie_jar=CookieJar(unsafe=True)
)

View File

@@ -56,7 +56,10 @@ from homeassistant.helpers import config_validation as cv, discovery
from homeassistant.helpers.entity_platform import async_get_platforms
from homeassistant.helpers.reload import async_integration_yaml_config
from homeassistant.helpers.service import async_register_admin_service
from homeassistant.helpers.trigger_template_entity import CONF_AVAILABILITY
from homeassistant.helpers.trigger_template_entity import (
CONF_AVAILABILITY,
ValueTemplate,
)
from homeassistant.helpers.typing import ConfigType
from .const import (
@@ -91,7 +94,9 @@ BINARY_SENSOR_SCHEMA = vol.Schema(
vol.Optional(CONF_PAYLOAD_OFF, default=DEFAULT_PAYLOAD_OFF): cv.string,
vol.Optional(CONF_PAYLOAD_ON, default=DEFAULT_PAYLOAD_ON): cv.string,
vol.Optional(CONF_DEVICE_CLASS): BINARY_SENSOR_DEVICE_CLASSES_SCHEMA,
vol.Optional(CONF_VALUE_TEMPLATE): cv.template,
vol.Optional(CONF_VALUE_TEMPLATE): vol.All(
cv.template, ValueTemplate.from_template
),
vol.Optional(CONF_COMMAND_TIMEOUT, default=DEFAULT_TIMEOUT): cv.positive_int,
vol.Optional(CONF_UNIQUE_ID): cv.string,
vol.Optional(
@@ -108,7 +113,9 @@ COVER_SCHEMA = vol.Schema(
vol.Optional(CONF_COMMAND_STOP, default="true"): cv.string,
vol.Required(CONF_NAME): cv.string,
vol.Optional(CONF_ICON): cv.template,
vol.Optional(CONF_VALUE_TEMPLATE): cv.template,
vol.Optional(CONF_VALUE_TEMPLATE): vol.All(
cv.template, ValueTemplate.from_template
),
vol.Optional(CONF_COMMAND_TIMEOUT, default=DEFAULT_TIMEOUT): cv.positive_int,
vol.Optional(CONF_DEVICE_CLASS): COVER_DEVICE_CLASSES_SCHEMA,
vol.Optional(CONF_UNIQUE_ID): cv.string,
@@ -134,7 +141,9 @@ SENSOR_SCHEMA = vol.Schema(
vol.Optional(CONF_NAME, default=SENSOR_DEFAULT_NAME): cv.string,
vol.Optional(CONF_ICON): cv.template,
vol.Optional(CONF_UNIT_OF_MEASUREMENT): cv.string,
vol.Optional(CONF_VALUE_TEMPLATE): cv.template,
vol.Optional(CONF_VALUE_TEMPLATE): vol.All(
cv.template, ValueTemplate.from_template
),
vol.Optional(CONF_UNIQUE_ID): cv.string,
vol.Optional(CONF_DEVICE_CLASS): SENSOR_DEVICE_CLASSES_SCHEMA,
vol.Optional(CONF_STATE_CLASS): SENSOR_STATE_CLASSES_SCHEMA,
@@ -150,7 +159,9 @@ SWITCH_SCHEMA = vol.Schema(
vol.Optional(CONF_COMMAND_ON, default="true"): cv.string,
vol.Optional(CONF_COMMAND_STATE): cv.string,
vol.Required(CONF_NAME): cv.string,
vol.Optional(CONF_VALUE_TEMPLATE): cv.template,
vol.Optional(CONF_VALUE_TEMPLATE): vol.All(
cv.template, ValueTemplate.from_template
),
vol.Optional(CONF_ICON): cv.template,
vol.Optional(CONF_COMMAND_TIMEOUT, default=DEFAULT_TIMEOUT): cv.positive_int,
vol.Optional(CONF_UNIQUE_ID): cv.string,

View File

@@ -18,7 +18,10 @@ from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.event import async_track_time_interval
from homeassistant.helpers.template import Template
from homeassistant.helpers.trigger_template_entity import ManualTriggerEntity
from homeassistant.helpers.trigger_template_entity import (
ManualTriggerEntity,
ValueTemplate,
)
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from homeassistant.util import dt as dt_util
@@ -50,7 +53,7 @@ async def async_setup_platform(
scan_interval: timedelta = binary_sensor_config.get(
CONF_SCAN_INTERVAL, SCAN_INTERVAL
)
value_template: Template | None = binary_sensor_config.get(CONF_VALUE_TEMPLATE)
value_template: ValueTemplate | None = binary_sensor_config.get(CONF_VALUE_TEMPLATE)
data = CommandSensorData(hass, command, command_timeout)
@@ -86,7 +89,7 @@ class CommandBinarySensor(ManualTriggerEntity, BinarySensorEntity):
config: ConfigType,
payload_on: str,
payload_off: str,
value_template: Template | None,
value_template: ValueTemplate | None,
scan_interval: timedelta,
) -> None:
"""Initialize the Command line binary sensor."""
@@ -133,9 +136,14 @@ class CommandBinarySensor(ManualTriggerEntity, BinarySensorEntity):
await self.data.async_update()
value = self.data.value
variables = self._template_variables_with_value(value)
if not self._render_availability_template(variables):
self.async_write_ha_state()
return
if self._value_template is not None:
value = self._value_template.async_render_with_possible_json_value(
value, None
value = self._value_template.async_render_as_value_template(
self.entity_id, variables, None
)
self._attr_is_on = None
if value == self._payload_on:
@@ -143,7 +151,7 @@ class CommandBinarySensor(ManualTriggerEntity, BinarySensorEntity):
elif value == self._payload_off:
self._attr_is_on = False
self._process_manual_data(value)
self._process_manual_data(variables)
self.async_write_ha_state()
async def async_update(self) -> None:

View File

@@ -20,7 +20,10 @@ from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.event import async_track_time_interval
from homeassistant.helpers.template import Template
from homeassistant.helpers.trigger_template_entity import ManualTriggerEntity
from homeassistant.helpers.trigger_template_entity import (
ManualTriggerEntity,
ValueTemplate,
)
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from homeassistant.util import dt as dt_util, slugify
@@ -79,7 +82,7 @@ class CommandCover(ManualTriggerEntity, CoverEntity):
command_close: str,
command_stop: str,
command_state: str | None,
value_template: Template | None,
value_template: ValueTemplate | None,
timeout: int,
scan_interval: timedelta,
) -> None:
@@ -164,14 +167,20 @@ class CommandCover(ManualTriggerEntity, CoverEntity):
"""Update device state."""
if self._command_state:
payload = str(await self._async_query_state())
variables = self._template_variables_with_value(payload)
if not self._render_availability_template(variables):
self.async_write_ha_state()
return
if self._value_template:
payload = self._value_template.async_render_with_possible_json_value(
payload, None
payload = self._value_template.async_render_as_value_template(
self.entity_id, variables, None
)
self._state = None
if payload:
self._state = int(payload)
self._process_manual_data(payload)
self._process_manual_data(variables)
self.async_write_ha_state()
async def async_update(self) -> None:

View File

@@ -23,7 +23,10 @@ from homeassistant.exceptions import TemplateError
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.event import async_track_time_interval
from homeassistant.helpers.template import Template
from homeassistant.helpers.trigger_template_entity import ManualTriggerSensorEntity
from homeassistant.helpers.trigger_template_entity import (
ManualTriggerSensorEntity,
ValueTemplate,
)
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from homeassistant.util import dt as dt_util
@@ -57,7 +60,7 @@ async def async_setup_platform(
json_attributes: list[str] | None = sensor_config.get(CONF_JSON_ATTRIBUTES)
json_attributes_path: str | None = sensor_config.get(CONF_JSON_ATTRIBUTES_PATH)
scan_interval: timedelta = sensor_config.get(CONF_SCAN_INTERVAL, SCAN_INTERVAL)
value_template: Template | None = sensor_config.get(CONF_VALUE_TEMPLATE)
value_template: ValueTemplate | None = sensor_config.get(CONF_VALUE_TEMPLATE)
data = CommandSensorData(hass, command, command_timeout)
trigger_entity_config = {
@@ -88,7 +91,7 @@ class CommandSensor(ManualTriggerSensorEntity):
self,
data: CommandSensorData,
config: ConfigType,
value_template: Template | None,
value_template: ValueTemplate | None,
json_attributes: list[str] | None,
json_attributes_path: str | None,
scan_interval: timedelta,
@@ -144,6 +147,11 @@ class CommandSensor(ManualTriggerSensorEntity):
await self.data.async_update()
value = self.data.value
variables = self._template_variables_with_value(self.data.value)
if not self._render_availability_template(variables):
self.async_write_ha_state()
return
if self._json_attributes:
self._attr_extra_state_attributes = {}
if value:
@@ -168,16 +176,17 @@ class CommandSensor(ManualTriggerSensorEntity):
LOGGER.warning("Unable to parse output as JSON: %s", value)
else:
LOGGER.warning("Empty reply found when expecting JSON data")
if self._value_template is None:
self._attr_native_value = None
self._process_manual_data(value)
self._process_manual_data(variables)
self.async_write_ha_state()
return
self._attr_native_value = None
if self._value_template is not None and value is not None:
value = self._value_template.async_render_with_possible_json_value(
value,
None,
value = self._value_template.async_render_as_value_template(
self.entity_id, variables, None
)
if self.device_class not in {
@@ -190,7 +199,7 @@ class CommandSensor(ManualTriggerSensorEntity):
value, self.entity_id, self.device_class
)
self._process_manual_data(value)
self._process_manual_data(variables)
self.async_write_ha_state()
async def async_update(self) -> None:

View File

@@ -19,7 +19,10 @@ from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.event import async_track_time_interval
from homeassistant.helpers.template import Template
from homeassistant.helpers.trigger_template_entity import ManualTriggerEntity
from homeassistant.helpers.trigger_template_entity import (
ManualTriggerEntity,
ValueTemplate,
)
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from homeassistant.util import dt as dt_util, slugify
@@ -78,7 +81,7 @@ class CommandSwitch(ManualTriggerEntity, SwitchEntity):
command_on: str,
command_off: str,
command_state: str | None,
value_template: Template | None,
value_template: ValueTemplate | None,
timeout: int,
scan_interval: timedelta,
) -> None:
@@ -166,15 +169,21 @@ class CommandSwitch(ManualTriggerEntity, SwitchEntity):
"""Update device state."""
if self._command_state:
payload = str(await self._async_query_state())
variables = self._template_variables_with_value(payload)
if not self._render_availability_template(variables):
self.async_write_ha_state()
return
value = None
if self._value_template:
value = self._value_template.async_render_with_possible_json_value(
payload, None
value = self._value_template.async_render_as_value_template(
self.entity_id, variables, None
)
self._attr_is_on = None
if payload or value:
self._attr_is_on = (value or payload).lower() == "true"
self._process_manual_data(payload)
self._process_manual_data(variables)
self.async_write_ha_state()
async def async_update(self) -> None:

View File

@@ -197,6 +197,7 @@ class ChatLog:
(
"?",
";", # Greek question mark
"", # Chinese question mark
)
)
)
@@ -387,7 +388,7 @@ class ChatLog:
self,
conversing_domain: str,
user_input: ConversationInput,
user_llm_hass_api: str | None = None,
user_llm_hass_api: str | list[str] | None = None,
user_llm_prompt: str | None = None,
) -> None:
"""Set the LLM system prompt."""

View File

@@ -73,14 +73,14 @@ async def _async_set_position(
Returns True if the position was set, False if there is no
supported method for setting the position.
"""
if target_position == FULL_CLOSE and CoverEntityFeature.CLOSE in features:
await service_call(SERVICE_CLOSE_COVER, service_data)
elif target_position == FULL_OPEN and CoverEntityFeature.OPEN in features:
await service_call(SERVICE_OPEN_COVER, service_data)
elif CoverEntityFeature.SET_POSITION in features:
if CoverEntityFeature.SET_POSITION in features:
await service_call(
SERVICE_SET_COVER_POSITION, service_data | {ATTR_POSITION: target_position}
)
elif target_position == FULL_CLOSE and CoverEntityFeature.CLOSE in features:
await service_call(SERVICE_CLOSE_COVER, service_data)
elif target_position == FULL_OPEN and CoverEntityFeature.OPEN in features:
await service_call(SERVICE_OPEN_COVER, service_data)
else:
# Requested a position but the cover doesn't support it
return False
@@ -98,15 +98,17 @@ async def _async_set_tilt_position(
Returns True if the tilt position was set, False if there is no
supported method for setting the tilt position.
"""
if target_tilt_position == FULL_CLOSE and CoverEntityFeature.CLOSE_TILT in features:
await service_call(SERVICE_CLOSE_COVER_TILT, service_data)
elif target_tilt_position == FULL_OPEN and CoverEntityFeature.OPEN_TILT in features:
await service_call(SERVICE_OPEN_COVER_TILT, service_data)
elif CoverEntityFeature.SET_TILT_POSITION in features:
if CoverEntityFeature.SET_TILT_POSITION in features:
await service_call(
SERVICE_SET_COVER_TILT_POSITION,
service_data | {ATTR_TILT_POSITION: target_tilt_position},
)
elif (
target_tilt_position == FULL_CLOSE and CoverEntityFeature.CLOSE_TILT in features
):
await service_call(SERVICE_CLOSE_COVER_TILT, service_data)
elif target_tilt_position == FULL_OPEN and CoverEntityFeature.OPEN_TILT in features:
await service_call(SERVICE_OPEN_COVER_TILT, service_data)
else:
# Requested a tilt position but the cover doesn't support it
return False
@@ -183,12 +185,12 @@ async def _async_reproduce_state(
current_attrs = cur_state.attributes
target_attrs = state.attributes
current_position = current_attrs.get(ATTR_CURRENT_POSITION)
target_position = target_attrs.get(ATTR_CURRENT_POSITION)
current_position: int | None = current_attrs.get(ATTR_CURRENT_POSITION)
target_position: int | None = target_attrs.get(ATTR_CURRENT_POSITION)
position_matches = current_position == target_position
current_tilt_position = current_attrs.get(ATTR_CURRENT_TILT_POSITION)
target_tilt_position = target_attrs.get(ATTR_CURRENT_TILT_POSITION)
current_tilt_position: int | None = current_attrs.get(ATTR_CURRENT_TILT_POSITION)
target_tilt_position: int | None = target_attrs.get(ATTR_CURRENT_TILT_POSITION)
tilt_position_matches = current_tilt_position == target_tilt_position
state_matches = cur_state.state == target_state
@@ -214,19 +216,11 @@ async def _async_reproduce_state(
)
service_data = {ATTR_ENTITY_ID: entity_id}
set_position = (
not position_matches
and target_position is not None
and await _async_set_position(
service_call, service_data, features, target_position
)
set_position = target_position is not None and await _async_set_position(
service_call, service_data, features, target_position
)
set_tilt = (
not tilt_position_matches
and target_tilt_position is not None
and await _async_set_tilt_position(
service_call, service_data, features, target_tilt_position
)
set_tilt = target_tilt_position is not None and await _async_set_tilt_position(
service_call, service_data, features, target_tilt_position
)
if target_state in CLOSING_STATES:

View File

@@ -73,7 +73,7 @@
"remote_moved_any_side": "Device moved with any side up",
"remote_double_tap_any_side": "Device double tapped on any side",
"remote_turned_clockwise": "Device turned clockwise",
"remote_turned_counter_clockwise": "Device turned counter clockwise",
"remote_turned_counter_clockwise": "Device turned counterclockwise",
"remote_rotate_from_side_1": "Device rotated from \"side 1\" to \"{subtype}\"",
"remote_rotate_from_side_2": "Device rotated from \"side 2\" to \"{subtype}\"",
"remote_rotate_from_side_3": "Device rotated from \"side 3\" to \"{subtype}\"",

View File

@@ -45,6 +45,17 @@
}
}
},
"light": {
"bed_light": {
"state_attributes": {
"effect": {
"state": {
"rainbow": "mdi:looks"
}
}
}
}
},
"number": {
"volume": {
"default": "mdi:volume-high"

View File

@@ -15,6 +15,7 @@ from homeassistant.components.light import (
ATTR_WHITE,
DEFAULT_MAX_KELVIN,
DEFAULT_MIN_KELVIN,
EFFECT_OFF,
ColorMode,
LightEntity,
LightEntityFeature,
@@ -28,7 +29,7 @@ from . import DOMAIN
LIGHT_COLORS = [(56, 86), (345, 75)]
LIGHT_EFFECT_LIST = ["rainbow", "none"]
LIGHT_EFFECT_LIST = ["rainbow", EFFECT_OFF]
LIGHT_TEMPS = [4166, 2631]
@@ -48,6 +49,7 @@ async def async_setup_entry(
available=True,
effect_list=LIGHT_EFFECT_LIST,
effect=LIGHT_EFFECT_LIST[0],
translation_key="bed_light",
device_name="Bed Light",
state=False,
unique_id="light_1",
@@ -119,8 +121,10 @@ class DemoLight(LightEntity):
rgbw_color: tuple[int, int, int, int] | None = None,
rgbww_color: tuple[int, int, int, int, int] | None = None,
supported_color_modes: set[ColorMode] | None = None,
translation_key: str | None = None,
) -> None:
"""Initialize the light."""
self._attr_translation_key = translation_key
self._available = True
self._brightness = brightness
self._ct = ct or random.choice(LIGHT_TEMPS)

View File

@@ -41,6 +41,7 @@ async def async_setup_entry(
DemoTVShowPlayer(),
DemoBrowsePlayer("Browse"),
DemoGroupPlayer("Group"),
DemoSearchPlayer("Search"),
]
)
@@ -95,6 +96,8 @@ NETFLIX_PLAYER_SUPPORT = (
BROWSE_PLAYER_SUPPORT = MediaPlayerEntityFeature.BROWSE_MEDIA
SEARCH_PLAYER_SUPPORT = MediaPlayerEntityFeature.SEARCH_MEDIA
class AbstractDemoPlayer(MediaPlayerEntity):
"""A demo media players."""
@@ -398,3 +401,9 @@ class DemoGroupPlayer(AbstractDemoPlayer):
| MediaPlayerEntityFeature.GROUPING
| MediaPlayerEntityFeature.TURN_OFF
)
class DemoSearchPlayer(AbstractDemoPlayer):
"""A Demo media player that supports searching."""
_attr_supported_features = SEARCH_PLAYER_SUPPORT

View File

@@ -28,10 +28,10 @@
"state_attributes": {
"fan_mode": {
"state": {
"auto_high": "Auto High",
"auto_low": "Auto Low",
"on_high": "On High",
"on_low": "On Low"
"auto_high": "Auto high",
"auto_low": "Auto low",
"on_high": "On high",
"on_low": "On low"
}
},
"swing_mode": {
@@ -39,14 +39,14 @@
"1": "1",
"2": "2",
"3": "3",
"auto": "Auto",
"auto": "[%key:common::state::auto%]",
"off": "[%key:common::state::off%]"
}
},
"swing_horizontal_mode": {
"state": {
"rangefull": "Full range",
"auto": "Auto",
"auto": "[%key:common::state::auto%]",
"off": "[%key:common::state::off%]"
}
}
@@ -58,7 +58,7 @@
"state_attributes": {
"preset_mode": {
"state": {
"auto": "[%key:component::climate::entity_component::_::state_attributes::fan_mode::state::auto%]",
"auto": "[%key:common::state::auto%]",
"sleep": "[%key:component::climate::entity_component::_::state_attributes::preset_mode::state::sleep%]",
"smart": "Smart",
"on": "[%key:common::state::on%]"
@@ -78,12 +78,23 @@
}
}
},
"light": {
"bed_light": {
"state_attributes": {
"effect": {
"state": {
"rainbow": "Rainbow"
}
}
}
}
},
"select": {
"speed": {
"state": {
"light_speed": "Light Speed",
"ludicrous_speed": "Ludicrous Speed",
"ridiculous_speed": "Ridiculous Speed"
"light_speed": "Light speed",
"ludicrous_speed": "Ludicrous speed",
"ridiculous_speed": "Ridiculous speed"
}
}
},
@@ -102,7 +113,7 @@
"model_s": {
"state_attributes": {
"cleaned_area": {
"name": "Cleaned Area"
"name": "Cleaned area"
}
}
}

View File

@@ -218,7 +218,7 @@ class TrackerEntity(
entity_description: TrackerEntityDescription
_attr_latitude: float | None = None
_attr_location_accuracy: int = 0
_attr_location_accuracy: float = 0
_attr_location_name: str | None = None
_attr_longitude: float | None = None
_attr_source_type: SourceType = SourceType.GPS
@@ -234,7 +234,7 @@ class TrackerEntity(
return not self.should_poll
@cached_property
def location_accuracy(self) -> int:
def location_accuracy(self) -> float:
"""Return the location accuracy of the device.
Value in meters.

View File

@@ -3,8 +3,8 @@
from __future__ import annotations
import asyncio
from collections.abc import Mapping
from functools import partial
from types import MappingProxyType
from typing import Any
from devolo_home_control_api.exceptions.gateway import GatewayOfflineError
@@ -97,7 +97,7 @@ async def async_remove_config_entry_device(
return True
def configure_mydevolo(conf: dict[str, Any] | MappingProxyType[str, Any]) -> Mydevolo:
def configure_mydevolo(conf: Mapping[str, Any]) -> Mydevolo:
"""Configure mydevolo."""
mydevolo = Mydevolo()
mydevolo.user = conf[CONF_USERNAME]

View File

@@ -88,6 +88,8 @@ class DevoloScannerEntity( # pylint: disable=hass-enforce-class-module
):
"""Representation of a devolo device tracker."""
_attr_translation_key = "device_tracker"
def __init__(
self,
coordinator: DevoloDataUpdateCoordinator[list[ConnectedStationInfo]],
@@ -123,13 +125,6 @@ class DevoloScannerEntity( # pylint: disable=hass-enforce-class-module
)
return attrs
@property
def icon(self) -> str:
"""Return device icon."""
if self.is_connected:
return "mdi:lan-connect"
return "mdi:lan-disconnect"
@property
def is_connected(self) -> bool:
"""Return true if the device is connected to the network."""

View File

@@ -13,6 +13,14 @@
"default": "mdi:wifi-plus"
}
},
"device_tracker": {
"device_tracker": {
"default": "mdi:lan-disconnect",
"state": {
"home": "mdi:lan-connect"
}
}
},
"sensor": {
"connected_plc_devices": {
"default": "mdi:lan"

View File

@@ -8,7 +8,7 @@
"integration_type": "device",
"iot_class": "local_polling",
"loggers": ["devolo_plc_api"],
"requirements": ["devolo-plc-api==1.4.1"],
"requirements": ["devolo-plc-api==1.5.1"],
"zeroconf": [
{
"type": "_dvl-deviceapi._tcp.local.",

View File

@@ -138,7 +138,7 @@ async def async_setup_entry(
SENSOR_TYPES[CONNECTED_PLC_DEVICES],
)
)
network = await device.plcnet.async_get_network_overview()
network: LogicalNetwork = coordinators[CONNECTED_PLC_DEVICES].data
peers = [
peer.mac_address for peer in network.devices if peer.topology == REMOTE
]

View File

@@ -114,9 +114,14 @@ class DevoloSwitchEntity[_DataT: _DataType](
translation_key="password_protected",
translation_placeholders={"title": self.entry.title},
) from ex
except DeviceUnavailable:
pass # The coordinator will handle this
await self.coordinator.async_request_refresh()
except DeviceUnavailable as ex:
raise HomeAssistantError(
translation_domain=DOMAIN,
translation_key="no_response",
translation_placeholders={"title": self.entry.title},
) from ex
finally:
await self.coordinator.async_request_refresh()
async def async_turn_off(self, **kwargs: Any) -> None:
"""Turn the entity off."""
@@ -129,6 +134,11 @@ class DevoloSwitchEntity[_DataT: _DataType](
translation_key="password_protected",
translation_placeholders={"title": self.entry.title},
) from ex
except DeviceUnavailable:
pass # The coordinator will handle this
await self.coordinator.async_request_refresh()
except DeviceUnavailable as ex:
raise HomeAssistantError(
translation_domain=DOMAIN,
translation_key="no_response",
translation_placeholders={"title": self.entry.title},
) from ex
finally:
await self.coordinator.async_request_refresh()

View File

@@ -4,7 +4,6 @@ from __future__ import annotations
import asyncio
from collections.abc import Callable
from dataclasses import dataclass
from datetime import timedelta
from fnmatch import translate
from functools import lru_cache, partial
@@ -66,13 +65,12 @@ from homeassistant.helpers.service_info.dhcp import DhcpServiceInfo as _DhcpServ
from homeassistant.helpers.typing import ConfigType
from homeassistant.loader import DHCPMatcher, async_get_dhcp
from .const import DOMAIN
from . import websocket_api
from .const import DOMAIN, HOSTNAME, IP_ADDRESS, MAC_ADDRESS
from .models import DATA_DHCP, DHCPAddressData, DHCPData, DhcpMatchers
CONFIG_SCHEMA = cv.empty_config_schema(DOMAIN)
HOSTNAME: Final = "hostname"
MAC_ADDRESS: Final = "macaddress"
IP_ADDRESS: Final = "ip"
REGISTERED_DEVICES: Final = "registered_devices"
SCAN_INTERVAL = timedelta(minutes=60)
@@ -87,15 +85,6 @@ _DEPRECATED_DhcpServiceInfo = DeprecatedConstant(
)
@dataclass(slots=True)
class DhcpMatchers:
"""Prepared info from dhcp entries."""
registered_devices_domains: set[str]
no_oui_matchers: dict[str, list[DHCPMatcher]]
oui_matchers: dict[str, list[DHCPMatcher]]
def async_index_integration_matchers(
integration_matchers: list[DHCPMatcher],
) -> DhcpMatchers:
@@ -133,36 +122,34 @@ def async_index_integration_matchers(
async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
"""Set up the dhcp component."""
watchers: list[WatcherBase] = []
address_data: dict[str, dict[str, str]] = {}
integration_matchers = async_index_integration_matchers(await async_get_dhcp(hass))
dhcp_data = DHCPData(integration_matchers=integration_matchers)
hass.data[DATA_DHCP] = dhcp_data
websocket_api.async_setup(hass)
watchers: list[WatcherBase] = []
# For the passive classes we need to start listening
# for state changes and connect the dispatchers before
# everything else starts up or we will miss events
device_watcher = DeviceTrackerWatcher(hass, address_data, integration_matchers)
device_watcher = DeviceTrackerWatcher(hass, dhcp_data)
device_watcher.async_start()
watchers.append(device_watcher)
device_tracker_registered_watcher = DeviceTrackerRegisteredWatcher(
hass, address_data, integration_matchers
)
device_tracker_registered_watcher = DeviceTrackerRegisteredWatcher(hass, dhcp_data)
device_tracker_registered_watcher.async_start()
watchers.append(device_tracker_registered_watcher)
async def _async_initialize(event: Event) -> None:
await aiodhcpwatcher.async_init()
network_watcher = NetworkWatcher(hass, address_data, integration_matchers)
network_watcher = NetworkWatcher(hass, dhcp_data)
network_watcher.async_start()
watchers.append(network_watcher)
dhcp_watcher = DHCPWatcher(hass, address_data, integration_matchers)
dhcp_watcher = DHCPWatcher(hass, dhcp_data)
await dhcp_watcher.async_start()
watchers.append(dhcp_watcher)
rediscovery_watcher = RediscoveryWatcher(
hass, address_data, integration_matchers
)
rediscovery_watcher = RediscoveryWatcher(hass, dhcp_data)
rediscovery_watcher.async_start()
watchers.append(rediscovery_watcher)
@@ -180,18 +167,13 @@ async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
class WatcherBase:
"""Base class for dhcp and device tracker watching."""
def __init__(
self,
hass: HomeAssistant,
address_data: dict[str, dict[str, str]],
integration_matchers: DhcpMatchers,
) -> None:
def __init__(self, hass: HomeAssistant, dhcp_data: DHCPData) -> None:
"""Initialize class."""
super().__init__()
self.hass = hass
self._integration_matchers = integration_matchers
self._address_data = address_data
self._callbacks = dhcp_data.callbacks
self._integration_matchers = dhcp_data.integration_matchers
self._address_data = dhcp_data.address_data
self._unsub: Callable[[], None] | None = None
@callback
@@ -230,18 +212,18 @@ class WatcherBase:
mac_address = formatted_mac.replace(":", "")
compressed_ip_address = made_ip_address.compressed
data = self._address_data.get(mac_address)
current_data = self._address_data.get(mac_address)
if (
not force
and data
and data[IP_ADDRESS] == compressed_ip_address
and data[HOSTNAME].startswith(hostname)
and current_data
and current_data[IP_ADDRESS] == compressed_ip_address
and current_data[HOSTNAME].startswith(hostname)
):
# If the address data is the same no need
# to process it
return
data = {IP_ADDRESS: compressed_ip_address, HOSTNAME: hostname}
data: DHCPAddressData = {IP_ADDRESS: compressed_ip_address, HOSTNAME: hostname}
self._address_data[mac_address] = data
lowercase_hostname = hostname.lower()
@@ -287,9 +269,19 @@ class WatcherBase:
_LOGGER.debug("Matched %s against %s", data, matcher)
matched_domains.add(domain)
if not matched_domains:
return # avoid creating DiscoveryKey if there are no matches
if self._callbacks:
address_data = {mac_address: data}
for callback_ in self._callbacks:
callback_(address_data)
service_info: _DhcpServiceInfo | None = None
if not matched_domains:
return
service_info = _DhcpServiceInfo(
ip=ip_address,
hostname=lowercase_hostname,
macaddress=mac_address,
)
discovery_key = DiscoveryKey(
domain=DOMAIN,
key=mac_address,
@@ -300,11 +292,7 @@ class WatcherBase:
self.hass,
domain,
{"source": config_entries.SOURCE_DHCP},
_DhcpServiceInfo(
ip=ip_address,
hostname=lowercase_hostname,
macaddress=mac_address,
),
service_info,
discovery_key=discovery_key,
)
@@ -315,11 +303,10 @@ class NetworkWatcher(WatcherBase):
def __init__(
self,
hass: HomeAssistant,
address_data: dict[str, dict[str, str]],
integration_matchers: DhcpMatchers,
dhcp_data: DHCPData,
) -> None:
"""Initialize class."""
super().__init__(hass, address_data, integration_matchers)
super().__init__(hass, dhcp_data)
self._discover_hosts: DiscoverHosts | None = None
self._discover_task: asyncio.Task | None = None

View File

@@ -1,3 +1,8 @@
"""Constants for the dhcp integration."""
from typing import Final
DOMAIN = "dhcp"
HOSTNAME: Final = "hostname"
MAC_ADDRESS: Final = "macaddress"
IP_ADDRESS: Final = "ip"

View File

@@ -0,0 +1,37 @@
"""The dhcp integration."""
from __future__ import annotations
from collections.abc import Callable
from functools import partial
from homeassistant.core import CALLBACK_TYPE, HomeAssistant, callback
from .models import DATA_DHCP, DHCPAddressData
@callback
def async_register_dhcp_callback_internal(
hass: HomeAssistant,
callback_: Callable[[dict[str, DHCPAddressData]], None],
) -> CALLBACK_TYPE:
"""Register a dhcp callback.
For internal use only.
This is not intended for use by integrations.
"""
callbacks = hass.data[DATA_DHCP].callbacks
callbacks.add(callback_)
return partial(callbacks.remove, callback_)
@callback
def async_get_address_data_internal(
hass: HomeAssistant,
) -> dict[str, DHCPAddressData]:
"""Get the address data.
For internal use only.
This is not intended for use by integrations.
"""
return hass.data[DATA_DHCP].address_data

View File

@@ -0,0 +1,43 @@
"""The dhcp integration."""
from __future__ import annotations
from collections.abc import Callable
import dataclasses
from dataclasses import dataclass
from typing import TypedDict
from homeassistant.loader import DHCPMatcher
from homeassistant.util.hass_dict import HassKey
from .const import DOMAIN
@dataclass(slots=True)
class DhcpMatchers:
"""Prepared info from dhcp entries."""
registered_devices_domains: set[str]
no_oui_matchers: dict[str, list[DHCPMatcher]]
oui_matchers: dict[str, list[DHCPMatcher]]
class DHCPAddressData(TypedDict):
"""Typed dict for DHCP address data."""
hostname: str
ip: str
@dataclasses.dataclass(slots=True)
class DHCPData:
"""Data for the dhcp component."""
integration_matchers: DhcpMatchers
callbacks: set[Callable[[dict[str, DHCPAddressData]], None]] = dataclasses.field(
default_factory=set
)
address_data: dict[str, DHCPAddressData] = dataclasses.field(default_factory=dict)
DATA_DHCP: HassKey[DHCPData] = HassKey(DOMAIN)

View File

@@ -0,0 +1,63 @@
"""The dhcp integration websocket apis."""
from __future__ import annotations
from typing import Any
import voluptuous as vol
from homeassistant.components import websocket_api
from homeassistant.core import HomeAssistant, callback
from homeassistant.helpers import device_registry as dr
from homeassistant.helpers.json import json_bytes
from .const import HOSTNAME, IP_ADDRESS
from .helpers import (
async_get_address_data_internal,
async_register_dhcp_callback_internal,
)
from .models import DHCPAddressData
@callback
def async_setup(hass: HomeAssistant) -> None:
"""Set up the DHCP websocket API."""
websocket_api.async_register_command(hass, ws_subscribe_discovery)
@websocket_api.require_admin
@websocket_api.websocket_command(
{
vol.Required("type"): "dhcp/subscribe_discovery",
}
)
@websocket_api.async_response
async def ws_subscribe_discovery(
hass: HomeAssistant, connection: websocket_api.ActiveConnection, msg: dict[str, Any]
) -> None:
"""Handle subscribe discovery websocket command."""
ws_msg_id: int = msg["id"]
def _async_send(address_data: dict[str, DHCPAddressData]) -> None:
connection.send_message(
json_bytes(
websocket_api.event_message(
ws_msg_id,
{
"add": [
{
"mac_address": dr.format_mac(mac_address).upper(),
"hostname": data[HOSTNAME],
"ip_address": data[IP_ADDRESS],
}
for mac_address, data in address_data.items()
]
},
)
)
)
unsub = async_register_dhcp_callback_internal(hass, _async_send)
connection.subscriptions[ws_msg_id] = unsub
connection.send_message(json_bytes(websocket_api.result_message(ws_msg_id)))
_async_send(async_get_address_data_internal(hass))

View File

@@ -2,7 +2,7 @@
"config": {
"step": {
"user": {
"title": "Set up the Dialogflow Webhook",
"title": "Set up the Dialogflow webhook",
"description": "Are you sure you want to set up Dialogflow?"
}
},
@@ -12,7 +12,7 @@
"webhook_not_internet_accessible": "[%key:common::config_flow::abort::webhook_not_internet_accessible%]"
},
"create_entry": {
"default": "To send events to Home Assistant, you will need to set up [webhook integration of Dialogflow]({dialogflow_url}).\n\nFill in the following info:\n\n- URL: `{webhook_url}`\n- Method: POST\n- Content Type: application/json\n\nSee [the documentation]({docs_url}) for further details."
"default": "To send events to Home Assistant, you will need to set up the [webhook service of Dialogflow]({dialogflow_url}).\n\nFill in the following info:\n\n- URL: `{webhook_url}`\n- Method: POST\n- Content Type: application/json\n\nSee [the documentation]({docs_url}) for further details."
}
}
}

View File

@@ -6,5 +6,5 @@
"iot_class": "local_polling",
"loggers": ["pydoods"],
"quality_scale": "legacy",
"requirements": ["pydoods==1.0.2", "Pillow==11.1.0"]
"requirements": ["pydoods==1.0.2", "Pillow==11.2.1"]
}

View File

@@ -179,22 +179,18 @@ class DukeEnergyCoordinator(DataUpdateCoordinator[None]):
one = timedelta(days=1)
if start_time is None:
# Max 3 years of data
agreement_date = dt_util.parse_datetime(meter["agreementActiveDate"])
if agreement_date is None:
start = dt_util.now(tz) - timedelta(days=3 * 365)
else:
start = max(
agreement_date.replace(tzinfo=tz),
dt_util.now(tz) - timedelta(days=3 * 365),
)
start = dt_util.now(tz) - timedelta(days=3 * 365)
else:
start = datetime.fromtimestamp(start_time, tz=tz) - lookback
agreement_date = dt_util.parse_datetime(meter["agreementActiveDate"])
if agreement_date is not None:
start = max(agreement_date.replace(tzinfo=tz), start)
start = start.replace(hour=0, minute=0, second=0, microsecond=0)
end = dt_util.now(tz).replace(hour=0, minute=0, second=0, microsecond=0) - one
_LOGGER.debug("Data lookup range: %s - %s", start, end)
start_step = end - lookback
start_step = max(end - lookback, start)
end_step = end
usage: dict[datetime, dict[str, float | int]] = {}
while True:

View File

@@ -2,8 +2,7 @@
from __future__ import annotations
from collections.abc import Callable
from types import MappingProxyType
from collections.abc import Callable, Mapping
from typing import Any
from dynalite_devices_lib.dynalite_devices import (
@@ -50,7 +49,7 @@ class DynaliteBridge:
LOGGER.debug("Setting up bridge - host %s", self.host)
return await self.dynalite_devices.async_setup()
def reload_config(self, config: MappingProxyType[str, Any]) -> None:
def reload_config(self, config: Mapping[str, Any]) -> None:
"""Reconfigure a bridge when config changes."""
LOGGER.debug("Reloading bridge - host %s, config %s", self.host, config)
self.dynalite_devices.configure(convert_config(config))

Some files were not shown because too many files have changed in this diff Show More