Skip to content

Commit a2b1add

Browse files
committed
Update 0008.py
1 parent d860beb commit a2b1add

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

renzongxian/0008/0008.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
def get_body(url):
1717
html_content = urllib.request.urlopen(url).read()
1818
r = re.compile('<p>(?:<.[^>]*>)?(.*?)(?:<.[^>]*>)?</p>')
19-
result = r.findall(html_content.decode('GBK'))
19+
result = r.findall(html_content.decode('GBK').encode('utf-8'))
2020
return result
2121

2222

0 commit comments

Comments
 (0)