摘要: resrest库是 python实现的简单的应用的库,可以做爬虫使用 1、例程 import requests response = requests.get("https://baidu.com") print(response) # <Response [200]> print(type(res 阅读全文
posted @ 2020-08-27 18:17 yxlll 阅读(191) 评论(0) 推荐(0) 编辑
摘要: urllib库是 python内置的一个库,用于 HTTP的访问 其中包括4个模块 urllib.request 基本 HTTP请求模块,类似于浏览器上输入网址 url,获取网页源代码 urllib.error 异常处理模块,当获取网页数据错误时,可以使程序不退出,进行重试等操作 urllib.pa 阅读全文
posted @ 2020-08-27 10:37 yxlll 阅读(136) 评论(0) 推荐(0) 编辑