tplinkrouterc6u 5.6.1__py3-none-any.whl → 5.6.2__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.
@@ -1,5 +1,7 @@
1
1
  from base64 import b64decode
2
2
  from json import dumps
3
+ from requests.exceptions import ConnectTimeout
4
+ from collections.abc import Callable
3
5
  from macaddress import EUI48
4
6
  from ipaddress import IPv4Address
5
7
  from logging import Logger
@@ -149,6 +151,22 @@ class TPLinkDecoClient(TplinkEncryption, AbstractRouter):
149
151
 
150
152
  return ipv4_status
151
153
 
154
+ def authorize(self) -> None:
155
+ self._retry_request(super().authorize)
156
+
157
+ def request(self, path: str, data: str, ignore_response: bool = False, ignore_errors: bool = False) -> dict | None:
158
+ return self._retry_request(super().request, path, data, ignore_response, ignore_errors)
159
+
160
+ def _retry_request(self, callback: Callable, *args):
161
+ retries = 0
162
+ while True:
163
+ try:
164
+ return callback(*args)
165
+ except ConnectTimeout as err:
166
+ if retries > 2:
167
+ raise err
168
+ retries += 1
169
+
152
170
  def _map_wire_type(self, data: dict) -> Connection:
153
171
  if data.get('wire_type') == 'wired':
154
172
  return Connection.WIRED
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.2
1
+ Metadata-Version: 2.4
2
2
  Name: tplinkrouterc6u
3
- Version: 5.6.1
3
+ Version: 5.6.2
4
4
  Summary: TP-Link Router API (supports also Mercusys Router)
5
5
  Home-page: https://github.com/AlexandrErohin/TP-Link-Archer-C6U
6
6
  Author: Alex Erohin
@@ -25,6 +25,7 @@ Dynamic: classifier
25
25
  Dynamic: description
26
26
  Dynamic: description-content-type
27
27
  Dynamic: home-page
28
+ Dynamic: license-file
28
29
  Dynamic: requires-dist
29
30
  Dynamic: requires-python
30
31
  Dynamic: summary
@@ -292,8 +293,7 @@ or you have TP-link C5400X or similar router you need to get web encrypted passw
292
293
  - Archer A9 V6
293
294
  - Archer AX10 v1.0
294
295
  - Archer AX12 v1.0
295
- - Archer AX20 v1.0
296
- - Archer AX20 v3.0
296
+ - Archer AX20 (v1.0, v3.0)
297
297
  - Archer AX21 (v1.20, v3.0)
298
298
  - Archer AX23 (v1.0, v1.2)
299
299
  - Archer AX50 v1.0
@@ -317,6 +317,7 @@ or you have TP-link C5400X or similar router you need to get web encrypted passw
317
317
  - Archer C6 (v2.0, v3.0, 4.0)
318
318
  - Archer C6U v1.0
319
319
  - Archer C7 (v4.0, v5.0)
320
+ - Archer C24 (1.0, 2.0)
320
321
  - Archer C60 v2.0
321
322
  - Archer C80 (1.0, 2.20)
322
323
  - Archer C5400X V1
@@ -349,11 +350,13 @@ or you have TP-link C5400X or similar router you need to get web encrypted passw
349
350
  - TL-MR105
350
351
  - TL-MR6400 (v5, v5.3)
351
352
  - TL-MR6500v
353
+ - TL-WA1201 3.0
352
354
  - TL-WA3001 v1.0
353
355
  - TL-XDR3010 V2
354
356
  - XC220-G3v v2.30
355
357
  ### <a id="mercusys">MERCUSYS routers</a>
356
358
  - MR47BE v1.0
359
+ - MR50G 1.0
357
360
  - H60XR 1.0
358
361
 
359
362
  Please let me know if you have tested integration with any other model. Open an issue with info about router's model, hardware and firmware versions.
@@ -14,7 +14,7 @@ tplinkrouterc6u/client/c1200.py,sha256=_nY_pJ-wPWODAaes9kHPdVcM6YM54f1E54CfdoFHq
14
14
  tplinkrouterc6u/client/c5400x.py,sha256=9E0omBSbWY_ljrs5MTCMu5brmrLtzsDB5O62Db8lP8Q,4329
15
15
  tplinkrouterc6u/client/c6u.py,sha256=TbS8qbwfPzIVDEMNNlKMhWuGeo-RUvaCkG_bF7Y4L0Q,17637
16
16
  tplinkrouterc6u/client/c80.py,sha256=3Cy9FCYHZaGzTGAjsB2BdjxpzJmBoW6TMDTDaCyUDjI,18437
17
- tplinkrouterc6u/client/deco.py,sha256=7uVd9wt3aJGShft7L520AzFpQ85xbgRWM-8uyrpxE8Y,8229
17
+ tplinkrouterc6u/client/deco.py,sha256=cpKRggKD2RvSmMZuD6tzsZmehAUCU9oLiTTHcZBW81Y,8898
18
18
  tplinkrouterc6u/client/ex.py,sha256=ZK08mlOts3fbBJh9NUrzBADP0N9LHgzOXCKY2tF9gG0,13111
19
19
  tplinkrouterc6u/client/mr.py,sha256=kJ-meAgMPub6aKtzBEVI3CNNzsVab7pLkOlXU9dj030,26030
20
20
  tplinkrouterc6u/client/vr.py,sha256=7Tbu0IrWtr4HHtyrnLFXEJi1QctzhilciL7agtwQ0R8,5025
@@ -25,8 +25,8 @@ tplinkrouterc6u/common/encryption.py,sha256=4HelTxzN6esMfDZRBt3m8bwB9Nj_biKijnCn
25
25
  tplinkrouterc6u/common/exception.py,sha256=_0G8ZvW5__CsGifHrsZeULdl8c6EUD071sDCQsQgrHY,140
26
26
  tplinkrouterc6u/common/helper.py,sha256=23b04fk9HuVinrZXMCS5R1rmF8uZ7eM-Cdnp7Br9NR0,572
27
27
  tplinkrouterc6u/common/package_enum.py,sha256=4ykL_2Pw0nDEIH_qR9UJlFF6stTgSfhPz32r8KT-sh8,1624
28
- tplinkrouterc6u-5.6.1.dist-info/LICENSE,sha256=YF6QR6Vjxcg5b_sYIyqkME7FZYau5TfEUGTG-0JeRK0,35129
29
- tplinkrouterc6u-5.6.1.dist-info/METADATA,sha256=yR4yQKnQL71GuYxBQYi36CBaPgVd6n-14U_ntiHD568,15302
30
- tplinkrouterc6u-5.6.1.dist-info/WHEEL,sha256=52BFRY2Up02UkjOa29eZOS2VxUrpPORXg1pkohGGUS8,91
31
- tplinkrouterc6u-5.6.1.dist-info/top_level.txt,sha256=1iSCCIueqgEkrTxtQ-jiHe99jAB10zqrVdBcwvNfe_M,21
32
- tplinkrouterc6u-5.6.1.dist-info/RECORD,,
28
+ tplinkrouterc6u-5.6.2.dist-info/licenses/LICENSE,sha256=YF6QR6Vjxcg5b_sYIyqkME7FZYau5TfEUGTG-0JeRK0,35129
29
+ tplinkrouterc6u-5.6.2.dist-info/METADATA,sha256=OJZ_573ij0N15aCx8DIhTyQ-gM8x794j5gYaygq5310,15365
30
+ tplinkrouterc6u-5.6.2.dist-info/WHEEL,sha256=tTnHoFhvKQHCh4jz3yCn0WPTYIy7wXx3CJtJ7SJGV7c,91
31
+ tplinkrouterc6u-5.6.2.dist-info/top_level.txt,sha256=1iSCCIueqgEkrTxtQ-jiHe99jAB10zqrVdBcwvNfe_M,21
32
+ tplinkrouterc6u-5.6.2.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (76.0.0)
2
+ Generator: setuptools (77.0.1)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5