* Use temperature of current preset when set fritz HVAC mode to HEAT
If the HVAC mode of the Fritzbox thermostats changes from `HVACMode.OFF`
to `HVAMode.HEAT`, the current preset (COMFORT / ECO) should be
observed. Depending on the status of the current preset, the set
temperature of comfort / eco is set as the new temperature.
* fixup do not use value_scheduled_preset
Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
* Add current_preset value to test_set_hvac_mode
The current_preset parameter allows the mock to be set to an active
preset. When setting HVACMode.HEAT, the respective temperature of the
ECO/COMFORT preset should be set.
* fixup Use the updated value_scheduled_preset function
To distinguish which temperature should be used when setting the
`HVAMode.HEAT`, `value_schedules_preset` is now used again, which has
been updated since the first commit. If no schedule is active, the
comfort_temperature is used. Otherwise, the respective temperature of
the current preset.
Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
---------
Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
* Start mqtt integration config flow only once
* Remember last config message
* Filter out instead of unsubscribing the intehration discovery topic
* Follow up comments from code review
* add optional config_flow step of uploading .ics file to import local calendar events
* feat: add unit test for import_ics step
* fix: remove unneeded test patch
* feat: add helper for moving ics to storage location
* move helper to config_flow
* ruff
* fix tests; add test for invalid ics content
* Update homeassistant/components/local_calendar/config_flow.py
* Update import flow with radio button and improved text
Signed-off-by: Allen Porter <allen.porter@gmail.com>
* Remove commented out code
* Update with lint fixes
* Apply suggestions from code review
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
---------
Signed-off-by: Allen Porter <allen.porter@gmail.com>
Co-authored-by: Allen Porter <allen.porter@gmail.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
* Prevent session scope fixtures in component tests
* Link message to the decorator - not the function
* Add checks for package also
* Add check for session scope autouse
* Rename variable
* Adjust message
* Ignore fancy autouse
* Simplify
* 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>
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Enable Zwave notification sensors by default
* Fix the check to (dis)allow discovering a value multiple times
* Prevent discovery of duplicate Notification CC sensors
* alarm sensors disabled by default
* one more fix
* Update diagnostics tests
---------
Co-authored-by: Marcel van der Veldt <m.vanderveldt@outlook.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Make statistics validation create issue registry issues
* Disable creating issue about outdated MariaDB version in tests
* Use call_soon_threadsafe instead of run_callback_threadsafe
* Update tests
* Fix flapping test
* Disable creating issue about outdated SQLite version in tests
* Implement agreed changes
* Add translation strings for issue titles
* Update test
* Add fan mode support to knx climate
* fix linting errors
* remove unneeded None protection from CONF_FAN_PERCENTAGES_MODES
* Update homeassistant/components/knx/climate.py
Co-authored-by: Matthias Alphart <farmio@alphart.net>
* Update homeassistant/components/knx/climate.py
Co-authored-by: Matthias Alphart <farmio@alphart.net>
* Update homeassistant/components/knx/climate.py
Co-authored-by: Matthias Alphart <farmio@alphart.net>
* Update homeassistant/components/knx/schema.py
Co-authored-by: Matthias Alphart <farmio@alphart.net>
* find closest percentage when not in fan modes
* new field for fan speed mode, max steps apply to both step and percentage
* not picking FAN_OFF when the percentage is closest to zero
* add fan zero mode to support auto mode
* use StrEnum for FanZeroMode
* change default to 'percent'
* fix mypy errors
---------
Co-authored-by: Matthias Alphart <farmio@alphart.net>
* Add work area switch for Husqvarna Automower
* move work area deletion test to separate file
* stale doctsrings
* don't use custom test file
* use _attr_name
* ruff
* add available property
* hassfest
* fix tests
* Apply suggestions from code review
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* constants
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Require uploads to target an album
* Remove edge case where albums are not loaded on startup which no longer happens
* Update homeassistant/components/google_photos/strings.json
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Update Google Photos to have a data update coordiantor for loading albums
* Remove album from services
* Remove action string changes
* Revert services.yaml change
* Simplify integration by blocking startup on album loading
* Update homeassistant/components/google_photos/coordinator.py
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Reinitialize bluetooth discovery flow on unignore
* Update homeassistant/components/bluetooth/manager.py
Co-authored-by: J. Nick Koston <nick@koston.org>
* Update tests
* Rediscover on any removed config entry
---------
Co-authored-by: J. Nick Koston <nick@koston.org>
* Allow tts options of type list such as profiles in google_cloud
* Update tests/components/tts/test_media_source.py
* Don't mix engine specific options with other options
* Fix test
* Update assist_pipeline snapshots
---------
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
Co-authored-by: Erik Montnemery <erik@montnemery.com>
* Index config entry discovery_keys by discovery domain
* Add new signal
* Update tests
* Update homeassistant/config_entries.py
Co-authored-by: J. Nick Koston <nick@koston.org>
* Fix imports
---------
Co-authored-by: J. Nick Koston <nick@koston.org>
* Reinitialize zeroconf discovery flow on unignore
* Adjust tests
* Improve comments
* Fix logic for updating discovery keys
* Add tests
* Use mock_config_flow helper in new config_entries test
* Add discovery_keys attribute to ConfigEntry
* Update zeroconf rediscovery
* Change type of ConfigEntry.discovery_keys
* Update tests
* Fix DiscoveryKey.from_json_dict and add tests
* Fix test
---------
Co-authored-by: J. Nick Koston <nick@koston.org>
* Add button for router reconnect
* strings for router reconnect
* remove stale router reconnect if zigbee is not running router firmware
* Add tests for router reconnect button
* Update homeassistant/components/smlight/strings.json
And fix associated tests
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Make router button entity dynamic
* adjust test for dynamic runtime removal
* drop if statements from tests
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Adding coordinator for omada device list
* Remove dead omada devices at startup
* Tidy up tests
* Address PR feedback
* Returned to use of read-only properties for coordinators. Tidied up parameters some more
* Update homeassistant/components/tplink_omada/controller.py
* Update homeassistant/components/tplink_omada/controller.py
* Update homeassistant/components/tplink_omada/controller.py
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Add issue asking users to disable ESPHome assist_in_progress binary sensor
* Include integration name in title and description
* Add repair flow
* Improve test coverage
* Add siren platform for tplink
* Add tests
* Add alarm to features.json
* Update based on reviews
* Use alarm module instead of individual features
---------
Co-authored-by: J. Nick Koston <nick@koston.org>
* Initial commit
* Add/update tests
* Minor adjustment
* Update data_schema
* Adjust get password
* Set const for has_password, remove deletion of extended_data
* Update diagnostics snapshot
* Correct typo
* Add test for migration from mv 2 to 3
* Adjust migration test
* Rename site to account_site
* Add battery service with entities
* Test UpdateFailed exception in coordinator
* Add battery data to diagnostics report
* Add TOTAL state_class where needed
* Fix
---------
Co-authored-by: Joostlek <joostlek@outlook.com>
* Fix loading KNX UI entities with entity category set
* add test
* docstring fixes
* telegram order
* Optionally ignore telegram sending order in tests
because we can't know which platform initialises first
* Add service to set the AC schedule of renault vehicles
* Remove executable permission
* Applied review comments (use snapshot)
* Rewrote examples to not use JSON
* Make NextBus coordinator more resilient and efficient
Resolves issues where one request failing will prevent all agency
predictions to fail. This also removes redundant requests for
predictions that share the same stop.
* Add unload entry test
* Prevent shutdown if the coordinator is still needed
rmvtransport: make filters always effective
In the `rmvtransport` integration, the three config attributes
`destination`, `lines`, and `time_offset` all act as filters. The
expectation is that if multiple filters are given, all of them take
effect.
However, as a consequence of using `elif` in the loop body, if a
`destination` filter has been configured, then both the `lines` and the
`time_offset` filters are ignored and have no effect.
Replace the `elif` with an `if` clause to allow all filter settings to
work as intended.
CC: @cgtobi
* hand down device serial into common entity
* fix platforms
* Revert "fix platforms"
This reverts commit 067af2b567.
* handle event loop issue
* hand in serial
* Revert "Revert "fix platforms""
This reverts commit 9bbb55ee6d.
* fix get serial call
* handle other exceptions
* also check device model for migration
* merge entity and device migration
* add test fixture without serial
* adjust test cases
* add dummy fixture
* remove commented code
* modify migration
* use continue
* break comment
* Dont launch SSE client for core firmware 0.9.9
* Dont offer updates on core firmware 0.9.9
* Add correct firmware done event for legacy v2 firmware
* test update legacy v2 firmware
* Dont raise issue for firmware v2
* Update Aseko to support new API
* Apply suggestions from code review
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Use self.unit instead of self._unit
* Refactor sensor setup entry
* Keep same unique id and identifier
* Revert rename free_chlorine translation key
* Remove new heating entity to keep PR small
* Fix keep same unique id
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* Use correct app credentials when europe is checked
* Rework to add china as well
* Use our own package since the maintainer of the original package is not responding
* Revert to using rewardone's package
* Import app credentials where needed instead of __init__
* Rework region selector
* Bump config entry minor and add migration
* Address comments
* Add vpn_status sensor
* update test fixures with new attributes
* Add vpn enabled switch
vpn strings
* Add vpn switch to test
* update snapshots
* Add vpn status to disabled by default test
* Turn Ring Doorbell and Chime volumes into number entities.
* turn RingOther volumes into numbers as well
* fix linter issues
* move other volume strings into `number` section
* add back old volume sensors but deprecate them
* add tests for `ring.number`
* add back strings for sensors that have just become deprecated
* remove deprecated volume sensors from test
* Revert "remove deprecated volume sensors from test"
This reverts commit fc95af66e7.
* create entities for deprecated sensors so that tests still run
* remove print
* add entities immediately
* move `RingNumberEntityDescription` above `RingNumber` and remove unused import
* remove irrelevant comment about history
* fix not using `setter_fn`
* add missing icons for other volume entities
* rename `entity` -> `entity_id` in number tests
* fix typing in number test
* use constants for `hass.services.async_call()`
* use `@refresh_after` decorator instead of delaying updates manually
* move descriptors above entity class
* Use snapshot to test states.
* add missing snapshot file for number platform
* Update homeassistant/components/ring/number.py
Co-authored-by: Steven B. <51370195+sdb9696@users.noreply.github.com>
---------
Co-authored-by: Steven B. <51370195+sdb9696@users.noreply.github.com>
* Add platform number.
* Remove number user_limit.
* Change LED to led in number snapshot.
* Update homeassistant/components/lektrico/number.py
---------
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
* feat: initial implementation of sensor platform
* refactor(tests): await setup of config_entry in parent function
* feat(tests): add tests for laundrify sensor platform
* refactor: set name property for laundrify binary_sensor
* refactor(tests): add missing type hints
* refactor(tests): remove global change of the logging level
* refactor: address minor changes from code review
* refactor(tests): transform setup_config_entry into fixture
* refactor: leverage entity descriptions to define common entity properties
* refactor: change native unit to Wh
* fix(tests): use fixture to create the config entry
* fix: remove redundant raise of LaundrifyDeviceException
* fix(tests): raise a LaundrifyDeviceException to test the update failure behavior
* refactor(tests): merge several library fixtures into a single one
* refactor(tests): create a separate UpdateCoordinator instead of using the internal
* refactor(tests): avoid using LaundrifyPowerSensor
* refactor: simplify value retrieval by directly accessing the coordinator
* refactor: remove non-raising code from try-block
* refactor(sensor): revert usage of entity descriptions
* refactor(sensor): consolidate common attributes and init func to LaundrifyBaseSensor
* refactor(sensor): instantiate DeviceInfo obj instead of using dict
* refactor(tests): use freezer to trigger coordinator update
* refactor(tests): assert on entity state instead of coordinator
* refactor(tests): make use of freezer
* chore(tests): typo in comment
* Add new integration for WMS WebControl pro using local API
Warema recently released a new local API for their WMS hub
called "WebControl pro". This integration makes use of the
new local API via a new dedicated Python library pywmspro.
For now this integration only supports awnings as covers.
But pywmspro is device-agnostic to ease future extensions.
* Incorporated review feedback from joostlek
Thanks a lot!
* Incorporated more review feedback from joostlek
Thanks a lot!
* Incorporated more review feedback from joostlek
Thanks a lot!
* Fix
* Follow-up fix
* Improve handling of DHCP discovery
* Further test improvements suggested by joostlek, thanks!
---------
Co-authored-by: Joostlek <joostlek@outlook.com>
* Add internet sensor updated by events
* Strings for internet sensor
* Update binary_sensor snapshot with internet sensor
* Add test for internet sensor
* Address review comments
---------
Co-authored-by: Tim Lunn <tim@feathertop.org>
* Add Beolink custom services
Add support for media player grouping via beolink
Give media player entity name
* Fix progress not being set to None as Beolink listener
Revert naming changes
* Update API
simplify Beolink attributes
* Improve beolink custom services
* Fix Beolink expandable source check
Add unexpand return value
Set entity name on initialization
* Handle entity naming as intended
* Fix "null" Beolink self friendly name
* Add regex service input validation
Add all_discovered to beolink_expand service
Improve beolink_expand response
* Add service icons
* Fix merge
Remove unnecessary assignment
* Remove invalid typing
Update response typing for updated API
* Revert to old typed response dict method
Remove mypy ignore line
Fix jid possibly used before assignment
* Re add debugging logging
* Fix coroutine
Fix formatting
* Remove unnecessary update control
* Make tests pass
Fix remote leader media position bug
Improve remote leader BangOlufsenSource comparison
* Fix naming and add callback decorators
* Move regex service check to variable
Suppress KeyError
Update tests
* Re-add hass running check
* Improve comments, naming and type hinting
* Remove old temporary fix
* Convert logged warning to raised exception for invalid media_player
Simplify code using walrus operator
* Fix test for invalid media_player grouping
* Improve method naming
* Improve _beolink_sources explanation
* Improve _beolink_sources explanation
* Add initial media_player grouping
* Convert custom service methods to media_player methods
Fix testing
* Remove beolink JID extra state attribute
* Modify custom services to only work as expected for media_player grouping
Fix tests
* Remove unused dispatch
* Remove wrong comment
* Remove commented out code
* Add config entry mock typing
* Fix beolink listener playback progress
Fix formatting
Add and use get_serial_number_from_jid function
* Fix testing
* Clarify beolink WebSocket notifications
* Further clarify beolink WebSocket notifications
* Convert notification value to enum value
* Improve comments for touch to join
* Fix None being cast to str if leader is not in HA
* Add error messages to devices in Beolink session and not Home Assistant
Rework _get_beolink_jid
* Replace redundant function call
* Show friendly name for unavailable remote leader instead of JID
* Update homeassistant/components/bang_olufsen/media_player.py
Co-authored-by: Erik Montnemery <erik@montnemery.com>
* Remove unneeded typing
* Rework _get_beolink_jid entity check
Clarify invalid entity error message
* Remove redundant "entity" from string
* Fix invalid typing
fix state assertions
* Fix raised error type
---------
Co-authored-by: Erik Montnemery <erik@montnemery.com>
* Force root import of references from other components
* Improve
* Adjust
* Tweak exceptions
* Another
* Another
* Another
* Another
* Another
* Another
* Another
* Another
* Another
* Another
* Another
* Another
* Adjust
* More
* Ignore violations in test
* Improve
* if the derivative is negative, ignore it
* add option to ignore the negatives or not
* add tests for a new ignore negative derivative
* add missing description when editing
* rename to ignore_negative_derivative
to increase clarity of which negative I mean
in case in the future we want a ignore_negative_value...
* use state_class=total_increasing to ignore the negative derivative
* remove ignore negative from the config
* add test for total_increasing_reset case
* add comments
* update test_total_increasing_reset with history tests
Also remove the last comment because the test is already clear
My existing comment there isn't unique to this unit test but applies to the entire component. The existing web documentation pointing to Wikipedia should suffice.
---------
Co-authored-by: Erik Montnemery <erik@montnemery.com>