From a7f06fb85399498b551cb984908b5ad72a4be410 Mon Sep 17 00:00:00 2001
From: Luke <conway220@gmail.com>
Date: Sat, 19 Oct 2024 13:04:59 -0400
Subject: [PATCH] fix: add a warning for wrong type of clean area and add new
 dock

---
 roborock/code_mappings.py                     | 1 +
 roborock/containers.py                        | 5 ++++-
 roborock/version_1_apis/roborock_client_v1.py | 1 +
 3 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/roborock/code_mappings.py b/roborock/code_mappings.py
index d1f1077..321def2 100644
--- a/roborock/code_mappings.py
+++ b/roborock/code_mappings.py
@@ -386,6 +386,7 @@ class RoborockDockTypeCode(RoborockEnum):
     p10_dock = 8
     p10_pro_dock = 9
     s8_maxv_ultra_dock = 10
+    qrevo_s_dock = 15
 
 
 class RoborockDockDustCollectionModeCode(RoborockEnum):
diff --git a/roborock/containers.py b/roborock/containers.py
index 65dac3b..862bb4a 100644
--- a/roborock/containers.py
+++ b/roborock/containers.py
@@ -612,7 +612,10 @@ class CleanSummary(RoborockBase):
     last_clean_t: int | None = None
 
     def __post_init__(self) -> None:
-        self.square_meter_clean_area = round(self.clean_area / 1000000, 1) if self.clean_area is not None else None
+        if isinstance(self.clean_area, list):
+            _LOGGER.warning(f"Clean area is a unexpected type! Please give the following in a issue: {self.clean_area}")
+        else:
+            self.square_meter_clean_area = round(self.clean_area / 1000000, 1) if self.clean_area is not None else None
 
 
 @dataclass
diff --git a/roborock/version_1_apis/roborock_client_v1.py b/roborock/version_1_apis/roborock_client_v1.py
index 636b104..ddf1f3f 100644
--- a/roborock/version_1_apis/roborock_client_v1.py
+++ b/roborock/version_1_apis/roborock_client_v1.py
@@ -67,6 +67,7 @@
     RoborockDockTypeCode.p10_dock,
     RoborockDockTypeCode.p10_pro_dock,
     RoborockDockTypeCode.s8_maxv_ultra_dock,
+    RoborockDockTypeCode.qrevo_s_dock,
 ]
 RT = TypeVar("RT", bound=RoborockBase)
 EVICT_TIME = 60