From 3adccc1b6ca69351bec7e3d82ef6730c957b7b29 Mon Sep 17 00:00:00 2001 From: lowking <33308659+lowking@users.noreply.github.com> Date: Mon, 24 May 2021 09:32:41 +0800 Subject: [PATCH] change decode --- pl.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pl.py b/pl.py index d9225b1..50ff89c 100644 --- a/pl.py +++ b/pl.py @@ -34,7 +34,7 @@ async def pl(context): for _ in range(3): # 最多重试3次 try: plhtml = get(f"http://www.gd2063.com/pl/?{s}") - htmlStr = plhtml.content.decode("gb2312") + htmlStr = plhtml.content.decode("gbk") soup = BeautifulSoup(htmlStr, 'html.parser') arr = soup.find_all(name='a', attrs={"class": "heise"}, limit=10) result = ""