Python crawler regular matching is incomplete

response = requests.get("https://36kr.com/newsflashes")
        all_list=re.findall(
            ""title":"(.*?)","catch_title":"","description":".*?","cover":"","news_url_type":"news_url","news_url":"(.*?)","user_id":"344033181","published_at":"(.*?)",",
            response.text, re.S)
        print(all_list)
        print(len(all_list))
        

Why can"t my rule match all of them? Only 16 matches can be made. There are 20 headings in total
https://36kr.com/newsflashes. This is the URL

.

generally, it is better to get the json first and then get the data from it. It is reasonable, and it may be useful to have a lot more data.

import requests as req
import json
import re

rsp = req.get('https://36kr.com/newsflashes')
p = r'<script>var props=(.*?}),\s*\w*?='
j = re.findall(p, rsp.text)
dic = json.loads(j[0])
print(dic)
Menu