Commit Graph

184 Commits

Author SHA1 Message Date
Marc Mueller
6c365c94ed Update sqlalchemy to 2.0.41 (#145790) 2025-05-28 16:39:10 +02:00
Jan Bouwhuis
b1403838bb Add translation string and references for sensor Measurement Angle state class (#145639) 2025-05-26 21:22:10 +02:00
alorente
1d47dc41c9 Add reactive energy device class and units (#143941) 2025-05-15 12:05:46 +01: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
J. Nick Koston
f247183e11 Bump SQLAlchemy to 2.0.40 (#141898)
changelog: https://docs.sqlalchemy.org/en/20/changelog/changelog_20.html#change-2.0.40
2025-03-31 10:11:13 +02:00
J. Nick Koston
e78dc486f7 Bump SQLAlchemy to 2.0.39 (#140473)
* Bump SQLAlchemy to 2.0.39

changelog: https://docs.sqlalchemy.org/en/20/changelog/changelog_20.html#change-2.0.39

* fix typing
2025-03-12 13:09:41 -10:00
G Johansson
32950df0b7 Specify recorder as after dependency in sql integration (#139037)
* Specify recorder as after dependency in sql integration

* Remove hassfest exception

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2025-02-28 20:51:56 +01:00
Erik Montnemery
f83c8de8d3 Update signature of platforms' async_setup_entry (#138201) 2025-02-10 21:08:03 +01:00
J. Nick Koston
684d8dac0d Bump SQLAlchemy to 2.0.38 (#137693) 2025-02-07 13:03:19 -06:00
Norbert Rittel
b4559e0342 Several fixes in user-facing strings of the SQL integration (#137438)
- use proper sentence-casing for all strings
- replace "unit of measure" with correct "unit of measurement"
- replace "HA recorder" with "Home Assistant Recorder" as this is a name that is not translated
- add some details from the online docs to descriptions
2025-02-06 18:05:04 +02:00
J. Nick Koston
f75a61ac90 Bump SQLAlchemy to 2.0.37 (#137028)
changelog: https://docs.sqlalchemy.org/en/20/changelog/changelog_20.html#change-2.0.37

There is a bug fix that likely affects us that could lead to corrupted queries
https://docs.sqlalchemy.org/en/20/changelog/changelog_20.html#change-e4d04d8eb1bccee16b74f5662aff8edd
2025-01-31 13:52:38 -05:00
epenet
844259bd6c Standardize homeassistant imports in component (s) (#136832) 2025-01-29 12:24:31 +01:00
G Johansson
877d16273b Fix SQL sensor name (#134414) 2025-01-02 08:51:49 +01:00
J. Nick Koston
ffeefd4856 Bump SQLAlchemy to 2.0.36 (#126683)
* Bump SQLAlchemy to 2.0.35

changelog: https://docs.sqlalchemy.org/en/20/changelog/changelog_20.html#change-2.0.35

* fix mocking

* adjust to .36

* remove ignored as these are now typed

* fix SQLAlchemy
2024-11-30 22:07:51 -05:00
epenet
c54ed53a81 Remove usage of options property in OptionsFlow (part 1) (#129895)
* Remove usage of options property in OptionsFlow

* Improve
2024-11-05 19:51:20 +01:00
epenet
8b6c99776e Cleanup unnecessary OptionsFlowWithConfigEntry (part 1) (#129752)
* Cleanup unnecessary OptionsFlowWithConfigEntry

* Fix emoncms

* Fix imap

* Fix met

* Fix workday
2024-11-03 22:57:18 +01:00
Erik Montnemery
533e383d5d Remove unnecessary assignment of Template.hass from sql (#123690) 2024-08-12 15:51:02 +02:00
dougiteixeira
74c2f000d8 Add missing translations for device class in SQL (#120892) 2024-07-01 07:44:59 +02:00
G Johansson
9b341f5b67 Don't record attributes in sql (#120170) 2024-06-22 19:42:55 +02:00
J. Nick Koston
a642454e6f Bump sqlalchemy to 2.0.31 (#119951) 2024-06-19 08:09:04 +02:00
Sid
c2b3bf3fb9 Enable Ruff RET502 (#115139) 2024-05-21 22:19:33 +02:00
J. Nick Koston
fd52588565 Bump SQLAlchemy to 2.0.30 (#116964) 2024-05-07 10:42:13 +02:00
J. Nick Koston
7e35fcf11a Bump sqlparse to 0.5.0 (#115681)
fixes https://github.com/home-assistant/core/security/dependabot/54
fixes https://github.com/home-assistant/core/security/dependabot/55
2024-04-16 08:30:51 +02:00
J. Nick Koston
345fa75562 Bump SQLAlchemy to 2.0.29 (#114208) 2024-03-25 14:39:16 -10:00
Marc Mueller
2c06d4fcb9 Add empty line after module docstring (2) [components] (#112736) 2024-03-08 19:15:59 +01:00
Marc Mueller
930a396712 Add empty line after module docstring [s] (#112704) 2024-03-08 14:33:51 +01:00
J. Nick Koston
235771aaa2 Bump SQLAlchemy to 2.0.28 (#112314) 2024-03-05 12:14:30 -10:00
Erik Montnemery
b0ed8c4961 Migrate integrations s-t to generic flowhandler (#111865) 2024-02-29 22:16:14 +01:00
G Johansson
5073842514 Fix sql integration no recorder (#111263) 2024-02-24 22:40:49 +01:00
J. Nick Koston
eee6a119d5 Bump SQLAlchemy to 2.0.27 (#110517) 2024-02-14 10:32:05 +01:00
J. Nick Koston
5e5a9d9c59 Bump SQLAlchemy to 2.0.26 (#110358) 2024-02-12 19:57:53 +01:00
J. Nick Koston
710e55fb09 Bump SQLAlchemy to 2.0.25 (#106931)
* Bump SQLAlchemy to 2.0.25

changelog: https://docs.sqlalchemy.org/en/20/changelog/changelog_20.html#change-2.0.25

* drop unused ignore now that upstream is fixed
2024-01-03 09:12:35 +01:00
J. Nick Koston
6e98f72f8b Bump SQLAlchemy to 2.0.24 (#106672) 2023-12-29 10:19:06 -10:00
dougiteixeira
65c21438a6 Add query type validation independent of declaration position for SQL (#105921)
* Add query type validation independent of declaration position

* Restore close sess

* Separates invalid query and non-read-only query tests

* Add more tests

* Use the SQLParseError exception for queries that are not read-only

* Add handling for multiple SQL queries.

* Fix test

* Clean ';' at the beginning of the SQL query

* Clean ';' at the beginning of the SQL query - init

* Query cleaning before storing

* Query cleaning before setup sesensor plataform - YAML

* Exception when the SQL query type is not detected

* Cleaning

* Cleaning

* Fix typing in tests

* Fix typing in tests

* Add test for query = ';;'

* Update homeassistant/components/sql/__init__.py

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

* Update homeassistant/components/sql/__init__.py

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

* Update __init__.py

* Update config_flow.py

* Clean query before storing

---------

Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2023-12-27 17:58:35 +01:00
G Johansson
99cf4a6b2d Add rollback on exception that needs rollback in SQL (#104948) 2023-12-08 21:13:37 +01:00
J. Nick Koston
fd8caaf846 Bump SQLAlchemy to 2.0.23 (#103313) 2023-11-03 11:10:08 -05:00
Robert Resch
bb90c1f168 Fix multilevel reference translations (#102338) 2023-10-20 08:12:53 +02:00
J. Nick Koston
e427fc511b Bump SQLAlchemy to 2.0.22 (#102033) 2023-10-15 06:14:51 -10:00
Robert Resch
952a17532f Remove NONE_SENTINEL in favor of optional select in sql (#101309) 2023-10-11 17:38:29 +02:00
J. Nick Koston
6f8734167f Bump SQLAlchemy to 2.0.21 (#99745) 2023-09-20 16:19:53 +02:00
G Johansson
b8f35fb577 Fix missing unique id in SQL (#99641) 2023-09-04 22:31:53 +02:00
G Johansson
61c17291fb Move TemplateEntity to template (#98957)
* Move TemplateEntity to template

* Rename template_entity in helpers
2023-08-24 15:37:04 +02:00
Joost Lekkerkerker
87dd18cc2e Remove obsolete yaml check in SQL (#98950)
* Remove unique id check from SQL

* Remove unique id check from SQL
2023-08-24 12:35:11 +02:00
G Johansson
268e5244f0 Cleanup ManualTriggerSensorEntity (#98629)
* Cleanup ManualTriggerSensorEntity

* ConfigType
2023-08-18 20:19:17 +02:00
Erik Montnemery
045c327928 Move DeviceInfo from entity to device registry (#98149)
* Move DeviceInfo from entity to device registry

* Update integrations
2023-08-10 22:04:26 -04:00
G Johansson
1f11ce63fc Manual trigger entity fix name influence entity_id (#97398) 2023-07-30 18:47:34 +02:00
G Johansson
f610a9b1c9 Fix sql entities not loading (#97316) 2023-07-27 09:24:32 +02:00
Miguel Camba
38111141f9 Add new device class: PH (potential hydrogen) (#95928) 2023-07-23 18:49:10 +02:00
G Johansson
4e2b00a443 Refactor SQL with ManualTriggerEntity (#95116)
* First go

* Finalize sensor

* Add tests

* Remove not need _attr_name

* device_class

* _process_manual_data allow Any as value
2023-07-20 11:35:08 +02:00
dougiteixeira
4b1d096e6b Add device_class and state_class in config flow for SQL (#95020)
* Add device_class and state_class in config flow for SQL

* Update when selected NONE_SENTINEL

* Add tests

* Use SensorDeviceClass and SensorStateClass in tests

* Add volatile_organic_compounds_parts in strings selector

* Add test_attributes_from_entry_config

* Remove test_attributes_from_entry_config and complement test_device_state_class

* Add test_attributes_from_entry_config in test_sensor.py
2023-07-08 21:00:22 +02:00