p115client 0.0.5.12.2__py3-none-any.whl → 0.0.5.12.2.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.
p115/__init__.py ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env python3
2
+ # encoding: utf-8
3
+
4
+ __import__("sys").modules["p115"] = __import__("p115client")
p115client/client.py CHANGED
@@ -23060,3 +23060,4 @@ with temp_globals():
23060
23060
 
23061
23061
  # TODO: 提供一个可随时终止和暂停的上传功能,并且可以输出进度条和获取进度
23062
23062
  # TODO: 更新一下,p115client._upload,做更多的封装,至少让断点续传更易于使用
23063
+ # TODO: 支持对接口调用进行频率统计,默认就会开启,配置项目:1. 允许记录多少条或者多大时间窗口,默认记录最近 10 条(无限时间窗口) 2. 可以设置一个 key 函数,默认用 (url, method) 为 key 3. 数据和统计由单独的对象来承载,就行 headers 和 cookies 属性那样,可以被随意查看,这个对象由各种配置项目,可以随意修改,client初始化时候支持传入此对象 4. 可以修改时间窗口和数量限制 5. 可以获取数据,就像字典一样使用 dict[key, list[timestamp]] 6. 有一些做好的统计方法,你也可以自己来执行统计 7. 即使有些历史数据被移除,有些统计方法可以持续更新,覆盖从早到现在的所有数据,比如 加总、计数
@@ -37,7 +37,7 @@ def iter_fs_files(
37
37
  payload: int | str | dict = 0,
38
38
  /,
39
39
  first_page_size: int = 0,
40
- page_size: int = 10_000,
40
+ page_size: int = 7_000,
41
41
  count: int = -1,
42
42
  callback: None | Callable[[dict], Any] = None,
43
43
  app: str = "web",
@@ -53,7 +53,7 @@ def iter_fs_files(
53
53
  payload: int | str | dict = 0,
54
54
  /,
55
55
  first_page_size: int = 0,
56
- page_size: int = 10_000,
56
+ page_size: int = 7_000,
57
57
  count: int = -1,
58
58
  callback: None | Callable[[dict], Any] = None,
59
59
  app: str = "web",
@@ -68,7 +68,7 @@ def iter_fs_files(
68
68
  payload: int | str | dict = 0,
69
69
  /,
70
70
  first_page_size: int = 0,
71
- page_size: int = 10_000,
71
+ page_size: int = 7_000,
72
72
  count: int = -1,
73
73
  callback: None | Callable[[dict], Any] = None,
74
74
  app: str = "web",
@@ -95,7 +95,7 @@ def iter_fs_files(
95
95
  if isinstance(client, str):
96
96
  client = P115Client(client, check_for_relogin=True)
97
97
  if page_size <= 0:
98
- page_size = 10_000
98
+ page_size = 7_000
99
99
  if not isinstance(client, P115Client) or app == "open":
100
100
  page_size = min(page_size, 1150)
101
101
  fs_files = partial(client.fs_files_open, **request_kwargs)
@@ -191,7 +191,7 @@ def iter_fs_files_threaded(
191
191
  if isinstance(client, str):
192
192
  client = P115Client(client, check_for_relogin=True)
193
193
  if page_size <= 0:
194
- page_size = 10_000
194
+ page_size = 7_000
195
195
  if not isinstance(client, P115Client) or app == "open":
196
196
  page_size = min(page_size, 1150)
197
197
  fs_files = partial(client.fs_files_open, **request_kwargs)
@@ -306,7 +306,7 @@ async def iter_fs_files_asynchronized(
306
306
  if isinstance(client, str):
307
307
  client = P115Client(client, check_for_relogin=True)
308
308
  if page_size <= 0:
309
- page_size = 10_000
309
+ page_size = 7_000
310
310
  fs_files: Callable[..., Awaitable[dict]]
311
311
  if not isinstance(client, P115Client) or app == "open":
312
312
  page_size = min(page_size, 1150)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: p115client
3
- Version: 0.0.5.12.2
3
+ Version: 0.0.5.12.2.2
4
4
  Summary: Python 115 webdisk client.
5
5
  Home-page: https://github.com/ChenyangGao/p115client
6
6
  License: MIT
@@ -1,7 +1,8 @@
1
1
  LICENSE,sha256=o5242_N2TgDsWwFhPn7yr8YJNF7XsJM5NxUMtcT97bc,1100
2
+ p115/__init__.py,sha256=vS2FYRIUDvJPj38ti4nGOTbYtqdFqUEVnYjG_RM5S7M,103
2
3
  p115client/__init__.py,sha256=1mx7njuAlqcuEWONTjSiiGnXyyNyqOcJyNX1FMHqQ-4,214
3
4
  p115client/_upload.py,sha256=199Hc9B9vUMphDdwh8vK3yCIPusIfeAzzOLpC-WZ8C8,31184
4
- p115client/client.py,sha256=IRlyc45i5gtZD19MjS3MGqm8ZKh-XZe3mQbHF31KVLs,795356
5
+ p115client/client.py,sha256=KEn5zBVTx6qfc6LCA-1zY2CcwJuYqYgXW0TIx-z41i4,796153
5
6
  p115client/const.py,sha256=ZYtBtTFB0eljIR0tze21_52Gl0pQxvyqMmDwgB1bqNU,7803
6
7
  p115client/exception.py,sha256=4SZ8ubOLMRxtcqc0u1kNzXqH1a6wwXJFwGnRDURoEgQ,3708
7
8
  p115client/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -11,7 +12,7 @@ p115client/tool/auth.py,sha256=qlRcfEjzebseiHR2dyBpOoPpxB4k8P6Tj729S2TLB1s,1672
11
12
  p115client/tool/download.py,sha256=_Kp5_AKNAFmBXsUvL0zm8XBkPVlJxC4n4vj6-E0t6BE,61009
12
13
  p115client/tool/edit.py,sha256=UCECvHYTy_GGpsaYbaNGtEBT0s5pMD4k1M-s8GG6iFI,17725
13
14
  p115client/tool/export_dir.py,sha256=WZAiRFqe984-oXTEgkVhwHi4MTrExVL_tGZIzWCkdL0,24364
14
- p115client/tool/fs_files.py,sha256=VqHO2eiTwxaHmYR4CwVXifo3dT_wdcvvPVg4FSrIn4E,15896
15
+ p115client/tool/fs_files.py,sha256=3t1R-bDUdIUGwLMZ-GhHMRpYnkYYLcsI3MzFhJzg8g8,15890
15
16
  p115client/tool/history.py,sha256=Hk7W1Qko6P68AoukNc-cYFoGV5XemtZBqWBEm4uKt5c,7416
16
17
  p115client/tool/iterdir.py,sha256=t17T5XTCof7ZAbPKAzTAyhpVzfknVsJFb4SK5giXdsI,199635
17
18
  p115client/tool/life.py,sha256=Ik8jdFM9_DiT5ivd5h2Hag4ViBVOY5WRCCrmbCqKnMY,17209
@@ -22,7 +23,7 @@ p115client/tool/upload.py,sha256=z8eD5BAlw6SgWdaJBJ4VtyDMPr8xG3wz6oCxE6xxPTg,325
22
23
  p115client/tool/util.py,sha256=pAa8gc4BcnVTpNcXbNZU4tBUMjSB04DGOpzDdzfbto8,3934
23
24
  p115client/tool/xys.py,sha256=Xx8sRh4h4jlowFhRMTDTtOhftgmhevehAU27jMsKh8s,10191
24
25
  p115client/type.py,sha256=7kOp98uLaYqcTTCgCrb3DRcl8ukMpn7ibsnVvtw2nG8,6250
25
- p115client-0.0.5.12.2.dist-info/LICENSE,sha256=o5242_N2TgDsWwFhPn7yr8YJNF7XsJM5NxUMtcT97bc,1100
26
- p115client-0.0.5.12.2.dist-info/METADATA,sha256=_MF9z3xGkNCLuaWn9yk6ZQBvSnSLzCltzEcDBHI_5s4,8194
27
- p115client-0.0.5.12.2.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
28
- p115client-0.0.5.12.2.dist-info/RECORD,,
26
+ p115client-0.0.5.12.2.2.dist-info/LICENSE,sha256=o5242_N2TgDsWwFhPn7yr8YJNF7XsJM5NxUMtcT97bc,1100
27
+ p115client-0.0.5.12.2.2.dist-info/METADATA,sha256=DBLVNQ7f4-nIOk3H9h7s6h3e1LQ4HuWEcR6_pwk6ZCs,8196
28
+ p115client-0.0.5.12.2.2.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
29
+ p115client-0.0.5.12.2.2.dist-info/RECORD,,