摘要: 基于优先获取item的想法,最下级请求最优先 请求优先级是基于scrapy有很多请求要发起的情况 priority越大请求越优先 不在设置中修改配置 scrapy代码太复杂,这是目前可以接受的解决办法 class xxxspiderSpider(scrapy.Spider): # 三级请求优先级逐级 阅读全文
posted @ 2022-08-16 15:24 meizhengchao 阅读(358) 评论(0) 推荐(0)
摘要: class a(): def a1(self): print(self.a2()) def a2(self): return 'a-a2' class aa(a): def a2(self): return 'aa-a2' c = aa() c.a1() # 输出aa-a2 阅读全文
posted @ 2022-01-03 18:41 meizhengchao 阅读(9) 评论(0) 推荐(0)
摘要: # 无头浏览器下载地址:http://chromedriver.storage.googleapis.com/index.html from selenium import webdriver # 1. 添加浏览器设置参数对象 options = webdriver.ChromeOptions() 阅读全文
posted @ 2021-05-29 16:45 meizhengchao 阅读(328) 评论(0) 推荐(0)