10 2019 档案

摘要:lables = ['nvbfge','cvbfg','nfsd','jklibn','dfgrt','muyh','ytug','nghmdf','gfhasfecxv']for lable in lables: print(lable) urls_0 = response.xpath("//ma 阅读全文
posted @ 2019-10-29 12:24 乔儿 阅读(354) 评论(0) 推荐(0) 编辑
摘要:# 通过enumerate函数处理列表之后再遍历可以同时获得元素索引和值 for index, elem in enumerate(list1): print(index, elem) 阅读全文
posted @ 2019-10-25 15:02 乔儿 阅读(623) 评论(0) 推荐(0) 编辑
摘要:RETRY_ENABLED = True #打开重试开关RETRY_TIMES = 3 #重试次数DOWNLOAD_TIMEOUT = 3 #超时RETRY_HTTP_CODES = [429,404,403] #重试HTTPERROR_ALLOWED_CODES = [429] #上面报的是403 阅读全文
posted @ 2019-10-24 14:49 乔儿 阅读(5954) 评论(0) 推荐(0) 编辑
摘要:response = requests.post(url=url, data=data, headers=headers)# 获取requests请求返回的cookiecookie = requests.utils.dict_from_cookiejar(response.cookies)retur 阅读全文
posted @ 2019-10-21 17:05 乔儿 阅读(5947) 评论(0) 推荐(0) 编辑
摘要:import time, threading def demo1(value1, value2=None): print("%s threading is printed %s, %s"%(threading.current_thread().name, value1, value2)) time. 阅读全文
posted @ 2019-10-14 16:19 乔儿 阅读(131) 评论(0) 推荐(0) 编辑
摘要:class proxyMiddleware(object): def __init__(self): self.ip_pool_cc = [] self.get_ip_url_cc = 'http://xxxxx' self.ip_pool_cq = [] self.get_ip_url_cq = 阅读全文
posted @ 2019-10-09 09:35 乔儿 阅读(304) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示