Commit Graph

415 Commits (b3b5ca9b9592f2df4ff5e2b740cb5c2b52cd2498)

Author SHA1 Message Date
Ville Skyttä 2794ab1782
Fix huawei_lte current month up/download sensor error on delete (#100506)
Deleting one of them prematurely deleted the last reset item
subscription that is shared between the two.
2023-09-17 18:11:44 +02:00
Erik Montnemery d1afcd773f
Revert "Cache entity properties that are never expected to change in the base class" (#100422)
Revert "Cache entity properties that are never expected to change in the base class (#95315)"

This reverts commit 042776ebb8.
2023-09-15 11:25:24 +02:00
J. Nick Koston 042776ebb8
Cache entity properties that are never expected to change in the base class (#95315) 2023-09-14 17:48:48 -05:00
J. Nick Koston 6a7d5a0fd4
Use more shorthand attributes in huawei_lte binary_sensor (#100211) 2023-09-12 19:45:44 +02:00
Ville Skyttä c287bd1a3b
Remove pylint configs flagged by useless-suppression (#99081) 2023-08-26 17:46:03 +03:00
Erik Montnemery 045c327928
Move DeviceInfo from entity to device registry (#98149)
* Move DeviceInfo from entity to device registry

* Update integrations
2023-08-10 22:04:26 -04:00
Erik Montnemery 5b93017740
Correct huawei_lte device info (#96481) 2023-07-13 12:15:28 -04:00
Paulus Schoutsen 7859be6481
Add deduplicate translations script (#96384)
* Add deduplicate script

* Fix forecast_solar incorrect key with space

* Fix utf-8

* Do not create references to other arbitrary other integrations

* Add commented code to only allow applying to referencing integrations

* Tweak

* Bug fix

* Add command line arg for limit reference

* never suggest to update common keys

* Output of script

* Apply suggestions from code review

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>

---------

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
2023-07-13 11:52:50 -04:00
Ville Skyttä 127fbded18
Fix huawei_lte suspend_integration service URL description (#96450)
Copy-pasto from resume_integration.
2023-07-12 22:04:18 -04:00
Franck Nijhof 7bc90297d2
Migrate integration services (G-H) to support translations (#96372) 2023-07-12 12:31:26 +02:00
Erik Montnemery 2406b235b4
Name unnamed binary sensors by their device class (#92940)
* Name unnamed binary sensors by their device class

* Update type annotations

* Fix loading of entity component translations

* Add test

* Update integrations

* Set abode and rfxtrx binary_sensor name to None

* Revert changes in homekit_controller
2023-06-13 19:48:54 +02:00
Franck Nijhof c3936e6f14
Replace isort with ruff (#94302) 2023-06-08 23:43:56 +02:00
Ville Skyttä e949344dd9
Huawei LTE connection management cleanups (#85929)
* Disconnect rather than just logout at end of config flow

Neither the connection or the requests session will be reused, so
there's no reason just to logout. Do all of the connection closure
so we get all of huawei-lte-api's cleanups explicitly done.

* Name connect functions consistently, analoguous to disconnect
2023-05-16 20:34:03 +03:00
Franck Nijhof ed3c1d9b59
Fix incorrect entity category for huawei_lte sensors (#92235) 2023-04-29 20:21:38 -04:00
epenet 42b74e7f56
Adjust entity registry access in integrations (3) (#88948) 2023-03-01 08:24:56 +01:00
Ville Skyttä 93f23e7523
Do not round Huawei LTE LTE frequency values (#88127)
Suggest display precision 0 instead.

While at it, fix source info in frequency formatter docstring.
2023-02-15 15:28:35 +01:00
Erik Montnemery cc564026fa
Move EntityCategory to homeassistant.const (#87792)
* Move EntityCategory to homeassistant.const

* Fix more imports
2023-02-09 20:15:37 +01:00
Erik Montnemery 899adef590
Sort manifests 4 (#87025) 2023-02-08 20:27:05 +01:00
Franck Nijhof 939eef3b28
Remove translations from Core (#87543)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2023-02-06 15:06:43 +01:00
Franck Nijhof ca1a12898c
Enable Ruff D212 (#87347) 2023-02-03 23:08:48 +01:00
GitHub Action ce79b26ab6 [ci skip] Translation update 2023-02-03 00:25:31 +00:00
GitHub Action 0f80932709 [ci skip] Translation update 2023-02-02 00:25:01 +00:00
GitHub Action 0f6f63da64 [ci skip] Translation update 2023-01-29 00:26:29 +00:00
GitHub Action 072f228e4d [ci skip] Translation update 2023-01-28 00:23:36 +00:00
Franck Nijhof e738924780
Enable Ruff SIM105 (#86759)
* Enable Ruff SIM105

* Adjust existing cases
2023-01-26 21:06:22 -05:00
GitHub Action 71d7098530 [ci skip] Translation update 2023-01-27 00:25:12 +00:00
GitHub Action 7ab88fa713 [ci skip] Translation update 2023-01-26 00:23:39 +00:00
GitHub Action 9636fe4602 [ci skip] Translation update 2023-01-25 00:24:21 +00:00
Ville Skyttä 5f0adfe6e4
Add missing config flow abort strings (#86180)
* Add missing `already_configured` and `already_in_progress` abort strings

* Note required strings.json entries in config_entries aborting functions
2023-01-24 08:59:32 +02:00
GitHub Action d1ecc418bb [ci skip] Translation update 2023-01-19 00:25:04 +00:00
GitHub Action d2e11797f8 [ci skip] Translation update 2023-01-17 00:24:30 +00:00
Ville Skyttä f0e6f45e43
Remove signal strength state class from Huawei LTE transmit power sensor (#85973)
Co-authored-by: Franck Nijhof <git@frenck.dev>
2023-01-16 23:24:50 +01:00
GitHub Action b81453cb6b [ci skip] Translation update 2023-01-16 00:24:22 +00:00
GitHub Action 77f9548e51 [ci skip] Translation update 2023-01-15 00:25:52 +00:00
GitHub Action dffc913f9e [ci skip] Translation update 2023-01-14 00:22:57 +00:00
Ville Skyttä a5a079fb06
Huawei LTE sensor improvements (#84019)
* Use `None` for unknown states consistently

* Use huawei_lte_api NetworkModeEnum instead of magic strings

* Recognize some new sensor items

* Exclude current day duration sensor

* Fix current month upload/download types

* Add current day transfer

* Extract lambdas used in multiple spots to named functions

* Formatter naming consistency improvements
2023-01-13 18:27:57 +01:00
Ville Skyttä ae302bbec0
Make use of str.removeprefix and .removesuffix (#85584) 2023-01-13 12:19:38 +01:00
Ville Skyttä 4c31317c06
Key Huawei LTE routers in hass.data by config entry rather than unique id (#85788)
Key routers in hass.data by config entry rather than unique id

There's no particular reason to key them by the unique id; the config
entry id is a stronger, always available guarantee, and a much more
common convention across the HA codebase.

At some point, we might conceivably support devices we can't find a
proper unique id for; this would work for that purpose as well.
2023-01-13 09:20:24 +01:00
Ville Skyttä c625051665
Improve Huawei LTE SSDP inclusion (#85572)
* Probe Huawei LTE API for device support on SSDP match

More or less as expected, the loosening of SSDP/UPnP data matches done
in #81643 started to yield false positives, as in #85402.

Coming up with robust matches solely based on the SSDP/UPnP data still
does not seem possible, so keep the matches as loose as they were made,
but additionally invoke a probe request on the API to determine if the
device looks like a supported one.

* Probe only after unique id checks

Prevents throwaway probes for discoveries already in progress.

* Fix SSDP result URL test, add missing assert on it
2023-01-12 06:47:38 +01:00
Ville Skyttä ccd7f09de6
Upgrade huawei-lte-api to 1.6.11 (#85669) 2023-01-11 17:44:55 +01:00
GitHub Action b3ab0a0199 [ci skip] Translation update 2022-12-29 00:23:20 +00:00
GitHub Action cfa08c5229 [ci skip] Translation update 2022-12-15 00:24:38 +00:00
Ville Skyttä f02b6f1119
Huawei LTE SSDP improvements (#81643)
* Recognize more SSDP friendly names as "ours"

* Trigger on SoyeaLink devices

* Pass discovered URL through context, it does not persist via user_input

* Use manufacturer from SSDP

* Actually use serial number if available, update URL for configured

* Remove heuristic friendly name filtering against non-LTE devices
2022-12-14 23:48:25 +01:00
epenet b7b7cdcfcf
Refactor Huawei LTE to use Entity Description (#83904)
* Refactor Huawei LTE to use Entity Description

* Apply suggestions from code review

Co-authored-by: Ville Skyttä <ville.skytta@iki.fi>

Co-authored-by: Ville Skyttä <ville.skytta@iki.fi>
2022-12-13 19:48:46 +01:00
GitHub Action f19a1147fe [ci skip] Translation update 2022-12-11 00:26:24 +00:00
epenet 535aba10ee
Use DataRate unit and device class in integrations (#83610) 2022-12-10 11:41:44 +01:00
GitHub Action f25017313a [ci skip] Translation update 2022-12-09 00:24:29 +00:00
GitHub Action 1f3e5fb4fc [ci skip] Translation update 2022-12-07 00:24:08 +00:00
GitHub Action 03154e1d83 [ci skip] Translation update 2022-12-03 00:21:50 +00:00
GitHub Action 230b50d099 [ci skip] Translation update 2022-11-29 00:26:01 +00:00