httpr 0.1.10__cp39-abi3-manylinux_2_12_i686.manylinux2010_i686.whl → 0.1.12__cp39-abi3-manylinux_2_12_i686.manylinux2010_i686.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 httpr might be problematic. Click here for more details.

httpr/__init__.py CHANGED
@@ -80,6 +80,10 @@ class Client(RClient):
80
80
  # Validate the HTTP method. Raise an exception if it's not supported.
81
81
  if method not in ["GET", "HEAD", "OPTIONS", "DELETE", "POST", "PUT", "PATCH"]:
82
82
  raise ValueError(f"Unsupported HTTP method: {method}")
83
+ # Convert all params values to strings if params is present
84
+ if "params" in kwargs and kwargs["params"] is not None:
85
+ kwargs["params"] = {k: str(v) for k, v in kwargs["params"].items()}
86
+
83
87
  return super().request(method=method, url=url, **kwargs)
84
88
 
85
89
  def get(self, url: str, **kwargs: Unpack[RequestParams]) -> Response:
@@ -123,6 +127,12 @@ class AsyncClient(Client):
123
127
  return await loop.run_in_executor(None, partial(fn, *args, **kwargs))
124
128
 
125
129
  async def request(self, method: HttpMethod, url: str, **kwargs: Unpack[RequestParams]): # type: ignore
130
+ if method not in ["GET", "HEAD", "OPTIONS", "DELETE", "POST", "PUT", "PATCH"]:
131
+ raise ValueError(f"Unsupported HTTP method: {method}")
132
+ # Convert all params values to strings if params is present
133
+ if "params" in kwargs and kwargs["params"] is not None:
134
+ kwargs["params"] = {k: str(v) for k, v in kwargs["params"].items()}
135
+
126
136
  return await self._run_sync_asyncio(super().request, method=method, url=url, **kwargs)
127
137
 
128
138
  async def get(self, url: str, **kwargs: Unpack[RequestParams]): # type: ignore
httpr/httpr.abi3.so CHANGED
Binary file
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: httpr
3
- Version: 0.1.10
3
+ Version: 0.1.12
4
4
  Classifier: Programming Language :: Rust
5
5
  Classifier: Programming Language :: Python :: 3
6
6
  Classifier: Programming Language :: Python :: 3 :: Only
@@ -0,0 +1,8 @@
1
+ httpr-0.1.12.dist-info/METADATA,sha256=ACkNOuCFAVLoNWpi2xQgrTrLssjaPxt9pHyVt25YMWo,12387
2
+ httpr-0.1.12.dist-info/WHEEL,sha256=8XXmPkNngrF6kZ-eEuVTqHu2jRWnGboX5xGwALfMg9Y,123
3
+ httpr-0.1.12.dist-info/licenses/LICENSE,sha256=ZPD9tCar0h91tI4v-TuZdrjDdLqzU4rzPTxtP3x--uc,1063
4
+ httpr/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
+ httpr/__init__.py,sha256=WGZx_HtQdivDCLu7upDSwr-nQQpVXaFI4CX7vl7rFXg,9277
6
+ httpr/httpr.pyi,sha256=PYXORKm_hXjnVPhEBgzbTLY97lYM2ZK-TpmwZAj0d9c,3729
7
+ httpr/httpr.abi3.so,sha256=4ap96V_Ikz0vcsZglSPvCnCk7igxTgvF2M75Do6VK2w,4851260
8
+ httpr-0.1.12.dist-info/RECORD,,
@@ -1,8 +0,0 @@
1
- httpr-0.1.10.dist-info/METADATA,sha256=Skee3JJUdd1MTYEvMwOyyBBwMWSwhstTTDQQ2RM92UQ,12387
2
- httpr-0.1.10.dist-info/WHEEL,sha256=8XXmPkNngrF6kZ-eEuVTqHu2jRWnGboX5xGwALfMg9Y,123
3
- httpr-0.1.10.dist-info/licenses/LICENSE,sha256=ZPD9tCar0h91tI4v-TuZdrjDdLqzU4rzPTxtP3x--uc,1063
4
- httpr/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
- httpr/__init__.py,sha256=2AvAqECMH6euhi7kOacUDNZMSn3U0WvBW8KVPamg2-M,8689
6
- httpr/httpr.pyi,sha256=PYXORKm_hXjnVPhEBgzbTLY97lYM2ZK-TpmwZAj0d9c,3729
7
- httpr/httpr.abi3.so,sha256=Z4L6PIO5z4eCfk2x5XFEJhbnls7QAlDjTBGAzvo9NUY,4818452
8
- httpr-0.1.10.dist-info/RECORD,,
File without changes