* Abort flow if MAC-address can't be found
* Apply suggestions from code review
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Adjust homekit controller pairing errors back to a single step
* adjust test
* Revert "Adjust homekit controller pairing errors back to a single step"
This reverts commit e5ed89bbbb.
* Revert "adjust test"
This reverts commit c2e9f21a8401c144315260f6fdf71ea8060f8ca3.
* adjust
* prune
* prune
* merge
* Update tests
* remove debug
* adjust
* Multiple steps
* adjust the test
* Review: if not to pop
* Review: async_add_job --> async_add_executor_job
* Review: const
* Review: start logging messages with capital letter
* Review : UTC isoformated time --> fix "Invalid date""
* Fix hail forecast condition
* Review: _show_setup_form is a callback
* Fix update option
* Review: no icon for next_rain
* Review: inline cities form
* Review: store places as an instance attribute
* UNDO_UPDATE_LISTENER()
* Add support for slack bot icons via URL
* Removed as_user property from message send
* Use f-strings rather than concatenation
* Don't span lines with complex expression
If a device on the network presented a bad name, zeroconf
would throw zeroconf.BadTypeInNameException and the service
browser would die off. We now trap the exception and continue.
* Bump pysyncthru version to 0.7.0
This change includes a heavier refactoring, using a more reliable source for the device status and parsing display strings only for additional details
* Fix test flow to ensure a status is set
* Don't allow duplicate nightscout configs
* Fix nightscout translations
* Remove unnecessary should_poll method
* Remove SVG attribute, as it was duplicating the state
* Use aiohttp client session from HA
* Move validate_input outside the config class
* Use the entry unique_id on the sensor
* Move create entity logic
* Handle unexpected exception on Nightscout config
* update device
* add binary sensor
* updates post rebase
* fix entity type post rebase
* fix post rebase
* fix add entities
* fix name
* review comments
* Add ozw refresh_node_info websocket api
* Remove extra unsubs definition
* Remove unused bits from refresh_node_info websocket
* Add tests
* Add unsubscribe test
* Wait for response in unsubscribe test
* Squashed
* Fix requirements_all
* Update homeassistant/components/insteon/__init__.py
Only update options if the result is to create the entry.
Co-authored-by: J. Nick Koston <nick@koston.org>
* Update homeassistant/components/insteon/__init__.py
No return value needed.
Co-authored-by: J. Nick Koston <nick@koston.org>
* Ref RESULT_TYPE_CREATE_ENTRY correctly
* Return result back to import config process
* Make DOMAIN ref more clear
Co-authored-by: J. Nick Koston <nick@koston.org>
* Speed up OZW availability check
* Apply suggestions from code review
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Move DwdWeatherWarningsAPI to a library hosted on PyPI
PyPI library uses new DWD WFS API
WFS API allows a more detailed query with reduced data sent as return
Change CONF_REGION_NAME from Optional to Required because it was never really optional
Set attribute region_state to "N/A" because it is not available via the new API
Add attributes warning_i_parameters and warning_i_color
* Use constants instead of raw strings
Streamline methods state and device_state_attributes
* Wrap api, use UTC time
* Update homeassistant/components/dwd_weather_warnings/sensor.py
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Update homeassistant/components/dwd_weather_warnings/manifest.json
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* Add hourly forecast
* fix tests to assert for 2 entities created
* fix test to assert for 4 calls
* correct test tracking home number of calls
* fox tests
* fix test
* Apply suggestions from code review
* black
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Fix homekit_controller pairing retry
If the device was busy on the first pairing attempt, it
was not possible to retry.
* always restart pairing on recoverable execptions
* move code
* malformed pin is safe to restart
* make busy_error an abort
* switch max retries, simplify tests
* try pairing later
* try pairing later
* merge
* s/tlv_error/protocol_error/g
* Adjust wording
* Use global CONF_UNIQUE_ID for mqtt
* Update __init__.py
* Update __init__.py
* Update __init__.py
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
when changing the color for a hive light, keep the brightness at the
previous level.
Co-authored-by: Adam Charlton <ad5665@live.co.uk>
Co-authored-by: Adam Charlton <ad5665@live.co.uk>
* Add missing Short type to set_config_param
* Forgot to fix the for loop
* Remove leftover return
* Guard the for loop
* Changed from if to else
* Fixed list iteration for validating input
* Adjusted per linter
* [KODI] Fix casing issue
Alexa and the Services UI on HA feeds in a media type of "channel" for media type.
The Kodi code looks for a "CHANNEL" instead, as a result the functionality fails.
* Update homeassistant/components/kodi/media_player.py
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Update homeassistant/components/kodi/media_player.py
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Update homeassistant/components/kodi/media_player.py
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Update homeassistant/components/kodi/media_player.py
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Add more tests
* Add tests for sensor platform
* Add more tests
* More tests
* Simplify parsing of attributes
* Change Quality scale to platinum
* Patch the library in the manual update entity test
* Add unsupported condition icon test
* Do not patch _async_get_data
* Apply suggestions from code review
* Update config_flow.py
* Apply suggestions from code review
* Apply suggestions from code review
* Apply suggestions from code review
* Update tests/components/accuweather/test_weather.py
* Apply suggestions from code review
* Add return_value
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
Support the action.devices.commands.mute intent to mute and unmute
media_players that declare support for mute/unmute.
For media players with support for volume up/down, but no support for
setting the volume to a specific number, allow use of the
action.devices.commands.relativeMute intent to control volume up/down.
This will improve support for IR blasters and other open-loop
media_player integrations.
* Make sure groups are initialized before template sensors
This way users may use the `expand` function in templates to expand
groups and have HA listen for changes to group members.
Fixes#35872
* Patch async_setup_platform instead of async_setup
* Cleanup
* Use an event to avoid sleep
* Update tests/components/template/test_sensor.py
Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: J. Nick Koston <nick@koston.org>
* Don't set SUPPORT_EFFECT on DemoLight if there are no effects
This requires an update to the group test - previously the other lights
instantiated by the DemoLight component had nothing in ATTR_EFFECT_LIST, but
still had SUPPORT_EFFECT set. This appears to have resulted in the light
group test code setting an effect on the group and expecting it to apply to
all lights, but given that two of the bulbs didn't actually support any
effects (due to the empty ATTR_EFFECT_LIST) this seems like a broken
assumption and updating the test to verify only the bulb that supports
effects has had one applied seems reasonable.
* Add support for exposing light effects via Google Assistant
The LightEffects trait only supports a fixed (and small) list of lighting
effects, but we can expose them via the Modes trait - this requires saying
"Set (foo) effect to (bar)" which is a little clumsy, but at least makes it
possible.
* added device classes for electrical measurement
(cherry picked from commit 2409fe19ed43bef568a0cca826652867d3a2d71a)
* upadte power factor unit (%)
* update power factor unit (%)
* Add support for reload_on_update to _abort_if_unique_id_configured
async_update_entry now avoids firing update listeners and writing
the storage if there are no actual changes.
* Actually add the tests
* collapse branch
* Update homeassistant/config_entries.py
Co-authored-by: Franck Nijhof <git@frenck.dev>
* handle entries that lack the ability to reload
* reduce
* adjust konnected tests
* update axis tests
* fix blocking
* more mocking
* config flow tests outside of test_config_flow
* reduce
* volumio
* Update homeassistant/config_entries.py
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
* set reload_on_update=False for integrations that implement self._abort_if_unique_id_configured(updates= and a reload listen
* get rid of copy
* revert test change
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
```
2020-08-07 22:38:10 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection.3903193064] local variable 'response' referenced before assignment
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/rest_command/__init__.py", line 115, in async_service_handler
async with getattr(websession, method)(
File "/usr/local/lib/python3.8/site-packages/aiohttp/client.py", line 1012, in __aenter__
self._resp = await self._coro
File "/usr/local/lib/python3.8/site-packages/aiohttp/client.py", line 582, in _request
break
File "/usr/local/lib/python3.8/site-packages/aiohttp/helpers.py", line 586, in __exit__
raise asyncio.TimeoutError from None
asyncio.exceptions.TimeoutError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 125, in handle_call_service
await hass.services.async_call(
File "/usr/src/homeassistant/homeassistant/core.py", line 1281, in async_call
task.result()
File "/usr/src/homeassistant/homeassistant/core.py", line 1316, in _execute_service
await handler.func(service_call)
File "/usr/src/homeassistant/homeassistant/components/rest_command/__init__.py", line 137, in async_service_handler
_LOGGER.warning("Timeout call %s", response.url, exc_info=1)
UnboundLocalError: local variable 'response' referenced before assignment
```
* Update Tesla to use DataUpdateCoordinator
* Update Tesla to use DataUpdateCoordinator
* Fix linting errors
* Apply suggestions from code review
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Address requested changes
* Apply suggestions from code review
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Fix lint errors
* Remove controller from hass.data
Co-authored-by: Chris Talkington <chris@talkingtontech.com>
* Automatically switch between resume and start playing
* Fix Black issue
Weirdly when i run it i had an error `1544 files left unchanged, 3313 files failed to reformat.`
I didn't watch the commit check output afterward.
* track all settings and add service to update a setting
* sort setting types
* reduce frequency of updates due to the increase in API calls per update
* change dict call to a get in case audio settings aren't available
unlikely to occur but less error prone
* Update if statement to be more consistent
* revert changes to track all settings and store in state machine
* revert one more change
* force setting_type and setting_name to lowercase to make it easier to understand how to make service call
* make service calls even simpler by attempting to transform certain parameters as much as possible
* Support Next/Previous for InputSelector
* Update homeassistant/components/google_assistant/trait.py
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
* Adjust to match new version of _next_selected
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>