爬取猫眼电影排行榜第一页
import requests
from requests.exceptions import RequestException
from sqlalchemy import create_engine
from lxml import etree
import pandas as pd
import numpy as np
url = 'https://maoyan.com/board/4'
try:
headers={
'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.66 Safari/537.36'}
response=requests.get(url,headers=headers)
if response.</