Skip to content

Commit 7e44893

Browse files
author
huangsong
committed
add readme
1 parent c1c0f3e commit 7e44893

File tree

3 files changed

+14
-10
lines changed

3 files changed

+14
-10
lines changed

README.md

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,6 @@ And see the examples.
7979
<details>
8080
<summary> Change Log </summary>
8181

82-
### v1.0.0: refactor all the code, to be simple. remove the group client.
83-
84-
### v1.0.1: simple to use.
85-
86-
### v1.0.2: use enum to define the client type.
87-
8882
### v1.0.3: you can define your own client session in `client_config`
8983

9084
```python
@@ -101,4 +95,17 @@ client_config = ClientConfig(
10195

10296

10397
```
98+
### v1.0.5: support file response type.
99+
100+
```python
101+
from pydantic_client.schema.file import File
102+
from pydantic_client import post
103+
104+
@post("/download")
105+
def download_file(self) -> File:
106+
# you will get the bytes content of the file
107+
...
108+
109+
```
110+
104111
</details>

pydantic_client/container.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,6 @@ def get_request(method_info: MethodInfo, *args, **kwargs):
7373
else:
7474
data, json = {}, body
7575

76-
print(method_info.response_type, '!!!!!!!!')
77-
print(method_info.response_type is bytes)
78-
7976
return HttpRequest(
8077
url=url,
8178
data=data,

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "pydantic-client"
3-
version = "1.0.4"
3+
version = "1.0.5"
44
description = "Http client base pydantic, with requests or aiohttp"
55
authors = ["ponytailer <huangxiaohen2738@gmail.com>"]
66
readme = "README.md"

0 commit comments

Comments
 (0)