Python库之Requests(iMooc)---(1)
来源:互联网 发布:mac 浏览器 编辑:程序博客网 时间:2024/06/05 00:53
Linux环境下准备:
Requests, httpbin, virtualenv, pip
Linux环境下安装pip需首先安装setuptools.py, 如下:
sudo apt-get install python-setuptools
之后安装pip:
sudo apt-get install python-pip
上述工作完成后,使用pip安装Requests库以及virtualenv:
sudo pip install requests
sudo pip install virtualenv
开启victualenv:
切换至需要目录(最好自己新建一个文件夹用以存放本地网页):
source .env/bin/activate进入虚拟环境,在虚拟环境安装Requests和gunicorn
安装gunicorn命令如下:
sudo pip install gunicorn httpbin
其中httpbin为新建了一个Module,之后键入:
gunicorn httpbin:app
开启本地服务器,方便以后实验,默认地址为127.0.0.1:8000
------Python大法好:)------
阅读全文
0 0
- Python库之Requests(iMooc)---(1)
- Python库之Requests(iMooc)---(2)
- Python库之Requests(iMooc)---(3)
- Python库之Requests(iMooc)---(4)
- Python库之Requests(iMooc)---(5)
- Python之requests库
- python库之requests
- python学习之 requests库
- Python学习之Requests库
- python简洁之道-----Requests库
- Python网络爬虫之Requests库
- Python爬虫之requests
- python之requests篇
- Python之,requests包
- python爬虫之requests
- python requests库 笔记
- python requests库介绍
- python安装requests库
- CentOS7简单配置网络
- 超好用的网络抓包框架(Windivert)之四(实例二)
- 数据库和缓存同步机制
- hdu 6058 Kanade's sum
- 2743: [HEOI2012]采花(离线树状数组)
- Python库之Requests(iMooc)---(1)
- 菜鸟心历之路(6)
- 【JavaScript】最简单的一个例子
- 《Visual Basic 程序设计》——>基本概念
- String类的常用方法(1)A
- LeetCode 231 Power of Two AND LeetCode 326 Power of Three
- bootstrap table中显示头行结构
- zookeeper和dubbo的关系
- Codeforces Round #427 (Div. 2)(A+B)