* Subscribe to Traccar Server events
* No need to unsubscribe on error
* typo
* rename _attrs
* arg type
* reorder return type
* more spesific
* Update stale docstring
* Avoid circular import in Storage.async_delay_save
We call Storage.async_delay_save for every entity being added or removed
from the registry. The late import took more time than everything else
in the function.
* Avoid reschedule churn in Storage.async_delay_save
When we are adding or removing entities we will call async_delay_save
quite often which has to add and remove a TimerHandle on the event loop
which can add up when there are a lot of registry items changing.
If the timer handle still has 80% of the time remaining on it
we will avoid resceduling and let it fire at the time the
original async_delay_save call was made. This ensures we
do not force the event loop to rebuild its heapq because
too many timer handlers were cancelled at once
* div0
* add coverage for 0 since we had none
* fix bad conflict
* tweaks
* tweaks
* tweaks
* tweaks
* tweaks
* tweaks
* more test fixes
* mqtt tests rely on event loop overhead
* Convert debouncer async_shutdown to be a normal function
nothing was being awaited here and the shutdown call was only used
in integrations marked internal and other internals. Its possible
that a custom component might have been using the method but it
seemed uncommon enough that it did not warrent marking as a breaking
change. The update coordinator is no longer awaiting anything in
async_shutdown either now but it seemed likely that this use
would get subclassed.
* fix
* Add counter entities to the ZHA coordinator device
* rework to prepare for non coordinator device counters
* counter entity test
* update log lines
* disable by default
* Bump library
* Update code to the new library version
* Improve diagnostics
* Fix tests
---------
Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
* aemet: disable legacy options
This enables proper timezone handling:
- Atlantic/Canary for the Canary Islands.
- Europe/Madrid for the Iberian Peninsula.
Also provides daily data for the current day after AEMET stops providing the
full day interval, which is normally after midday (12:00).
This is a breaking change because with the previous behaviour the daily data
for the current day wasn't available after midday and now it will be.
What the integration library does to workaround this is to fallback to the
12-24 interval data if the the 00-24 is no longer provided by the API.
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
* Fix AEMET tests with v0.4.8
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
---------
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
* Add switch platform for husqvarna_automower
* Use RestrictedReasons const
* Typing
* Add snapshot testing
* Invert switch
* Test sucessfull servie calls
* Assert client mock calls
* Use getattr
* Update snapshot
* Add available property
* Add a new base class for control entities
* Make switch unavailabe if mower in error state
* Sort platforms
---------
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Add switch platform
* Add mypulink switch platform
* Update tests according to review
* Address more review comments
* Adjust types
* More typing
* Fix typo
* Use constants in tests
* Revert constants
* Catch aiohttp.ClientError when API call fails
* Add test case for failed async_set_device_points call
* Test api failures for both toggle directions
* Use parametrize for testing switching
* Move backup/* WS commands to the backup integration
* Call correct command
* Use debug for logging
* Remove assertion of hass.data for setup test
* parametrize token fixture
* Add sensor platform for husqvarna_automower
* Adress review comments
* Try to fix test
* Improve sensors
* Address review
* Adapt some values
* Add test
* Add test for cutting blade usage time
* Import TEST_MOWER_ID
* Use a parenthesis around the lambda and indent it so it's easier to distinguish the entity description parameters from the lambda
* Add OpenID authentication to wolflink integration
* Update wolf-comm to 0.0.2
* Upgrade wolf_comm to 0.0.3 + fix tests
* Version 0.0.4 of wolf_comm including LICENSE.txt
* Update requirements to wolf_comm 0.0.4
---------
Co-authored-by: Jan Rothkegel <jan.rothkegel@web.de>
* Add async_schedule_call to the Debouncer
async_schedule_call allows the Debouncer to schedule a call
from a callback without having to create tasks to run
async_call
* Update homeassistant/helpers/debounce.py
* Make device registry cleanup all callback function
* fix typing, code supported callback functions, but typing did not
* fixes
* fixes
* fix
* we had no coverage for other job types
* we had no coverage for other job types
* add calendar
* rename function
* remove device from test
* requested changes
* extend range
* fix async_get_events
* catch and test edge cases
* remove commented code
* rebase snapshot
* Reduce overhead to load multiple languages in translations
Instead of loading in a task, we now group everything
to be loaded into a single executor job
* fixes
* fixes
* fixes
* fixes
* fixes
* update tests
* add missing coverage (was existing)