Python did not respond when climbing Douban Books, and he did not make a mistake.

Crawler Code:

import requests
import re
content = requests.get("https://book.douban.com/").text
pattern = re.compile("<li.*?cover.*?href="(.*?)".*?title="(.*?)".*?more-meta.*?author">(.*?)</span>.*?year">(.*?)</span>.*?<li>",re.S)
results = re.findall(pattern,content)
print(results)
for result in results:
    url,name,author,date = result
    author = re.sub("\s",author)
    date = re.sub("\s","",date)
    print(url,name,author,date)

execution has been shown to be in execution, but there is no result and no error has been reported. I have been waiting for an hour. Ask God for help to see what the problem is

.
Feb.27,2021

regular writing is problematic and has been jammed. Use the dom parsing library to operate


regular expressions are not written correctly

the correct code is as follows:
import requests
import re
content = requests.get (' https://book.douban.com/').text
pattern = re.compile (r'< li class=">. ? < div class=" cover ">. ?

)
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3054e-2b06b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3054e-2b06b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?