爬猫眼电影top100

Posted bearcarl

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了爬猫眼电影top100相关的知识,希望对你有一定的参考价值。

学的是《python3网络爬虫开发实战》里的代码,就改了下正则。

import requests
import re
import json
import time
from requests.exceptions import RequestException


def get_one_page(url):
    try:
        headers = {
            User-Agent: "Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN) AppleWebKit/523.15 "
                          "(Khtml, like Gecko, Safari/419.3)Arora/0.3 (Change: 287 c9dfb30)"
        }
        response = requests.get(url, headers=headers)
        if response.status_code == 200:
            return response.text
        return None
    except RequestException:
        return None


def parse_one_page(html):
    print(type(html))
    pattern = re.compile(
        <dd>.*?board-index.*?>(.*?)</i>.*?data-src.*?"(.*?)".*?name.*?a.*?>(.*?)</a>.*?star.*?>(.*?)</p>.*?releasetime.*?>(.*?)</p>.*?integer.*?>(.*?)</i>.*?fraction.*?>(.*?)</i>.*?</dd>,
        re.S)
    items = re.findall(pattern, html)
    print(items)
    for item in items:
        yield {
            index: item[0],
            image: item[1],
            title: item[2].strip(),
            action: item[3].strip()[3:] if len(item[3]) > 3 else ‘‘,
            time: item[4].strip()[5:] if len(item[4]) > 5 else ‘‘,
            score: item[5].strip() + item[6].strip()
        }


def write_to_file(content):
    with open(result.txt, a, encoding=utf-8) as f:
        f.write(json.dumps(content, ensure_ascii=False) + 
)


def main(offset):
    url = http://maoyan.com/board/4?offset= + str(offset)
    html = get_one_page(url)
    for item in parse_one_page(html):
        print(item)
        write_to_file(item)


if __name__ == __main__:
    for i in range(10):
        main(offset=i * 10)
        time.sleep(1)

 

效果(result.txt):

{"index": "1", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "霸王别姬", "action": "张国荣,张丰毅,巩俐", "time": "1993-01-01(中国香港)", "score": "9.6"}
{"index": "2", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "肖申克的救赎", "action": "蒂姆·罗宾斯,摩根·弗里曼,鲍勃·冈顿", "time": "1994-10-14(美国)", "score": "9.5"}
{"index": "3", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "罗马假日", "action": "格利高里·派克,奥黛丽·赫本,埃迪·艾伯特", "time": "1953-09-02(美国)", "score": "9.1"}
{"index": "4", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "这个杀手不太冷", "action": "让·雷诺,加里·奥德曼,娜塔莉·波特曼", "time": "1994-09-14(法国)", "score": "9.5"}
{"index": "5", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "教父", "action": "马龙·白兰度,阿尔·帕西诺,詹姆斯·肯恩", "time": "1972-03-24(美国)", "score": "9.3"}
{"index": "6", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "泰坦尼克号", "action": "莱昂纳多·迪卡普里奥,凯特·温丝莱特,比利·赞恩", "time": "1998-04-03", "score": "9.5"}
{"index": "7", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "龙猫", "action": "日高法子,坂本千夏,糸井重里", "time": "1988-04-16(日本)", "score": "9.2"}
{"index": "8", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "唐伯虎点秋香", "action": "周星驰,巩俐,郑佩佩", "time": "1993-07-01(中国香港)", "score": "9.2"}
{"index": "9", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "千与千寻", "action": "柊瑠美,入野自由,夏木真理", "time": "2001-07-20(日本)", "score": "9.3"}
{"index": "10", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "魂断蓝桥", "action": "费雯·丽,罗伯特·泰勒,露塞尔·沃特森", "time": "1940-05-17(美国)", "score": "9.2"}
{"index": "11", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "乱世佳人", "action": "费雯·丽,克拉克·盖博,奥利维娅·德哈维兰", "time": "1939-12-15(美国)", "score": "9.1"}
{"index": "12", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "喜剧之王", "action": "周星驰,莫文蔚,张柏芝", "time": "1999-02-13(中国香港)", "score": "9.2"}
{"index": "13", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "天空之城", "action": "寺田农,鹫尾真知子,龟山助清", "time": "1992", "score": "9.1"}
{"index": "14", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "大闹天宫", "action": "邱岳峰,毕克,富润生", "time": "1965-12-31", "score": "9.0"}
{"index": "15", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "辛德勒的名单", "action": "连姆·尼森,拉尔夫·费因斯,本·金斯利", "time": "1993-12-15(美国)", "score": "9.2"}
{"index": "16", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "音乐之声", "action": "朱莉·安德鲁斯,克里斯托弗·普卢默,埃琳诺·帕克", "time": "1965-03-02(美国)", "score": "9.0"}
{"index": "17", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "春光乍泄", "action": "张国荣,梁朝伟,张震", "time": "1997-05-30(中国香港)", "score": "9.2"}
{"index": "18", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "剪刀手爱德华", "action": "约翰尼·德普,薇诺娜·瑞德,黛安·韦斯特", "time": "1990-12-06(美国)", "score": "8.8"}
{"index": "19", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "美丽人生", "action": "罗伯托·贝尼尼,尼可莱塔·布拉斯基,乔治·坎塔里尼", "time": "1997-12-20(意大利)", "score": "9.3"}
{"index": "20", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "海上钢琴师", "action": "蒂姆·罗斯,普路特·泰勒·文斯,比尔·努恩", "time": "1998-10-28(意大利)", "score": "9.2"}
{"index": "21", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "黑客帝国", "action": "基努·里维斯,凯瑞-安·莫斯,劳伦斯·菲什伯恩", "time": "2000-01-14", "score": "9.0"}
{"index": "22", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "指环王3:王者无敌", "action": "伊莱贾·伍德,伊恩·麦克莱恩,丽芙·泰勒", "time": "2004-03-15", "score": "9.2"}
{"index": "23", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "加勒比海盗", "action": "约翰尼·德普,凯拉·奈特莉,奥兰多·布鲁姆", "time": "2003-11-21", "score": "8.9"}
{"index": "24", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "哈利·波特与魔法石", "action": "丹尼尔·雷德克里夫,鲁伯特·格林特,艾玛·沃森", "time": "2002-01-26", "score": "9.1"}
{"index": "25", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "蝙蝠侠:黑暗骑士", "action": "克里斯蒂安·贝尔,希斯·莱杰,艾伦·艾克哈特", "time": "2008-07-18(美国)", "score": "9.3"}
{"index": "26", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "楚门的世界", "action": "金·凯瑞,劳拉·琳妮,诺亚·艾默里奇", "time": "1998-06-01(美国)", "score": "8.9"}
{"index": "27", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "射雕英雄传之东成西就", "action": "张国荣,梁朝伟,张学友", "time": "1993-02-05(中国香港)", "score": "8.9"}
{"index": "28", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "无间道", "action": "刘德华,梁朝伟,黄秋生", "time": "2003-09-05", "score": "9.1"}
{"index": "29", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "指环王2:双塔奇兵", "action": "伊莱贾·伍德,伊恩·麦克莱恩,丽芙·泰勒", "time": "2003-04-25", "score": "9.1"}
{"index": "30", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "机器人总动员", "action": "本·贝尔特,艾丽莎·奈特,杰夫·格尔林", "time": "2008-06-27(美国)", "score": "9.3"}
{"index": "31", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "教父2", "action": "阿尔·帕西诺,罗伯特·德尼罗,黛安·基顿", "time": "1974-12-12(美国)", "score": "9.0"}
{"index": "32", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "活着", "action": "葛优,巩俐,牛犇", "time": "1994-05-18(法国)", "score": "9.0"}
{"index": "33", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "天堂电影院", "action": "菲利普·努瓦雷,赛尔乔·卡斯特利托,蒂兹亚娜·罗达托", "time": "1988-11-17(意大利)", "score": "9.2"}
{"index": "34", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "拯救大兵瑞恩", "action": "汤姆·汉克斯,马特·达蒙,汤姆·塞兹摩尔", "time": "1998-07-24(美国)", "score": "8.9"}
{"index": "35", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "忠犬八公的故事", "action": "Forest,理查·基尔,琼·艾伦", "time": "2010-03-12(英国)", "score": "9.3"}
{"index": "36", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "哈尔的移动城堡", "action": "倍赏千惠子,木村拓哉,美轮明宏", "time": "2004-11-20(日本)", "score": "9.0"}
{"index": "37", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "东邪西毒", "action": "张国荣,梁朝伟,刘嘉玲", "time": "1994-09-17", "score": "8.9"}
{"index": "38", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "幽灵公主", "action": "松田洋治,石田百合子,田中裕子", "time": "1997-07-12(日本)", "score": "8.9"}
{"index": "39", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "盗梦空间", "action": "莱昂纳多·迪卡普里奥,渡边谦,约瑟夫·高登-莱维特", "time": "2010-09-01", "score": "9.2"}
{"index": "40", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "搏击俱乐部", "action": "爱德华·诺顿,布拉德·皮特,海伦娜·伯翰·卡特", "time": "1999-10-15(美国)", "score": "8.8"}
{"index": "41", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "疯狂原始人", "action": "尼古拉斯·凯奇,艾玛·斯通,瑞恩·雷诺兹", "time": "2013-04-20", "score": "9.5"}
{"index": "42", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "阿凡达", "action": "萨姆·沃辛顿,佐伊·索尔达娜,米歇尔·罗德里格兹", "time": "2010-01-04", "score": "9.0"}
{"index": "43", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "V字仇杀队", "action": "娜塔莉·波特曼,雨果·维文,斯蒂芬·瑞", "time": "2006-03-17(美国)", "score": "8.8"}
{"index": "44", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "风之谷", "action": "岛本须美,永井一郎,坂本千夏", "time": "1992", "score": "8.9"}
{"index": "45", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "放牛班的春天", "action": "热拉尔·朱尼奥,尚-巴堤·莫里耶,玛丽·布奈尔", "time": "2004-10-16", "score": "8.9"}
{"index": "46", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "当幸福来敲门", "action": "威尔·史密斯,贾登·史密斯,坦迪·牛顿", "time": "2008-01-17", "score": "8.9"}
{"index": "47", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "十二怒汉", "action": "亨利·方达,李·科布,马丁·鲍尔萨姆", "time": "1957-04-13(美国)", "score": "9.1"}
{"index": "48", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "速度与激情5", "action": "范·迪塞尔,保罗·沃克,道恩·强森", "time": "2011-05-12", "score": "9.2"}
{"index": "49", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "驯龙高手", "action": "杰伊·巴鲁切尔,杰拉德·巴特勒,亚美莉卡·费雷拉", "time": "2010-05-14", "score": "9.0"}
{"index": "50", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "神偷奶爸", "action": "史蒂夫·卡瑞尔,杰森·席格尔,拉塞尔·布兰德", "time": "2010-07-09(美国)", "score": "9.0"}
{"index": "51", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "勇敢的心", "action": "梅尔·吉布森,苏菲·玛索,帕特里克·麦高汉", "time": "1995-05-24(美国)", "score": "8.8"}
{"index": "52", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "黑客帝国3:矩阵革命", "action": "基努·里维斯,雨果·维文,凯瑞-安·莫斯", "time": "2003-11-05", "score": "8.8"}
{"index": "53", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "三傻大闹宝莱坞", "action": "阿米尔·汗,黄渤,卡琳娜·卡普尔", "time": "2011-12-08", "score": "9.1"}
{"index": "54", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "断背山", "action": "希斯·莱杰,杰克·吉伦哈尔,米歇尔·威廉姆斯", "time": "2006-01-13(美国)", "score": "9.0"}
{"index": "55", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "闻香识女人", "action": "阿尔·帕西诺,克里斯·奥唐纳,加布里埃尔·安瓦尔", "time": "1992-12-23(美国)", "score": "8.8"}
{"index": "56", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "飞屋环游记", "action": "爱德华·阿斯纳,乔丹·长井,鲍勃·彼德森", "time": "2009-08-04", "score": "8.9"}
{"index": "57", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "飞越疯人院", "action": "杰克·尼科尔森,路易丝·弗莱彻,威尔·萨姆森", "time": "1975-11-19(美国)", "score": "8.8"}
{"index": "58", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "鬼子来了", "action": "姜文,姜宏波,陈强", "time": "2000-05-12(法国戛纳)", "score": "8.9"}
{"index": "59", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "少年派的奇幻漂流", "action": "苏拉·沙玛,伊尔凡·可汗,塔布", "time": "2012-11-22", "score": "9.1"}
{"index": "60", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "致命魔术", "action": "休·杰克曼,克里斯蒂安·贝尔,迈克尔·凯恩", "time": "2006-10-20(美国)", "score": "8.8"}
{"index": "61", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "美国往事", "action": "罗伯特·德尼罗,詹姆斯·伍兹,伊丽莎白·麦戈文", "time": "1984-02-17(美国)", "score": "9.1"}
{"index": "62", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "怦然心动", "action": "玛德琳·卡罗尔,卡兰·麦克奥利菲,艾丹·奎因", "time": "2010-08-06(美国)", "score": "8.9"}
{"index": "63", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "美丽心灵", "action": "罗素·克劳,詹妮弗·康纳利,艾德·哈里斯", "time": "2001-12-21(美国)", "score": "8.8"}
{"index": "64", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "夜访吸血鬼", "action": "汤姆·克鲁斯,布拉德·皮特,克斯汀·邓斯特", "time": "1994-11-11(美国)", "score": "8.8"}
{"index": "65", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "大话西游之月光宝盒", "action": "周星驰,莫文蔚,吴孟达", "time": "2014-10-24", "score": "9.6"}
{"index": "66", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "蝙蝠侠:黑暗骑士崛起", "action": "克里斯蒂安·贝尔,迈克尔·凯恩,加里·奥德曼", "time": "2012-08-27", "score": "8.9"}
{"index": "67", "image": "http://p1.meituan.net/movie/484171372de4594[email protected]_220h_1e_1c", "title": "钢琴家", "action": "艾德里安·布洛迪,艾米莉娅·福克斯,米哈乌·热布罗夫斯基", "time": "2002-09-25(法国)", "score": "8.8"}
{"index": "68", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "无敌破坏王", "action": "约翰·C·赖利,萨拉·西尔弗曼,简·林奇", "time": "2012-11-06", "score": "9.0"}
{"index": "69", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "本杰明·巴顿奇事", "action": "布拉德·皮特,凯特·布兰切特,塔拉吉·P·汉森", "time": "2008-12-25(美国)", "score": "8.8"}
{"index": "70", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "倩女幽魂", "action": "张国荣,王祖贤,午马", "time": "2011-04-30", "score": "9.1"}
{"index": "71", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "哈利·波特与死亡圣器(下)", "action": "丹尼尔·雷德克里夫,鲁伯特·格林特,艾玛·沃森", "time": "2011-08-04", "score": "9.0"}
{"index": "72", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "初恋这件小事", "action": "马里奥·毛瑞尔,平采娜·乐维瑟派布恩,阿查拉那·阿瑞亚卫考", "time": "2012-06-05", "score": "8.8"}
{"index": "73", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "新龙门客栈", "action": "张曼玉,梁家辉,甄子丹", "time": "2012-02-24", "score": "8.8"}
{"index": "74", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "甜蜜蜜", "action": "黎明,张曼玉,曾志伟", "time": "2015-02-13", "score": "9.2"}
{"index": "75", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "触不可及", "action": "弗朗索瓦·克鲁塞,奥玛·希,安娜·勒尼", "time": "2011-11-02(法国)", "score": "9.1"}
{"index": "76", "image": "http://p0.meituan.net/movie/40/[email protected]_220h_1e_1c", "title": "熔炉", "action": "孔刘,郑有美,金智英", "time": "2011-09-22(韩国)", "score": "8.8"}
{"index": "77", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "大话西游之大圣娶亲", "action": "周星驰,朱茵,莫文蔚", "time": "2014-10-24", "score": "8.8"}
{"index": "78", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "小鞋子", "action": "默罕默德·阿米尔·纳吉,Kamal Mirkarimi,Behzad Rafi", "time": "1999-01-22(美国)", "score": "9.1"}
{"index": "79", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "素媛", "action": "李来,薛耿求,严志媛", "time": "2013-10-02(韩国)", "score": "9.1"}
{"index": "80", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "萤火之森", "action": "内山昂辉,佐仓绫音,后藤弘树", "time": "2011-09-17(日本)", "score": "9.0"}
{"index": "81", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "窃听风暴", "action": "乌尔里希·穆埃,塞巴斯蒂安·科赫,马蒂娜·格德克", "time": "2006-03-23(德国)", "score": "9.0"}
{"index": "82", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "穿条纹睡衣的男孩", "action": "阿萨·巴特菲尔德,维拉·法米加,大卫·休里斯", "time": "2008-09-12(英国)", "score": "9.0"}
{"index": "83", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "时空恋旅人", "action": "瑞秋·麦克亚当斯,多姆纳尔·格里森,比尔·奈伊", "time": "2013-09-04(英国)", "score": "8.9"}
{"index": "84", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "借东西的小人阿莉埃蒂", "action": "志田未来,神木隆之介,大竹忍", "time": "2010-07-17(日本)", "score": "8.8"}
{"index": "85", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "7号房的礼物", "action": "柳承龙,郑镇荣,朴信惠", "time": "2013-01-23(韩国)", "score": "8.9"}
{"index": "86", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "海豚湾", "action": "里克·奥巴瑞,路易·西霍尤斯,哈迪·琼斯", "time": "2009-07-31(美国)", "score": "8.9"}
{"index": "87", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "恐怖直播", "action": "河正宇,李璟荣,李大为", "time": "2013-07-31(韩国)", "score": "8.8"}
{"index": "88", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "忠犬八公物语", "action": "仲代达矢,春川真澄,井川比佐志", "time": "1987-08-01(日本)", "score": "9.0"}
{"index": "89", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "上帝之城", "action": "亚历桑德雷·罗德里格斯,艾莉丝·布拉加,莱安德鲁·菲尔米诺", "time": "2002-08-30(巴西)", "score": "8.9"}
{"index": "90", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "辩护人", "action": "宋康昊,郭度沅,吴达洙", "time": "2013-12-18(韩国)", "score": "8.8"}
{"index": "91", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "七武士", "action": "三船敏郎,志村乔,千秋实", "time": "1954-04-26(日本)", "score": "9.1"}
{"index": "92", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "完美的世界", "action": "凯文·科斯特纳,克林特·伊斯特伍德,T·J·劳瑟", "time": "1993-11-24(美国)", "score": "8.9"}
{"index": "93", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "一一", "action": "吴念真,金燕玲,李凯莉", "time": "2000-09-20(法国)", "score": "8.9"}
{"index": "94", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "海洋", "action": "雅克·贝汉,姜文,兰斯洛特·贝汉", "time": "2011-08-12", "score": "9.0"}
{"index": "95", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "爱·回家", "action": "俞承豪,金艺芬,童孝熙", "time": "2002-04-05(韩国)", "score": "9.0"}
{"index": "96", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "黄金三镖客", "action": "克林特·伊斯特伍德,李·范·克里夫,埃里·瓦拉赫", "time": "1966-12-23(意大利)", "score": "8.9"}
{"index": "97", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "我爱你", "action": "宋在浩,李顺才,尹秀晶", "time": "2011-02-17(韩国)", "score": "9.0"}
{"index": "98", "image": "http://p1.meituan.net/movie/[email protected]_220h_1e_1c", "title": "迁徙的鸟", "action": "雅克·贝汉,Philippe Labro", "time": "2001-12-12(法国)", "score": "9.1"}
{"index": "99", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "阿飞正传", "action": "张国荣,张曼玉,刘德华", "time": "2018-06-25", "score": "8.8"}
{"index": "100", "image": "http://p0.meituan.net/movie/[email protected]_220h_1e_1c", "title": "英雄本色", "action": "狄龙,张国荣,周润发", "time": "2017-11-17", "score": "9.2"}

  

以上是关于爬猫眼电影top100的主要内容,如果未能解决你的问题,请参考以下文章

Requwsts+正则表达式爬取猫眼电影Top100

Requests+正则爬取猫眼电影TOP100

request+正则爬猫眼电影榜top100

[爬虫]requests+正则表达式爬取猫眼电影TOP100

Python | requests+正则表达式爬取猫眼电影TOP100

Requests+正则表达式爬取猫眼TOP100电影