python-roborock 3.10.10__tar.gz → 3.11.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_roborock-3.10.10 → python_roborock-3.11.1}/PKG-INFO +1 -1
- {python_roborock-3.10.10 → python_roborock-3.11.1}/pyproject.toml +1 -1
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/v1/v1_code_mappings.py +7 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/v1/v1_containers.py +6 -2
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/mqtt/roborock_session.py +16 -2
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/mqtt/session.py +14 -1
- {python_roborock-3.10.10 → python_roborock-3.11.1}/.gitignore +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/LICENSE +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/README.md +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/api.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/broadcast_protocol.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/callbacks.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/cli.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/cloud_api.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/command_cache.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/const.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q10/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q10/b01_q10_code_mappings.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q10/b01_q10_containers.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q7/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q7/b01_q7_code_mappings.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q7/b01_q7_containers.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/code_mappings.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/containers.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/dyad/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/dyad/dyad_code_mappings.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/dyad/dyad_containers.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/v1/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/v1/v1_clean_modes.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/zeo/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/zeo/zeo_code_mappings.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/zeo/zeo_containers.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/device_features.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/README.md +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/a01_channel.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/b01_channel.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/cache.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/channel.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/device.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/device_manager.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/file_cache.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/local_channel.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/mqtt_channel.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/a01/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/b01/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/traits_mixin.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/child_lock.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/clean_summary.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/command.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/common.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/consumeable.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/device_features.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/do_not_disturb.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/dust_collection_mode.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/flow_led_status.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/home.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/led_status.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/map_content.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/maps.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/network_info.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/rooms.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/routines.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/smart_wash_params.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/status.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/valley_electricity_timer.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/volume.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/wash_towel_mode.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/v1_channel.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/exceptions.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/map/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/map/map_parser.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/mqtt/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/mqtt/health_manager.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/protocol.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/protocols/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/protocols/a01_protocol.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/protocols/b01_protocol.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/protocols/v1_protocol.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/py.typed +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/roborock_future.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/roborock_message.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/roborock_typing.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/util.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_1_apis/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_1_apis/roborock_client_v1.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_1_apis/roborock_local_client_v1.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_1_apis/roborock_mqtt_client_v1.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_a01_apis/__init__.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_a01_apis/roborock_client_a01.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_a01_apis/roborock_mqtt_client_a01.py +0 -0
- {python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/web_api.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-roborock
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.11.1
|
|
4
4
|
Summary: A package to control Roborock vacuums.
|
|
5
5
|
Project-URL: Repository, https://github.com/humbertogontijo/python-roborock
|
|
6
6
|
Project-URL: Documentation, https://python-roborock.readthedocs.io/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "python-roborock"
|
|
3
|
-
version = "3.
|
|
3
|
+
version = "3.11.1"
|
|
4
4
|
description = "A package to control Roborock vacuums."
|
|
5
5
|
authors = [{ name = "humbertogontijo", email = "humbertogontijo@users.noreply.github.com" }, {name="Lash-L"}, {name="allenporter"}]
|
|
6
6
|
requires-python = ">=3.11, <4"
|
|
@@ -123,6 +123,13 @@ class DustBagStatus(RoborockDssCodes):
|
|
|
123
123
|
full = 34
|
|
124
124
|
|
|
125
125
|
|
|
126
|
+
class CleanFluidStatus(RoborockDssCodes):
|
|
127
|
+
"""Status of the cleaning fluid container."""
|
|
128
|
+
|
|
129
|
+
empty_not_installed = 1
|
|
130
|
+
okay = 2
|
|
131
|
+
|
|
132
|
+
|
|
126
133
|
class RoborockErrorCode(RoborockEnum):
|
|
127
134
|
none = 0
|
|
128
135
|
lidar_blocked = 1
|
|
@@ -39,6 +39,7 @@ from roborock.exceptions import RoborockException
|
|
|
39
39
|
|
|
40
40
|
from ..containers import RoborockBase, RoborockBaseTimer, _attr_repr
|
|
41
41
|
from .v1_code_mappings import (
|
|
42
|
+
CleanFluidStatus,
|
|
42
43
|
ClearWaterBoxStatus,
|
|
43
44
|
DirtyWaterBoxStatus,
|
|
44
45
|
DustBagStatus,
|
|
@@ -229,9 +230,12 @@ class Status(RoborockBase):
|
|
|
229
230
|
return None
|
|
230
231
|
|
|
231
232
|
@property
|
|
232
|
-
def clean_fluid_status(self) ->
|
|
233
|
+
def clean_fluid_status(self) -> CleanFluidStatus | None:
|
|
233
234
|
if self.dss:
|
|
234
|
-
|
|
235
|
+
value = (self.dss >> 10) & 3
|
|
236
|
+
if value == 0:
|
|
237
|
+
return None # Feature not supported by this device
|
|
238
|
+
return CleanFluidStatus(value)
|
|
235
239
|
return None
|
|
236
240
|
|
|
237
241
|
@property
|
|
@@ -15,11 +15,11 @@ from collections.abc import Callable
|
|
|
15
15
|
from contextlib import asynccontextmanager
|
|
16
16
|
|
|
17
17
|
import aiomqtt
|
|
18
|
-
from aiomqtt import MqttError, TLSParameters
|
|
18
|
+
from aiomqtt import MqttCodeError, MqttError, TLSParameters
|
|
19
19
|
|
|
20
20
|
from roborock.callbacks import CallbackMap
|
|
21
21
|
|
|
22
|
-
from .session import MqttParams, MqttSession, MqttSessionException
|
|
22
|
+
from .session import MqttParams, MqttSession, MqttSessionException, MqttSessionUnauthorized
|
|
23
23
|
|
|
24
24
|
_LOGGER = logging.getLogger(__name__)
|
|
25
25
|
_MQTT_LOGGER = logging.getLogger(f"{__name__}.aiomqtt")
|
|
@@ -33,6 +33,16 @@ MAX_BACKOFF_INTERVAL = datetime.timedelta(minutes=30)
|
|
|
33
33
|
BACKOFF_MULTIPLIER = 1.5
|
|
34
34
|
|
|
35
35
|
|
|
36
|
+
class MqttReasonCode:
|
|
37
|
+
"""MQTT Reason Codes used by Roborock devices.
|
|
38
|
+
|
|
39
|
+
This is a subset of paho.mqtt.reasoncodes.ReasonCode where we would like
|
|
40
|
+
different error handling behavior.
|
|
41
|
+
"""
|
|
42
|
+
|
|
43
|
+
RC_ERROR_UNAUTHORIZED = 135
|
|
44
|
+
|
|
45
|
+
|
|
36
46
|
class RoborockMqttSession(MqttSession):
|
|
37
47
|
"""An MQTT session for sending and receiving messages.
|
|
38
48
|
|
|
@@ -83,6 +93,10 @@ class RoborockMqttSession(MqttSession):
|
|
|
83
93
|
self._reconnect_task = loop.create_task(self._run_reconnect_loop(start_future))
|
|
84
94
|
try:
|
|
85
95
|
await start_future
|
|
96
|
+
except MqttCodeError as err:
|
|
97
|
+
if err.rc == MqttReasonCode.RC_ERROR_UNAUTHORIZED:
|
|
98
|
+
raise MqttSessionUnauthorized(f"Authorization error starting MQTT session: {err}") from err
|
|
99
|
+
raise MqttSessionException(f"Error starting MQTT session: {err}") from err
|
|
86
100
|
except MqttError as err:
|
|
87
101
|
raise MqttSessionException(f"Error starting MQTT session: {err}") from err
|
|
88
102
|
except Exception as err:
|
|
@@ -64,4 +64,17 @@ class MqttSession(ABC):
|
|
|
64
64
|
|
|
65
65
|
|
|
66
66
|
class MqttSessionException(RoborockException):
|
|
67
|
-
"""
|
|
67
|
+
"""Raised when there is an error communicating with MQTT."""
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
class MqttSessionUnauthorized(RoborockException):
|
|
71
|
+
"""Raised when there is an authorization error communicating with MQTT.
|
|
72
|
+
|
|
73
|
+
This error may be raised in multiple scenarios so there is not a well
|
|
74
|
+
defined behavior for how the caller should behave. The two cases are:
|
|
75
|
+
- Rate limiting is in effect and the caller should retry after some time.
|
|
76
|
+
- The credentials are invalid and the caller needs to obtain new credentials
|
|
77
|
+
|
|
78
|
+
However, it is observed that obtaining new credentials may resolve the
|
|
79
|
+
issue in both cases.
|
|
80
|
+
"""
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q10/b01_q10_code_mappings.py
RENAMED
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q10/b01_q10_containers.py
RENAMED
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q7/b01_q7_code_mappings.py
RENAMED
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/data/b01_q7/b01_q7_containers.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/clean_summary.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/consumeable.py
RENAMED
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/device_features.py
RENAMED
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/do_not_disturb.py
RENAMED
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/flow_led_status.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/map_content.py
RENAMED
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/network_info.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/smart_wash_params.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/devices/traits/v1/wash_towel_mode.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_1_apis/roborock_client_v1.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_roborock-3.10.10 → python_roborock-3.11.1}/roborock/version_a01_apis/roborock_client_a01.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|