Skip to content

Commit 5946d9a

Browse files
committed
up
1 parent 3bf3586 commit 5946d9a

File tree

5 files changed

+14
-6
lines changed

5 files changed

+14
-6
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,14 @@ Telegram:[@lgc2333](https://t.me/lgc2333)
193193

194194
## 📝 更新日志
195195

196+
### 2.0.4
197+
198+
- 兼容 HTTPX 0.28
199+
200+
### 2.0.3
201+
202+
- 移除重复搜索结果并添加数量提示
203+
196204
### 2.0.2
197205

198206
- 添加配置项用于自定义 Ascii2D 的 Base URL

YetAnotherPicSearch/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
load_search_func()
1313

14-
__version__ = "2.0.3.post2"
14+
__version__ = "2.0.4"
1515
__plugin_meta__ = PluginMetadata(
1616
name="YetAnotherPicSearch",
1717
description="基于 NoneBot2 及 PicImageSearch 的另一个 NoneBot 搜图插件",

YetAnotherPicSearch/data_source/ehentai.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ async def ehentai_title_search(title: str) -> list[UniMessage]:
5656
async with AsyncClient(
5757
headers=DEFAULT_HEADERS,
5858
cookies=parse_cookies(config.exhentai_cookies),
59-
proxies=config.proxy,
59+
proxy=config.proxy,
6060
) as session:
6161
resp = await session.get(url, params=params)
6262
if res := EHentaiResponse(resp.text, str(resp.url)):

YetAnotherPicSearch/data_source/nhentai.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ async def update_nhentai_info(item: NHentaiItem) -> None:
2727
async with AsyncClient(
2828
headers=NHENTAI_HEADERS,
2929
cookies=NHENTAI_COOKIES,
30-
proxies=config.proxy,
30+
proxy=config.proxy,
3131
) as session:
3232
resp = await session.get(item.url)
3333
uft8_parser = HTMLParser(encoding="utf-8")
@@ -49,7 +49,7 @@ async def nhentai_title_search(title: str) -> list[UniMessage]:
4949
async with AsyncClient(
5050
headers=NHENTAI_HEADERS,
5151
cookies=NHENTAI_COOKIES,
52-
proxies=config.proxy,
52+
proxy=config.proxy,
5353
) as session:
5454
resp = await session.get(url, params=params)
5555
if res := NHentaiResponse(resp.text, str(resp.url)):

YetAnotherPicSearch/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ async def get_image_bytes_by_url(url: str, cookies: Optional[str] = None) -> byt
5858
async with AsyncClient(
5959
headers=headers,
6060
cookies=parse_cookies(cookies),
61-
proxies=config.proxy,
61+
proxy=config.proxy,
6262
follow_redirects=True,
6363
) as session:
6464
resp = await session.get(url)
@@ -132,7 +132,7 @@ async def get_source(url: str) -> str:
132132
headers = None if host == "danbooru.donmai.us" else DEFAULT_HEADERS
133133
async with AsyncClient(
134134
headers=headers,
135-
proxies=config.proxy,
135+
proxy=config.proxy,
136136
follow_redirects=True,
137137
) as session:
138138
resp = await session.get(url)

0 commit comments

Comments
 (0)