Commit Graph

39571 Commits (a28fd7d61b392d001b338f3bff2d5d68f5d50b4f)

Author SHA1 Message Date
Michael Chisholm a28fd7d61b
Config-flow for DLNA-DMR integration (#55267)
* Modernize dlna_dmr component: configflow, test, types

* Support config-flow with ssdp discovery
* Add unit tests
* Enforce strict typing
* Gracefully handle network devices (dis)appearing

* Fix Aiohttp mock response headers type to match actual response class

* Fixes from code review

* Fixes from code review

* Import device config in flow if unavailable at hass start

* Support SSDP advertisements

* Ignore bad BOOTID, fix ssdp:byebye handling

* Only listen for events on interface connected to device

* Release all listeners when entities are removed

* Warn about deprecated dlna_dmr configuration

* Use sublogger for dlna_dmr.config_flow for easier filtering

* Tests for dlna_dmr.data module

* Rewrite DMR tests for HA style

* Fix DMR strings: "Digital Media *Renderer*"

* Update DMR entity state and device info when changed

* Replace deprecated async_upnp_client State with TransportState

* supported_features are dynamic, based on current device state

* Cleanup fully when subscription fails

* Log warnings when device connection fails unexpectedly

* Set PARALLEL_UPDATES to unlimited

* Fix spelling

* Fixes from code review

* Simplify has & can checks to just can, which includes has

* Treat transitioning state as playing (not idle) to reduce UI jerking

* Test if device is usable

* Handle ssdp:update messages properly

* Fix _remove_ssdp_callbacks being shared by all DlnaDmrEntity instances

* Fix tests for transitioning state

* Mock DmrDevice.is_profile_device (added to support embedded devices)

* Use ST & NT SSDP headers to find DMR devices, not deviceType

The deviceType is extracted from the device's description XML, and will not
be what we want when dealing with embedded devices.

* Use UDN from SSDP headers, not device description, as unique_id

The SSDP headers have the UDN of the embedded device that we're interested
in, whereas the device description (`ATTR_UPNP_UDN`) field will always be
for the root device.

* Fix DMR string English localization

* Test config flow with UDN from SSDP headers

* Bump async-upnp-client==0.22.1, fix flake8 error

* fix test for remapping

* DMR HA Device connections based on root and embedded UDN

* DmrDevice's UpnpDevice is now named profile_device

* Use device type from SSDP headers, not device description

* Mark dlna_dmr constants as Final

* Use embedded device UDN and type for unique ID when connected via URL

* More informative connection error messages

* Also match SSDP messages on NT headers

The NT header is to ssdp:alive messages what ST is to M-SEARCH responses.

* Bump async-upnp-client==0.22.2

* fix merge

* Bump async-upnp-client==0.22.3

Co-authored-by: Steven Looman <steven.looman@gmail.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-27 15:47:01 -05:00
RenierM26 b15f11f46a
Discover Switchbot MAC in config flow (#56616)
* Update config_flow.py

* Switchbot Config_flow discover mac instead of needing to type it.

* Do not show already configured devices in config flow, abort if no unconfigured devices.

* Apply suggestions from code review

Co-authored-by: J. Nick Koston <nick@koston.org>

* Move MAC to top of config flow form dict.

* Update homeassistant/components/switchbot/config_flow.py

Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-27 15:12:40 -05:00
Teemu R b40d229369
Rework TPLink integration to use python-kasa (#56701)
Co-authored-by: J. Nick Koston <nick@koston.org>
Co-authored-by: Teemu R. <tpr@iki.fi>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-09-27 14:11:55 -05:00
Hung Nguyen 7a2bc130b7
Bump elkm1-lib to 1.0.0 (#56703) 2021-09-27 14:10:09 -05:00
Bastien Gautier 806fdc0095
Patch coinbase (#56426)
* Add Clover Finance coin to coinbase

* Add Fetch.ai coin to coinbase

* Fix typo
2021-09-27 20:39:43 +02:00
Marc Mueller 2f4e992662
Use EntityDescription - daikin (#55929) 2021-09-27 20:26:10 +02:00
Raman Gupta f0e0b41f77
Use entity attributes for vizio integration (#56093) 2021-09-27 20:20:15 +02:00
Marc Mueller 0dcd8b32ab
Use EntityDescription - meteo_france (#55677) 2021-09-27 19:40:55 +02:00
Marc Mueller 71ce858378
Use EntityDescription - toon (#55035) 2021-09-27 19:37:12 +02:00
Erik Montnemery fe66d6295c
Improve migration to recorder schema version 21 (#56204) 2021-09-27 19:31:40 +02:00
Steffen Zimmermann e5642a8648
Add state_class measurements in wiffi integration (#54279)
* add support for state_class measurements in wiffi integration

* use new STATE_CLASS_TOTAL_INCREASING for metered entities

like
- amount of rainfall per hour/day
- rainfall hours per day
- sunshine hours per day

* Update homeassistant/components/wiffi/sensor.py

Co-authored-by: Greg <greg.diehl.gtd@gmail.com>

Co-authored-by: Greg <greg.diehl.gtd@gmail.com>
2021-09-27 18:28:20 +02:00
Erik Montnemery 4d7e3cde5a
Minor cleanup and test coverage improvement for MQTT (#55265) 2021-09-27 17:45:52 +02:00
Franck Nijhof eae828a15a
Upgrade lupupy to 0.0.21 (#56636) 2021-09-27 17:42:13 +02:00
Michael Chisholm 805e73f78c
Add UPNP device connection for Sonos (#56702) 2021-09-27 17:36:47 +02:00
Marc Mueller 70cc6295b5
Use EntityDescription - hydrawise (#55924) 2021-09-27 17:35:09 +02:00
Fredrik Oterholt 4d433e18ac
Add more sensor types for airthings devices (#56706)
* add additional sensor types for airthings devices

* remove "out of ten" unit

* change unit on rssi

* remove device class for light

* disable by default
2021-09-27 13:27:02 +02:00
Marius 4ce7166afd
Add node sensor status icons (#56137)
Co-authored-by: kpine <keith.pine@gmail.com>
Co-authored-by: Raman Gupta <7243222+raman325@users.noreply.github.com>
2021-09-27 12:50:14 +02:00
Marc Mueller 83b1b3e92c
Use EntityDescription - tellduslive (#55928) 2021-09-27 12:28:58 +02:00
Michael f2debf5c01
Remove unnecessary extra attribute from Pi-hole sensors (#56076) 2021-09-27 12:27:03 +02:00
jan iversen 6da548b56a
Strictly type modbus cover.py (#56381) 2021-09-27 12:26:25 +02:00
jan iversen 50f97b26eb
Strictly type modbus climate.py (#56380) 2021-09-27 12:25:05 +02:00
Simone Chemelli b612e16120
Add current and latest firmware info to Synology_dsm (#56460) 2021-09-27 12:23:26 +02:00
Erik Montnemery 58f465f271
Don't reset meter when last_reset is set to None (#56609) 2021-09-27 12:17:09 +02:00
jjlawren 931cf4eaab
Improve Sonos handling of TuneIn stations (#56479) 2021-09-27 12:07:14 +02:00
Robert Svensson ca6b53c16d
Remove UniFi config entry reference from device when removing last entity of said device (#56501) 2021-09-27 12:04:29 +02:00
Erik Montnemery efe467217a
Don't round in energy cost sensor (#56258) 2021-09-27 12:01:17 +02:00
Aaron Bach 56b94d6809
Simplify native value property for WattTime (#56664) 2021-09-27 11:58:51 +02:00
Franck Nijhof 4f5d6b8ba1
Upgrade sentry-sdk to 1.4.1 (#56707) 2021-09-27 11:20:43 +02:00
Erik Montnemery 14a1bb423c
Add is_number template filter and function (#56705) 2021-09-27 10:47:57 +02:00
Fabian Affolter e4dc646237
Upgrade praw to 7.4.0 (#56682) 2021-09-27 08:48:21 +02:00
Michael Chisholm 6c2674734a
SSDP starts config flow only for alive devices (#56551)
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-27 08:39:22 +02:00
dependabot[bot] 0f313ec73c
Bump home-assistant/builder from 2021.07.0 to 2021.09.0 (#56704)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-09-27 08:37:54 +02:00
J. Nick Koston 0fce9f39b3
Avoid checking if a package is installed if it already failed (#56698) 2021-09-26 22:32:25 -07:00
Fabian Affolter 01bd3ff138
Upgrade sendgrid to 6.8.2 (#56688) 2021-09-27 07:03:29 +02:00
Fabian Affolter 8884e9691e
Upgrade TwitterAPI to 2.7.5 (#56687) 2021-09-27 07:03:09 +02:00
Fabian Affolter 55c9abc58d
Upgrade discord.py to 1.7.3 (#56686) 2021-09-27 07:02:46 +02:00
Fabian Affolter 44a4507b51
Upgrade requests to 2.26.0 (#56683)
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-26 21:44:28 -05:00
Fabian Affolter 115d34f55a
Set certifi to >=2021.5.30 (#56679)
Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-26 21:19:30 -05:00
J. Nick Koston 7ab6c82ad2
Drop defusedxml dep from ssdp manifest (#56699) 2021-09-26 19:49:43 -05:00
J. Nick Koston 26e031984b
Ensure sonos always gets ssdp callbacks from searches (#56591) 2021-09-26 17:16:03 -05:00
J. Nick Koston 6399730d2f
Optimize SSDP matching (#56622)
* Optimize SSDP matching

* tweak

* remove

* remove dupe
2021-09-26 16:30:39 -05:00
J. Nick Koston f268227d64
Implement retry and backoff strategy for requirements install (#56580)
Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2021-09-26 14:47:03 -05:00
Raman Gupta 8716aa011a
Add support for multilevel switch CC select entities (#56656)
* Add support for multilevel switch CC select entities

* Use state names from docs and include more device identifiers from device DB

* black

* pylint

* type fix

* Add failure scenario test

* Update homeassistant/components/zwave_js/select.py

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

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-09-26 14:22:41 -04:00
Fabian Affolter 2326e3ed94
Upgrade voluptuous to 0.12.2 (#56680) 2021-09-26 18:59:00 +02:00
J. Nick Koston 52410ff0d7
Ensure yeelight can be unloaded when device is offline (#56464) 2021-09-26 09:54:43 -07:00
J. Nick Koston 26f73779cc
Avoid enabling ipv6 dual stack for zeroconf on unsupported platforms (#56584) 2021-09-26 09:51:34 -07:00
J. Nick Koston f74291ccb6
Expose the ability to move an entity/device between config entries (#56661) 2021-09-26 09:50:57 -07:00
Marc Mueller e35e584b60
Use EntityDescription - sht31 (#56435)
* Use EntityDescription - sht31

* Add device_class for humidity

* Fix monitored conditions

* Add pylint disable
2021-09-26 18:19:36 +02:00
Fabian Affolter 65bce33a63
Upgrade emoji to 1.5.0 (#56684) 2021-09-26 15:09:13 +02:00
Franck Nijhof bfefe82605
Upgrade pre-commit to 2.15.0 (#56677) 2021-09-26 14:47:47 +02:00