😐修复由于强制UTF-8带来的编码问题
This commit is contained in:
parent
79b6a5dee3
commit
e1d78bfefa
@ -112,7 +112,7 @@ def parse_feed(url, session, count=5, blog_url=''):
|
||||
"""
|
||||
try:
|
||||
response = session.get(url, headers=headers, timeout=timeout)
|
||||
response.encoding = 'utf-8'
|
||||
response.encoding = response.apparent_encoding or 'utf-8'
|
||||
feed = feedparser.parse(response.text)
|
||||
|
||||
result = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user