pymammotion 0.3.5__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.
- pymammotion/http/http.py +3 -1
- pymammotion/mammotion/commands/messages/system.py +1 -1
- {pymammotion-0.3.5.dist-info → pymammotion-0.3.7.dist-info}/METADATA +1 -1
- {pymammotion-0.3.5.dist-info → pymammotion-0.3.7.dist-info}/RECORD +6 -6
- {pymammotion-0.3.5.dist-info → pymammotion-0.3.7.dist-info}/LICENSE +0 -0
- {pymammotion-0.3.5.dist-info → pymammotion-0.3.7.dist-info}/WHEEL +0 -0
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 =
|
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,
|
@@ -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=
|
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=
|
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.
|
125
|
-
pymammotion-0.3.
|
126
|
-
pymammotion-0.3.
|
127
|
-
pymammotion-0.3.
|
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,,
|
File without changes
|
File without changes
|