Commit Graph

756 Commits (74e4654c26177909e653921f27f838fd1366adc0)

Author SHA1 Message Date
Stefan Agner 9ab69aa41c
Add mWh as unit of measurement for Matter energy sensors (#133005) 2024-12-13 09:33:58 +01:00
Robert Resch a67045ee6c
Remove deprecated home assistant const constants (#131799) 2024-11-28 12:12:37 +01:00
Marc Mueller 7110df04e6
Bump version to 2025.1.0dev0 (#131751) 2024-11-27 22:32:56 +01:00
Josef Zweck 3cfd958dc2
Allow mL/s as UnitOfVolumeFlowRate (#130771) 2024-11-21 20:47:24 +01:00
Michael Arthur d8549409f7
Area units and conversion between metric and US (#123563)
* area conversions

* start work on tests

* add number device class

* update unit conversions to utilise distance constants

* add area unit

* update test unit system

* update device condition and trigger

* update statistic unit converters

* further tests work WIP

* update test unit system

* add missing string translations

* fix websocket tests

* add deprecated notice

* add more missing strings and missing initialisation of unit system

* adjust icon and remove strings from scrape and random

* Fix acre to meters conversion

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Tidy up valid units

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* fix ordering of area

* update order alphabetically

* fix broken test

* update test_init

* Update homeassistant/const.py

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* remove deprecated unit and fix alphabetical order

* change deprecation and add tests, change to millimeter conversion for inches

* fix order

* re-order defs alphabetically

* add measurement as well

* update icons

* fix up Deprecation of area square meters

* Update core integrations to UnitOfArea

* update test recorder tests

* unit system tests in alphabetical

* update snapshot

* rebuild

* revert alphabetization of functions

* other revert of alphabetical order

---------

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2024-11-21 16:10:44 +01:00
Manu 397a299f15
Add µV as UnitOfElectricPotential (#130838) 2024-11-19 22:38:22 +01:00
Marc Mueller ed5560aec2
Update base image to Python 3.13 and deprecated 3.12 (#130425) 2024-11-13 19:28:53 +01:00
epenet 25fb70f281
Add blood glucose concentration device class (#129340) 2024-11-09 11:29:24 +01:00
Jakob Schlyter cd11f01ace
Add support for MW/GW/TW and GWh/TWh (#130089) 2024-11-08 22:12:16 +01:00
Bram Kragten 208b15637a
Bump version to 2024.12 (#129525) 2024-10-30 20:59:56 +01:00
Erik Montnemery 4b56701152
Move core config class to core_config.py (#129163) 2024-10-26 07:00:31 +02:00
G Johansson cdfec7ebb4
Implement new state property for alarm_control_panel which is using an enum (#126283)
* Alarm state from enum

* Fixes

* Set final

* Fix rebase

* Test const

* Fix breaking version

* Fix other for alarm_control_panel

* Fix integrations

* More

* More

* More

* More

* Fix zha

* Replace _attr_state

* Fix alarm_control_panel

* Fix tests

* Fixes

* Mods

* Change some

* More

* More

* More

* Tests

* Last tests

* Return enum

* Fix zha

* Remove not needed check

* Fix wording

* Fix homekit

* Mod prometheus

* Fix mypy

* Fix homekit

* Fix ifttt
2024-10-21 22:54:27 +02:00
Erik Montnemery 0956dbb578
Rename `UnitOfConductivity` enum members (#127919)
* Rename UnitOfConductivity enum members

* Update test snapshots
2024-10-08 14:44:01 +02:00
Michael ffa6b5fcb2
Use two words for Nautical miles unit (#126905) 2024-09-27 13:16:13 +02:00
Michael 26b5dab12b
Add `nmi` (nautical miles) as valid distance unit (#124723) 2024-09-27 10:40:59 +02:00
Franck Nijhof 9afd270111
Bump version to 2024.11.0dev0 (#126776) 2024-09-25 21:08:07 +02:00
Joost Lekkerkerker a1906b434f
Change trigger platform key to trigger (#124357)
* fix

* Fix

* Fix

* Update homeassistant/helpers/config_validation.py

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

* Fix

* Fix

* Fix

* Fix

* Add more tests

* Fix

* Fix tests

* Add tests

* Let's see what the CI does

* It fails on the code that tested the thing ofc

* It fails on the code that tested the thing ofc

* Revert test thingy

* Now the test works again, lovely

* Another one

* Fix websocket thingy

* Only copy when needed

* Improve comment

* Remove test

* Fix docstring

* I think this now also work since this transforms trigger to platform

* Add comment

* Update homeassistant/helpers/config_validation.py

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

* Update homeassistant/helpers/config_validation.py

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

* Update homeassistant/helpers/config_validation.py

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

* Check for mapping

* Add test

* Update homeassistant/helpers/config_validation.py

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

* Update test to also test for trigger keys

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-09-25 14:19:58 +02:00
G Johansson 93aade6e8e
Change lock state to an enum (#126379)
* Add new LockState enum for lock states

* Add rest

* Fix insteon tests

* Fix mqtt tests

* Fix tesla_fleet

* Revert back ST_STATE_LOCKED

* Add back constant
2024-09-24 12:30:50 +02:00
Trevor Schirmer 96b7fc9a75
Add mm/s and in/s As Unit Of Speed (#125044)
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-09-22 09:01:46 -05:00
epenet c81d104822
Sort values in Platform enum (#126259) 2024-09-19 13:12:37 +02:00
Sergey Dudanov dcd7830a35
Add calories to energy sensor device class (#122796)
* added calories to energy class

* changes

* temporarily solving the problem with conversion accuracy

* add tests

* added calories to energy class

* changes

* add tests

* Update homeassistant/util/unit_conversion.py

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

* Update homeassistant/util/unit_conversion.py

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

* apply suggestions

* Update homeassistant/util/unit_conversion.py

---------

Co-authored-by: Robert Resch <robert@resch.dev>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-09-10 12:22:15 +02:00
karwosts 056e6eae82
Add a syntax for merging lists of triggers (#117698)
* Add a syntax for merging lists of triggers

* Updating to the new syntax

* Update homeassistant/helpers/config_validation.py

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

* fix suggestion

* update test and add comments

* not actually json

* move test to new file

* update tests

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-09-09 13:51:32 +02:00
Michael Hansen 60b0f0dc53
Add assist satellite entity component (#125351)
* Add assist_satellite

* Update homeassistant/components/assist_satellite/manifest.json

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

* Update homeassistant/components/assist_satellite/manifest.json

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

* Add platform constant

* Update Dockerfile

* Apply suggestions from code review

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

* Address comments

* Update docstring async_internal_announce

* Update CODEOWNERS

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-09-05 21:16:30 -04:00
Robert Resch 2dce876a86
Bump version to 2024.10.0dev0 (#124808) 2024-08-28 18:51:50 +02:00
G Johansson dd52f4c84a
Remove deprecated mailbox platform (#123740)
* Remove deprecated mailbox platform

* Remove from const

* Remove from type hints

* Remove from pyproject
2024-08-28 16:41:23 +02:00
Christian Neumeier 3e53cc175f
Change POWER_VOLT_AMPERE_REACTIVE to UnitOfReactivePower (#117153)
* Refactoring: exchange POWER_VOLT_AMPERE_REACTIVE with UnitOfReactivePower

* updated iotawatt and mysensors from VOLT_AMPERE_REACTIVE to UnitOfReactivePower.VOLT_AMPERE_REACTIVE

* deprecation period for POWER_VOLT_AMPERE_REACTIVE changed to one year.

* POWER_VOLT_AMPERE_REACTIVE changed to UnitOfReactivePower in blebox integration

* Update homeassistant/const.py

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-08-21 15:36:45 +02:00
Maciej Bieniek a9d8e47979
Support `DeviceInfo.model_id` in MQTT integration (#123152)
Add support for model_id
2024-08-04 23:02:41 +02:00
Franck Nijhof bdd6f57975
Bump version to 2024.9.0dev0 (#122975) 2024-07-31 23:24:30 +02:00
Franck Nijhof 8b96c7873f
Rename 'service' to 'action' in automations and scripts (#122845) 2024-07-31 14:36:53 +02:00
Franck Nijhof 33b4f40b2a
Bump version to 2024.8.0dev0 (#120577) 2024-06-26 16:55:08 +02:00
Erik Montnemery d589eaf440
Simplify EVENT_STATE_REPORTED (#120508) 2024-06-26 11:23:26 +02:00
dontinelli 0dd5391cd7
Add Siemes and Millisiemens as additional units of conductivity and enable conversion between conductivity units (#118728) 2024-06-21 11:10:15 +02:00
Franck Nijhof eca8dd93c5
Bump version to 2024.7.0dev0 (#118399) 2024-05-29 20:54:49 +02:00
J. Nick Koston 33ff84469a
Align max expected entities constant between modules (#118102) 2024-05-27 14:06:16 -10:00
J. Nick Koston e12d23bd48
Speed up async_get_loaded_integrations (#117851)
* Speed up async_get_loaded_integrations

Use a setcomp and difference to find the components to split
to avoid the loop. A setcomp is inlined in python3.12 so its
much faster

* Speed up async_get_loaded_integrations

Use a setcomp and difference to find the components to split
to avoid the loop. A setcomp is inlined in python3.12 so its
much faster

* simplify

* fix compat

* bootstrap

* fix tests
2024-05-21 09:08:49 -04:00
Denis Shulyaka c3196a5667
LLM Tools support for Google Generative AI integration (#117644)
* initial commit

* Undo prompt chenges

* Move format_tool out of the class

* Only catch HomeAssistantError and vol.Invalid

* Add config flow option

* Fix type

* Add translation

* Allow changing API access from options flow

* Allow model picking

* Remove allowing HASS Access in main flow

* Move model to the top in options flow

* Make prompt conditional based on API access

* convert only once to dict

* Reduce debug logging

* Update title

* re-order models

* Address comments

* Move things

* Update labels

* Add tool call tests

* coverage

* Use LLM APIs

* Fixes

* Address comments

* Reinstate the title to not break entity name

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2024-05-19 22:11:25 -04:00
Marc Mueller c50a340cbc
Use HassKey for setup and bootstrap (#116998) 2024-05-07 11:18:20 -05:00
Franck Nijhof f2fe62d159
Bump version to 2024.6.0dev0 (#116120) 2024-04-24 23:16:48 +02:00
J. Nick Koston 53a179088f
Add debug mode to catch unsafe thread operations using core helpers (#115390)
* adjust

* adjust

* fixes

* one more

* test

* debug

* move to config

* cover

* Update homeassistant/core.py

* set debug from RuntimeConfig

* reduce

* fix message

* raise

* Update homeassistant/core.py

* Update homeassistant/core.py

* no flood check for raise

* cover
2024-04-24 03:36:05 +02:00
Marc Mueller 6116f11e6c
Use EventType for system events (#115190) 2024-04-08 08:25:34 -10:00
Paulus Schoutsen f9a7e6bb9f
Add migration logic to assist_pipeline (#115172) 2024-04-08 11:29:55 -04:00
Marc Mueller a0e6fd6ec5
Add improved typing for event fire and listen methods (#114906)
* Add EventType implementation

* Update integrations for EventType

* Change state_changed to EventType

* Fix tests

* Remove runtime impact

* Add tests

* Move to stub file

* Apply pre-commit to stub files

* Fix ruff PYI checks

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2024-04-07 13:28:24 -10:00
Franck Nijhof 3d4733a026
Bump version to 2024.5.0dev0 (#114324) 2024-03-27 19:43:38 +01:00
Marc Mueller 1d2c2d2055
Move SignalTypes to util (#114236) 2024-03-27 08:41:44 +01:00
Franck Nijhof 2388e2dda9
Drop Python 3.11 support (#114220) 2024-03-26 12:51:14 +01:00
Erik Montnemery 426f73b1f4
Add State.last_reported (#113511)
* Add State.last_reported

* Update tests

* Update test snapshots

* Call state_reported listeners when firing state_changed event

* Add tests
2024-03-20 21:05:07 +01:00
Franck Nijhof 167e66d45c
Add labels to service target (#113753) 2024-03-18 22:32:23 +01:00
Erik Montnemery a5cde8a61e
Improve typing of State.as_compressed_state (#113540) 2024-03-16 00:01:46 -04:00
Franck Nijhof 2aadd643ed
Add floors to service target (#110850) 2024-03-14 19:02:23 +01:00
Marc Mueller 19ab3d6daf
Add empty line after module docstring [helpers + other] (#112707) 2024-03-08 10:36:11 -05:00