Commit Graph
15478 Commits
Author SHA1 Message Date
J. Nick KostonandGitHub aec2d63302 Add keep_days to recorder.purge_entities (#89726) 2023-03-15 11:13:47 -10:00
epenetandGitHub 3aa5629665 Improve type hints in condition helper tests (#89754) 2023-03-15 19:42:23 +01:00
MichaelandGitHub d4edec2863 Move calculation of current value into lib in Fritz!SmartHome (#89150) 2023-03-15 18:59:03 +01:00
fceb208381 Abort Hue config flow if bridge can not be reached (#88893)
Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2023-03-15 18:55:34 +01:00
starkillerOGandGitHub 4eee626770 Reolink check firmware (#88903) 2023-03-15 18:54:28 +01:00
epenetandGitHub 54ad8b8ee9 Avoid lingering timers in update coordinator tests (#89749) 2023-03-15 18:50:32 +01:00
epenetandGitHub c416d18506 Add WAN information to SFR Box (#89678) 2023-03-15 18:49:57 +01:00
epenetandGitHub 35c02ddc81 Add type hints to update coordinator tests (#89748) 2023-03-15 18:07:43 +01:00
Allen PorterandGitHub b588b8b215 Bump ical to 4.5.0 (#89744) 2023-03-15 18:06:46 +01:00
J. Nick KostonandGitHub a244749712 Make StatesMetaManager thread-safe when an entity_id is fully deleted from the database and than re-added (#89732)
* refactor to make StatesMetaManager threadsafe

* refactor to make StatesMetaManager threadsafe

* refactor to make StatesMetaManager threadsafe

* refactor to make StatesMetaManager threadsafe

* reduce

* comments
2023-03-15 08:54:02 -04:00
6270776fbb Add turn_on trigger to Samsung TV (#89018)
* Add turn_on trigger to Samsung TV

* Add tests

* Apply suggestions from code review

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

* Remove assert

* Cleanup mock_send_magic_packet

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2023-03-15 12:43:53 +01:00
jan iversenandGitHub cd23caff58 Correct modbus serial method parameter (#89738) 2023-03-15 12:27:45 +01:00
epenetandGitHub 9719f817c0 Bump ruff to 0.0.256 (#89734) 2023-03-15 10:07:12 +01:00
a91055cc2a Fix additional typing in local calendar tests (#89704)
* Fix additional typing in local calendar tests

* Update tests/components/local_calendar/test_calendar.py

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

---------

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2023-03-14 19:33:46 -07:00
J. Nick KostonandGitHub b906d67c1e Fix filtered purge not removing newer events (#89721) 2023-03-14 16:33:19 -10:00
Penny WoodandGitHub 858fc30fcd Fix infinite loop in sun.sun (#89723) 2023-03-14 16:27:29 -10:00
Allen PorterandGitHub 4ddcb14053 Add additional CalendarEvent validation (#89533)
Add additional event validation
2023-03-14 20:27:38 -04:00
Jack BoswellandGitHub c33ca4f664 Add diagnostics to Starlink (#86328) 2023-03-14 22:24:47 +01:00
Erik MontnemeryandGitHub c2c809682a Tweak OTBR tests (#89694) 2023-03-14 21:26:16 +01:00
Ernst KlamerandGitHub d1969fd0c2 Add water sensor to bthome (#89595)
* Add water sensor to bthome

* Use TOTAL state class for gas water and energy
2023-03-14 19:26:05 +01:00
epenetandGitHub 71dc98a39c Improve hass_ws_client type hint in tests (#89703) 2023-03-14 16:31:40 +01:00
1bc4802c04 Move local calendar text fixtures to conftest.py (#89674)
* Move local calendar text fixtures to conftest.py

* Apply suggestions from code review

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

* Add imports for suggested typing fixes

* Apply suggestions from code review

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

---------

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2023-03-14 08:12:44 -07:00
Erik MontnemeryandGitHub 85e0177195 Add WS command for connecting OTBR to a known Thread network (#89692)
* Add WS command for connecting OTBR to a known Thread network

* Add test
2023-03-14 15:28:06 +01:00
Bram KragtenandGitHub a213ef2475 Add websocket command to set preferred thread dataset (#89700) 2023-03-14 15:27:31 +01:00
ec1b8b616f Debounce and group MQTT subscriptions (#88862)
* Debounce and group mqtt subscriptions

* Cleanup

* Do not cooldown on resubscribe

* Remove lock from task

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

* ruff

* Longer initial cool down. Manages unsubscribes

* Own lock for access to self._pending_subscriptions

* adjust

* Subscribe to highest QoS when sharing subscription

* do not block _pending_subscriptions_lock with io

* Test the highest qos is subscribed at

* Cleanup max qos

* Follow up comments part 1

* Make docstr more generic

* Make max qos update thread safe

* Add lock on clearing _max_qos when resubscribing

* Wait for linger task

* User copy

* Check for key before cleaning up

* Fix lingering task

* Do not use a lock

* do not await _async_queue_subscriptions

* Replace copy with assignment

* Update max qos before returning

* Do not iterate if max_qos == 0

* Do not ieterate subs if max qos == 0

* Set initial cooldown correctly

* Ensure discovery cooldown ends after subscribing

* plan last subscribe with debouncer timeout

* cooldown if self._pending_subscriptions is set

* Revert format changes

* Remove stale assingnment self._last_subscribe

* Remove not used property

* Also check while for pending subscriptions

* revert first added sleep()

* Optimize

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2023-03-14 11:13:55 +01:00
J. Nick KostonandGitHub 2cb673db04 Handle bytes data in sql sensors (#89169) 2023-03-13 18:07:05 -10:00
afa58b80bd Default to recorder db for SQL integration (#85436)
Co-authored-by: J. Nick Koston <nick@koston.org>
2023-03-13 17:41:32 -10:00
Erik MontnemeryandGitHub 2f4e9c8ef3 Use otbr domain as dataset source (#89653) 2023-03-13 20:56:09 -04:00
Erik MontnemeryandGitHub d422b0dcc2 Make OTBR add newly created dataset to thread credential store (#89645) 2023-03-13 14:09:09 -04:00
David PollandGitHub 0457bb2717 Add is_hidden_entity test for Jinja templates (#89011) 2023-03-13 18:20:33 +01:00
G JohanssonandGitHub 02389960ce Refactor Command line sensor to inherit TemplateSensor (#81222)
* Refactor sensor

* Remove not needed

* block until done

* reset test

* test sensor

* Add time
2023-03-13 17:23:25 +01:00
Erik MontnemeryandGitHub 8a0522ca2a Include extended address in thread discovery data (#89640) 2023-03-13 15:59:22 +01:00
11e21378b1 Add sensors for supervisor host (#89461)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2023-03-13 15:39:49 +01:00
epenetandGitHub 07b25939a2 Use SnapshotAssertion in SFR button tests (#89633) 2023-03-13 15:23:00 +01:00
cdfb43d403 Address late review comments for frontier_silicon config flow (#89507)
Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
Co-authored-by: wlcrs <wlcrs@users.noreply.github.com>
2023-03-13 15:06:45 +01:00
anotherthomasandGitHub 179cc4d7f7 Improve warnings in mqtt light messages (#89552)
* improved warnings in mqtt light messages.

* fixed tests.
2023-03-13 14:46:16 +01:00
Erik MontnemeryandGitHub a230732087 Correct naming of some otbr tests (#89631) 2023-03-13 13:56:08 +01:00
epenetandGitHub f3da95fb1f Use SnapshotAssertion in SFR binary sensor tests (#89624) 2023-03-13 13:37:51 +01:00
6e10cd81dd Use repair issue when port enable fails in Reolink (#89591)
* Reolink use repair issue for disabled ports

* fix styling

* Add port repair issue tests

* Update homeassistant/components/reolink/strings.json

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

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2023-03-13 11:43:41 +01:00
7284af6a3e Add an in-memory-preloading loader for Jinja imports (#88850)
* Adds a loader to enable jinja imports.

* Switch to in-memory

* Move loading custom_jinja off of the event loop

* Raise TemplateNotFound if template doesn't exist

* Fix docstring

* Adds a service to reload custom jinja

* Remove IO from test setup

* Improve coverage and small refactor

* Incorporate feedback and use .jinja extension

* Check the loaded sources in test.

* Incorporate PR feedback.

* Update homeassistant/helpers/template.py

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

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2023-03-13 11:00:05 +01:00
epenetandGitHub 5e73ad9cb0 Use SnapshotAssertion in SFR sensor tests (#89619)
* Use SnapshotAssertion in SFR sensor tests

* Name snapshots

* Cleanup const.py

* Remove name from snapshot
2023-03-13 10:45:59 +01:00
Erik MontnemeryandGitHub fd5c56fc7d Rename modules named repairs.py which are not repairs platforms (#89618) 2023-03-13 09:44:20 +01:00
J. Nick KostonandGitHub 4dcf7c6267 Fix history_stats test failing during DST (#89589)
Note that there is one test that needs `now()` as it is
timezone aware
2023-03-12 23:03:48 -04:00
Barry LoongandGitHub 877efc993b Add support for window device class to google assistant (#89564) 2023-03-12 22:45:25 -04:00
J. Nick KostonandGitHub b9ac6b4a7c Improve reliability of context id migration (#89609)
* Split context id migration into states and events tasks

Since events can finish much earlier than states we
would keep looking at the table because states as not
done. Make them seperate tasks

* add retry dec

* fix migration happening twice

* another case
2023-03-12 21:41:48 -04:00
J. Nick KostonandGitHub 459ea048ba Fix old indices never being removed with PostgreSQL (#89599) 2023-03-12 14:07:05 -10:00
J. Nick KostonandGitHub c41f91be89 Deduplicate entity_id in the states table (#89557) 2023-03-12 10:01:58 -10:00
J. Nick KostonandGitHub 73cd62bd32 Fix lingering tasks in google_wifi tests (#89571) 2023-03-12 06:39:07 -10:00
G JohanssonandGitHub e932139721 Strict typing threshold (#82786) 2023-03-12 17:10:00 +01:00
Erik MontnemeryandGitHub cf7e500a8e Support translating entity names (#88242) 2023-03-12 15:55:04 +01:00