diff --git a/devolo_home_control_api/backend/__init__.py b/devolo_home_control_api/backend/__init__.py index a8d9f64..53c77e6 100644 --- a/devolo_home_control_api/backend/__init__.py +++ b/devolo_home_control_api/backend/__init__.py @@ -38,4 +38,4 @@ "vfs.hdm": "_led", } -__all__ = ["Mprm", "MESSAGE_TYPES"] +__all__ = ["MESSAGE_TYPES", "Mprm"] diff --git a/devolo_home_control_api/backend/mprm_rest.py b/devolo_home_control_api/backend/mprm_rest.py index f5e0e78..918609e 100644 --- a/devolo_home_control_api/backend/mprm_rest.py +++ b/devolo_home_control_api/backend/mprm_rest.py @@ -9,7 +9,7 @@ from typing import Any from requests import Session -from requests.exceptions import ConnectionError, ReadTimeout +from requests.exceptions import ConnectionError, ReadTimeout # noqa: A004 from devolo_home_control_api.devices import Gateway from devolo_home_control_api.exceptions import GatewayOfflineError diff --git a/devolo_home_control_api/helper/__init__.py b/devolo_home_control_api/helper/__init__.py index 7e5f60f..b94b1dd 100644 --- a/devolo_home_control_api/helper/__init__.py +++ b/devolo_home_control_api/helper/__init__.py @@ -1,5 +1,5 @@ """Helper functions used in the package.""" -from .string import camel_case_to_snake_case +from .names import camel_case_to_snake_case from .uid import ( get_device_type_from_element_uid, get_device_uid_from_element_uid, @@ -10,9 +10,9 @@ __all__ = [ "camel_case_to_snake_case", + "get_device_type_from_element_uid", "get_device_uid_from_element_uid", "get_device_uid_from_setting_uid", - "get_sub_device_uid_from_element_uid", - "get_device_type_from_element_uid", "get_home_id_from_device_uid", + "get_sub_device_uid_from_element_uid", ] diff --git a/devolo_home_control_api/helper/string.py b/devolo_home_control_api/helper/names.py similarity index 93% rename from devolo_home_control_api/helper/string.py rename to devolo_home_control_api/helper/names.py index b63bfd5..88b241c 100644 --- a/devolo_home_control_api/helper/string.py +++ b/devolo_home_control_api/helper/names.py @@ -1,5 +1,5 @@ """ -Helper functions for converting strings. +Helper functions for converting names. The information we get from the gateway is often returned in a way, that does not fit to our naming convention. This helper function make names fit in nicely. diff --git a/pyproject.toml b/pyproject.toml index 4add274..3b3423d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ ignore_missing_imports = true [tool.ruff] line-length = 127 -lint.ignore = ["ANN101", "ANN102", "ANN401", "B024", "COM812", "D203", "D205", "D212", "EM", "FBT001", "N818", "TCH", "TRY300", "TRY400"] +lint.ignore = ["ANN401", "B024", "COM812", "D203", "D205", "D212", "EM", "FBT001", "N818", "TCH", "TRY300", "TRY400"] lint.select = ["ALL"] target-version = "py37"