ey-commerce-lib 1.0.8__py3-none-any.whl → 1.0.9__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.

Potentially problematic release.


This version of ey-commerce-lib might be problematic. Click here for more details.

@@ -1,4 +1,4 @@
1
- from httpx import AsyncClient
1
+ from httpx import AsyncClient, Timeout
2
2
 
3
3
  from ey_commerce_lib.kogan.schemas.query.order import KoganOrderQuery
4
4
  from ey_commerce_lib.kogan.schemas.query.product import KoganProductQuery
@@ -11,13 +11,17 @@ class KoganClient:
11
11
  def __init__(self, seller_id: str, seller_token: str):
12
12
  self.seller_id = seller_id
13
13
  self.seller_token = seller_token
14
+ timeout = Timeout(connect=5.0, read=20.0, write=10.0, pool=10.0)
15
+
14
16
  # 异步客户端
15
17
  self.__async_client = AsyncClient(base_url="https://nimda.kogan.com",
16
18
  headers={
17
19
  'Accept': 'application/json',
18
20
  'SellerId': self.seller_id,
19
21
  'SellerToken': self.seller_token
20
- })
22
+ },
23
+ timeout=timeout
24
+ )
21
25
 
22
26
  async def orders(self, query_params: KoganOrderQuery):
23
27
  # 设置查询参数
@@ -31,6 +35,7 @@ class KoganClient:
31
35
  params=query_params.model_dump(by_alias=True,
32
36
  exclude_none=True
33
37
  ))
38
+
34
39
  return ProductResponse(**products_res.json())
35
40
 
36
41
  async def __aenter__(self):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ey-commerce-lib
3
- Version: 1.0.8
3
+ Version: 1.0.9
4
4
  Summary: eeyoung电商客户端调用封装
5
5
  Author-email: 饶奇奇 <1124393197@qq.com>
6
6
  Requires-Python: >=3.10
@@ -29,7 +29,7 @@ ey_commerce_lib/four_seller/schemas/query/order.py,sha256=XV7by4RT9NWvei4C__cQsL
29
29
  ey_commerce_lib/four_seller/schemas/vo/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
30
30
  ey_commerce_lib/four_seller/schemas/vo/order.py,sha256=aNpnXSaXeUVbBz_7JtP8p6mWIWgUwejUhtYoa3gf4Po,12133
31
31
  ey_commerce_lib/kogan/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
32
- ey_commerce_lib/kogan/main.py,sha256=hHW-R3CYwzyFGFO7nzLHhwnFsz06a0hPE2cwdsiwwSM,2025
32
+ ey_commerce_lib/kogan/main.py,sha256=fROFOUd80qtsnggz5XR3vyoSAcb6PqFD1_rqSbAtYhE,2216
33
33
  ey_commerce_lib/kogan/schemas/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
34
34
  ey_commerce_lib/kogan/schemas/query/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
35
35
  ey_commerce_lib/kogan/schemas/query/order.py,sha256=ajqO992fiorUDg3-YPPpK2Dgmdy2LoHfz4IatBz1Mro,574
@@ -42,6 +42,6 @@ ey_commerce_lib/utils/close.py,sha256=-De_H1I-gryytKYhLMsC3HfW67W852XkP1ckK2gLsF
42
42
  ey_commerce_lib/utils/dxm.py,sha256=jVNltK_Pm_yMzXReD0Aw5VW6kzIZ5Bn23RucS0DKBI0,1196
43
43
  ey_commerce_lib/utils/list_util.py,sha256=R1w7B1m3sEXr38zSHWp-15C3xAs5ykYCCpvwmnRW4xs,545
44
44
  ey_commerce_lib/utils/str.py,sha256=939xE0y8U7KEWjwbEezMlaWJNBsfb2BSb-dBpYbOD8Q,138
45
- ey_commerce_lib-1.0.8.dist-info/METADATA,sha256=pwSNg0XUKe41gqcoJgdBmvqdZtH4E0BGjE4Ban1CLY4,390
46
- ey_commerce_lib-1.0.8.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
47
- ey_commerce_lib-1.0.8.dist-info/RECORD,,
45
+ ey_commerce_lib-1.0.9.dist-info/METADATA,sha256=ZtIwxpZimtVDdsxh9-K_PMNmmP1U49qr6i3mDunlk3w,390
46
+ ey_commerce_lib-1.0.9.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
47
+ ey_commerce_lib-1.0.9.dist-info/RECORD,,