Commit graph

59769 commits

Author SHA1 Message Date
Yuxin Wang
490a0908d4
Avoiding testing implementation details in apcupsd tests (#88772)
Fix apcupsd tests.
2023-02-26 07:57:31 +01:00
J. Nick Koston
327edabb64
Fix checking if a package is installed on py3.11 (#88768)
pkg_resources is abandoned and we need to move away
from using it https://github.com/pypa/pkg_resources

In the mean time we need to keep it working. This fixes
a new exception in py3.11 when a module is not installed
which allows proper fallback to pkg_resources.Requirement.parse
when needed

```
2023-02-25 15:46:21.101 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/opt/homebrew/lib/python3.11/site-packages/aiohttp/web_protocol.py", line 433, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/aiohttp/web_middlewares.py", line 117, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/forwarded.py", line 100, in forwarded_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/ban.py", line 80, in ban_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/auth.py", line 235, in auth_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/view.py", line 146, in handle
    result = await result
             ^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/config/config_entries.py", line 148, in post
    return await super().post(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/components/http/data_validator.py", line 72, in wrapper
    result = await method(view, request, data, *args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/helpers/data_entry_flow.py", line 71, in post
    result = await self._flow_mgr.async_init(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/config_entries.py", line 826, in async_init
    flow, result = await task
                   ^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/config_entries.py", line 844, in _async_init
    flow = await self.async_create_flow(handler, context=context, data=data)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/config_entries.py", line 950, in async_create_flow
    await async_process_deps_reqs(self.hass, self._hass_config, integration)
  File "/Users/bdraco/home-assistant/homeassistant/setup.py", line 384, in async_process_deps_reqs
    await requirements.async_get_integration_with_requirements(
  File "/Users/bdraco/home-assistant/homeassistant/requirements.py", line 52, in async_get_integration_with_requirements
    return await manager.async_get_integration_with_requirements(domain)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/requirements.py", line 171, in async_get_integration_with_requirements
    await self._async_process_integration(integration, done)
  File "/Users/bdraco/home-assistant/homeassistant/requirements.py", line 186, in _async_process_integration
    await self.async_process_requirements(
  File "/Users/bdraco/home-assistant/homeassistant/requirements.py", line 252, in async_process_requirements
    await self._async_process_requirements(name, missing)
  File "/Users/bdraco/home-assistant/homeassistant/requirements.py", line 284, in _async_process_requirements
    installed, failures = await self.hass.async_add_executor_job(
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/python@3.11/3.11.1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/requirements.py", line 113, in _install_requirements_if_missing
    if pkg_util.is_installed(req) or _install_with_retry(req, kwargs):
       ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/bdraco/home-assistant/homeassistant/util/package.py", line 40, in is_installed
    pkg_resources.get_distribution(package)
  File "/opt/homebrew/lib/python3.11/site-packages/pkg_resources/__init__.py", line 478, in get_distribution
    dist = get_provider(dist)
           ^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/pkg_resources/__init__.py", line 354, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
                                            ~~~~~~~~~~~~~~~~~~~~~~~~~^^^
IndexError: list index out of range
``
2023-02-25 22:47:18 -05:00
Robert Svensson
b4a3a663cf
Simplify adding unifi entities (#88571) 2023-02-25 08:18:49 -08:00
avee87
1519a78567
Fix log message in recorder on total_increasing reset (#88710) 2023-02-25 12:05:24 +01:00
J. Nick Koston
57360a7528
Prevent new discovery flows from being created when stopping (#88743) 2023-02-25 12:02:07 +01:00
J. Nick Koston
7b61d3763b
Log futures that are blocking shutdown stages (#88736) 2023-02-25 12:01:30 +01:00
Joakim Sørensen
0f204d6502
Remove homeassistant_hardware after dependency from zha (#88751) 2023-02-25 12:01:01 +01:00
Arturo
0a3a8c4b3c
Fix matter light color capabilities bit map (#88693)
* Adds matter light color capabilities bit map

* Fixed matter light hue and saturation test
2023-02-25 10:25:04 +01:00
Rami Mosleh
091305fc57
Use DataUpdateCoordinator for islamic_prayer_times (#73893)
* use DataUpdateCoordinator for islamic_prayer_times

Add suggested type hints

remove uneccassry options setup

* Use entity_description for sensors

* move coordinator into separate file, sensor_descptions to sensor.py

* add strict typing

* revert strict typing

* fix test coverage

* revert unrelated file changes

* fix sorting

* Update code based on review

* add missing type hint

* more missing type hints

* Update homeassistant/components/islamic_prayer_times/coordinator.py

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

* remove config_entry parameter

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2023-02-25 10:05:51 +01:00
Austin Mroczek
3499d60401
Bump total_connect_client to v2023.2 (#88729)
* bump total_connect_client to v2023.2

* Trigger Build
2023-02-25 09:20:17 +01:00
Artem Draft
f18c0bf626
Pass assumed_state property in universal media player (#87846)
Pass assumed_state property in universal media player
2023-02-25 07:43:58 +01:00
J. Nick Koston
f52a5f6965
Make hass.async_stop an untracked task (#88738) 2023-02-24 23:11:48 -05:00
Álvaro Fernández Rojas
1edef73c9a
Update aioqsw v0.3.2 (#88695)
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2023-02-24 22:10:00 -05:00
mkmer
5a365788b5
Add missing reauth strings to Honeywell (#88733)
Add missing reauth strings
2023-02-24 21:49:49 -05:00
Bram Kragten
a60fd18386
Update frontend to 20230224.0 (#88721) 2023-02-24 21:39:59 -05:00
J. Nick Koston
0223058d25
Reduce overhead to save json data to postgresql (#88717)
* Reduce overhead to strip nulls from json

* Reduce overhead to strip nulls from json

* small cleanup
2023-02-24 21:37:36 -05:00
J. Nick Koston
7b2e743a6b
Fix timeout in purpleapi test (#88715)
7423099757
2023-02-24 14:33:25 -05:00
J. Nick Koston
69a3738bdb
Fix migration failing when existing data has duplicates (#88712) 2023-02-24 11:41:44 -06:00
Jon Caruana
e69091c6db
Use strict typing for LiteJet integration (#88629)
* Strict typing for LiteJet.

* Add test for new check.

* PR feedback.

* PR feedback.
2023-02-24 17:51:48 +01:00
J. Nick Koston
ee7dfdae30
Bump aioesphomeapi to 13.4.1 (#88703)
changelog: https://github.com/esphome/aioesphomeapi/releases/tag/v13.4.1
2023-02-24 11:09:12 -05:00
epenet
fdc06c2fc2
Improve type hint in webostv trigger (#88599)
Improve type hint in webostv trigger
2023-02-24 16:54:02 +01:00
StefanIacobLivisi
ba929dfc79
Bump aiolivisi to 0.0.16 (#88700)
Increment aiolivisi library version
2023-02-24 15:22:30 +01:00
epenet
753c790a25
Use async_timeout in integrations (#88697) 2023-02-24 08:13:03 -05:00
Thomas Dietrich
ee8f746808
Change statistics component ownership (#88692) 2023-02-24 08:11:40 -05:00
stickpin
84823d2fcf
Upgrade caldav to 1.1.3 (#88681)
* Update caldav to 1.1.3

* update caldav to 1.1.3

* update caldav to 1.1.3

---------

Co-authored-by: Allen Porter <allen@thebends.org>
2023-02-24 06:32:59 +00:00
J. Nick Koston
0ae2fdc08b
Switch samsungtv to use async_timeout to avoid task creation (#88679)
wait_for creates a task, async_timeout does the same work
and avoids the task creation
2023-02-23 23:00:08 -05:00
Erik Montnemery
d90ee85118
Allow conditions to be implemented in platforms (#88509)
* Allow conditions to be implemented in platforms

* Update tests

* Tweak typing

* Rebase fixes
2023-02-23 22:30:51 -05:00
Franck Nijhof
2f826a6f86
Modernize uptime tests (#88636)
* Modernize uptime tests

* Fix tests
2023-02-23 22:15:20 -05:00
David Poll
af49b98475
Enable jinja loop controls (break/continue) (#88625)
Enables jinja loop controls (break/continue)
2023-02-23 22:14:28 -05:00
puddly
9575cd9161
Name the Yellow-internal radio and multi-PAN addon as ZHA serial ports (#88208)
* Expose the Yellow-internal radio and multi-PAN addon as named serial ports

* Remove the serial number if it isn't available

* Use consistent names for the addon and Zigbee radio

* Add `homeassistant_hardware` and `_yellow` as `after_dependencies`

* Handle `hassio` not existing when listing serial ports

* Add unit tests
2023-02-23 20:52:53 -05:00
J. Nick Koston
f0b029c363
Bump mopeka_iot_ble to 0.4.1 (#88680)
* Bump mopeka_iot_ble to 0.4.1

closes #88232

* adjust tests
2023-02-23 20:52:31 -05:00
Michael Hansen
a71487a42b
Make a copy of matching states so translated state names can be used (#88683) 2023-02-23 20:50:23 -05:00
Michael Hansen
d5f1713498
Include binary_sensor in default Assist exposed domains (#88682) 2023-02-23 19:40:10 -05:00
Marcel van der Veldt
301144993c
Fix support for Bridge(d) and composed devices in Matter (#88662)
* Refactor discovery of entities to support composed and bridged devices

* Bump library version to 3.1.0

* move discovery schemas to platforms

* optimize a tiny bit

* simplify even more

* fixed bug in light platform

* fix color control logic

* fix some issues

* Update homeassistant/components/matter/discovery.py

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

* fix some tests

* fix light test

---------

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2023-02-23 14:58:37 -05:00
Bram Kragten
e0601530a0
Update frontend to 20230223.0 (#88677) 2023-02-23 13:38:07 -05:00
Allen Porter
e1e0400b16
Fix local calendar issue with events created with fixed UTC offsets (#88650)
Fix issue with events created with UTC offsets
2023-02-23 13:37:15 -05:00
Raman Gupta
5739782877
Add support for firmware target in zwave_js FirmwareUploadView (#88523)
* Add support for firmware target in zwave_js FirmwareUploadView

fix

* Update tests/components/zwave_js/test_api.py

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

* Update tests/components/zwave_js/test_api.py

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

* Update tests/components/zwave_js/test_api.py

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

* Update tests/components/zwave_js/test_api.py

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

* fix types

* Switch back to using Any

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2023-02-23 13:24:55 -05:00
Franck Nijhof
6112793b19
Modernize Twentemilieu tests (#88640) 2023-02-23 10:26:17 -05:00
Franck Nijhof
f8314fe007
Update apprise to 1.3.0 (#88658) 2023-02-23 10:23:03 -05:00
epenet
dac3c7179f
Add missing async_setup_entry mock in openuv (#88661) 2023-02-23 10:22:39 -05:00
Franck Nijhof
6511b3f355
Update pre-commit to 3.1.0 (#88657) 2023-02-23 10:59:47 +01:00
Artem Draft
6474297d1f
Browse media support in universal media player (#85668)
Allow forward and override browse media in universal media player
2023-02-23 09:17:46 +01:00
J. Nick Koston
27ebee1501
Fix untrapped exceptions during Yale Access Bluetooth first setup (#88642) 2023-02-23 08:18:55 +01:00
starkillerOG
23b52025f9
Bump reolink-aio to 0.5.1 and check if update supported (#88641) 2023-02-23 08:13:03 +01:00
epenet
87dc692a20
Use json_loads_object in alexa (#88610) 2023-02-22 22:01:32 +01:00
Erik Montnemery
473db48943
Bump python-otbr-api to 1.0.4 (#88613)
* Bump python-otbr-api to 1.0.4

* Adjust tests
2023-02-22 15:31:02 -05:00
Franck Nijhof
aa3657e071
Bump version to 2023.4.0dev0 (#88630) 2023-02-22 21:29:49 +01:00
puddly
2a819f23c1
Disable the ZHA bellows UART thread when connecting to a TCP coordinator (#88202)
Disable the bellows UART thread when connecting to a TCP coordinator
2023-02-22 15:12:55 -05:00
Paulus Schoutsen
c6ff79aa0e
Error checking for OTBR (#88620)
* Error checking for OTBR

* Other errors in flow too

* Tests
2023-02-22 20:58:11 +01:00
J. Nick Koston
3ebb2fc3a9
Fix handling of HomeKit sources with unsafe characters (#88280)
fixes #87049
2023-02-22 14:33:27 -05:00