安装Requests
生活随笔
收集整理的這篇文章主要介紹了
安装Requests
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
前言
網絡爬蟲的起步就是根據URL來獲取網頁的HTML信息。
在python3中,可以使用urllib.request和requests進行網頁爬取。
urllib是python內置的,只要安裝了python就可以使用這個庫。
安裝Requests
打開cmd,輸入:
pip install requests如果提示:
?Could not find a version that satisfies the requirement requests (from version : )
重新執行一遍命令
獲得源碼
github地址:
https://github.com/requests/requests
你可以克隆公共版本庫:
git clone git://github.com/kennethreitz/requests.git獲得代碼之后,你就可以將其嵌入到你的python包中,或者安裝到你的site-package:
cd requests pip install?
總結
以上是生活随笔為你收集整理的安装Requests的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Could not find a ver
- 下一篇: vue中使用moment来实现导出exc