pymammotion 0.3.6__py3-none-any.whl → 0.3.7__py3-none-any.whl

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.
@@ -45,6 +45,7 @@ class MowingDevice(DataClassORJSONMixin):
45
45
  err_code_list: list = field(default_factory=list)
46
46
  err_code_list_time: Optional[list] = field(default_factory=list)
47
47
  limits: DeviceLimits = field(default_factory=DeviceLimits)
48
+ device: Optional[LubaMsg] = field(default_factory=LubaMsg)
48
49
  error_codes: dict[str, ErrorInfo] = field(default_factory=dict)
49
50
 
50
51
  @classmethod
pymammotion/http/http.py CHANGED
@@ -15,7 +15,7 @@ from pymammotion.http.model.http import ErrorInfo, LoginResponseData, Response
15
15
 
16
16
  class MammotionHTTP:
17
17
  def __init__(self, response: Response) -> None:
18
- self._headers = dict()
18
+ self._headers = {"User-Agent": "okhttp/3.14.9", "App-Version": "google Pixel 2 XL taimen-Android 11,1.11.332"}
19
19
  self.login_info = LoginResponseData.from_dict(response.data) if response.data else None
20
20
  self._headers["Authorization"] = f"Bearer {self.login_info.access_token}" if response.data else None
21
21
  self.response = response
@@ -55,6 +55,7 @@ class MammotionHTTP:
55
55
  headers={
56
56
  "Authorization": f"{self._headers.get('Authorization', "")}",
57
57
  "Content-Type": "application/json",
58
+ "User-Agent": "okhttp/3.14.9",
58
59
  },
59
60
  ) as resp:
60
61
  data = await resp.json()
@@ -66,6 +67,7 @@ class MammotionHTTP:
66
67
  async def login(cls, session: ClientSession, username: str, password: str) -> Response[LoginResponseData]:
67
68
  async with session.post(
68
69
  "/oauth/token",
70
+ headers={"User-Agent": "okhttp/3.14.9", "App-Version": "google Pixel 2 XL taimen-Android 11,1.11.332"},
69
71
  params=dict(
70
72
  username=username,
71
73
  password=password,
@@ -273,7 +273,7 @@ class MessageSystem(AbstractMessage, ABC):
273
273
  timeout=1000,
274
274
  period=1000,
275
275
  no_change_period=2000,
276
- count=0,
276
+ count=3,
277
277
  )
278
278
 
279
279
  def get_report_cfg_stop(self, timeout: int = 10000, period: int = 1000, no_change_period: int = 1000):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pymammotion
3
- Version: 0.3.6
3
+ Version: 0.3.7
4
4
  Summary:
5
5
  License: GNU-3.0
6
6
  Author: Michael Arthur
@@ -24,7 +24,7 @@ pymammotion/const.py,sha256=lWRxvTVdXnNHuxqvRkjO5ziK0Ic-fZMM6J2dbe5M6Nc,385
24
24
  pymammotion/data/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
25
25
  pymammotion/data/model/__init__.py,sha256=aSyroxYQQS-WMRi6WmWm2js4wLa9nmsi160gx9tts4o,323
26
26
  pymammotion/data/model/account.py,sha256=vJM-KTf2q6eBfVC-UlNHBSmJvqHiCawZ40vnuhXhaz8,140
27
- pymammotion/data/model/device.py,sha256=SMhk3kEohKb67nPtq8MIRfa3r6QWrjo_QrtTKI9OgbA,12370
27
+ pymammotion/data/model/device.py,sha256=GQH9pNPcqb4zdl55r8dYIHgvXlwdA8k3xHwMVzNalys,12433
28
28
  pymammotion/data/model/device_config.py,sha256=b3zmArKg10NIheNGSugwWruLM_H4ySBlQxDgXAiB2es,2852
29
29
  pymammotion/data/model/device_info.py,sha256=ahz2xILdSYdX6SIVuVzz8QCfSQLefbQnpXrsiDpBDbY,585
30
30
  pymammotion/data/model/enums.py,sha256=EpKmO8yVUZyEnTY4yH0DMMVKYNQM42zpW1maUu0i3IE,1582
@@ -46,7 +46,7 @@ pymammotion/data/state_manager.py,sha256=W6PjIMXHPObocYay6ZQ7ITju27MA5kK5udFptAy
46
46
  pymammotion/event/__init__.py,sha256=mgATR6vPHACNQ-0zH5fi7NdzeTCDV1CZyaWPmtUusi8,115
47
47
  pymammotion/event/event.py,sha256=bj2RirSIRyBs0QvkcrOtwZWUX_8F3m1sySuHVyKmZLs,2143
48
48
  pymammotion/http/_init_.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
49
- pymammotion/http/http.py,sha256=uPa6NeBKGbgw9FBIRfuSmFtp0nhsnK0NPtR1EBOkeEM,3678
49
+ pymammotion/http/http.py,sha256=h-h7pfLCbkyf1gsezTisvWdAjCRAKwyDTziylW0kq4A,3933
50
50
  pymammotion/http/model/http.py,sha256=0yGswnzFtszFR9rseq6vlW6nJmTiy9dth1Xn3USaQyw,2301
51
51
  pymammotion/mammotion/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
52
52
  pymammotion/mammotion/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -58,7 +58,7 @@ pymammotion/mammotion/commands/messages/media.py,sha256=l-m4l2Vp1ZOHPHyJTceuLaLv
58
58
  pymammotion/mammotion/commands/messages/navigation.py,sha256=Z6RQK-pMh8o7_K_1yTENx3lkNBFQTU_ojunolSre0oM,23241
59
59
  pymammotion/mammotion/commands/messages/network.py,sha256=AErasUL7U4lbFKRJPVzUZMHegP5K2Jo9wGmeWruOtUg,7623
60
60
  pymammotion/mammotion/commands/messages/ota.py,sha256=g937HT_-OQXV6A3zUiZ53b45cOX6y-rzs5m-4b0IcTk,1473
61
- pymammotion/mammotion/commands/messages/system.py,sha256=IXm0RxzPUvyXmvtLY59tS9oI2alWMGVNMSQSfog2A-c,14326
61
+ pymammotion/mammotion/commands/messages/system.py,sha256=2emBaN7NtqnCcxXdXecqifYChLvKPJI8F495H3pi-mI,14326
62
62
  pymammotion/mammotion/commands/messages/video.py,sha256=xili9khz4Op5NwjXfvIkeRYzQlQPIf8o8bnoYx-Ylpw,1319
63
63
  pymammotion/mammotion/control/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
64
64
  pymammotion/mammotion/control/joystick.py,sha256=QfBVxM_gxpWsZAGO90whtgxCI2tIZ3TTad9wHIPsU9s,5640
@@ -121,7 +121,7 @@ pymammotion/utility/map.py,sha256=GYscVMg2cX3IPlNpCBNHDW0S55yS1WGRf1iHnNZ7TfQ,22
121
121
  pymammotion/utility/movement.py,sha256=N75oAoAgFydqoaOedYIxGUHmuTCtPzAOtb-d_29tpfI,615
122
122
  pymammotion/utility/periodic.py,sha256=MbeSb9cfhxzYmdT_RiE0dZe3H9IfbQW_zSqhmSX2RUc,3321
123
123
  pymammotion/utility/rocker_util.py,sha256=6tX7sS87qoQC_tsxbx3NLL-HgS08wtzXiZkhDiz7uo0,7179
124
- pymammotion-0.3.6.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
125
- pymammotion-0.3.6.dist-info/METADATA,sha256=-D1Vd3AeRM3G_bJQZXPc7s2UtvKP8j6RhLlAG7tJaJE,3895
126
- pymammotion-0.3.6.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
127
- pymammotion-0.3.6.dist-info/RECORD,,
124
+ pymammotion-0.3.7.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
125
+ pymammotion-0.3.7.dist-info/METADATA,sha256=vVtlhHt1ggmZveK00vUpqPBNfPyMdgxPVBkybydNDK4,3895
126
+ pymammotion-0.3.7.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
127
+ pymammotion-0.3.7.dist-info/RECORD,,