资源简介
Python requests模块
代码片段和文件信息
#!/usr/bin/env python
import os
import re
import sys
from codecs import open
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
user_options = [(‘pytest-args=‘ ‘a‘ “Arguments to pass into py.test“)]
def initialize_options(self):
TestCommand.initialize_options(self)
self.pytest_args = []
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
import pytest
errno = pytest.main(self.pytest_args)
sys.exit(errno)
if sys.argv[-1] == ‘publish‘:
os.system(‘python setup.py sdist upload‘)
sys.exit()
packages = [
‘requests‘
‘requests.packages‘
‘requests.packages.chardet‘
‘requests.packages.idna‘
‘requests.packages.urllib3‘
‘requests.packages.urllib3.packages‘
‘requests.packages.urllib3.contrib‘
‘requests.packages.urllib3.util‘
‘requests.packages.urllib3.packages.ssl_match_hostname‘
‘requests.packages.urllib3.packages.backports‘
]
requires = []
test_requirements = [‘pytest>=2.8.0‘ ‘pytest-httpbin==0.0.7‘ ‘pytest-cov‘]
with open(‘requests/__init__.py‘ ‘r‘) as fd:
version = re.search(r‘^__version__\s*=\s*[\‘“]([^\‘“]*)[\‘“]‘
fd.read() re.MULTILINE).group(1)
if not version:
raise RuntimeError(‘Cannot find version information‘)
with open(‘README.rst‘ ‘r‘ ‘utf-8‘) as f:
readme = f.read()
with open(‘HISTORY.rst‘ ‘r‘ ‘utf-8‘) as f:
history = f.read()
setup(
name=‘requests‘
version=version
description=‘Python HTTP for Humans.‘
long_description=readme + ‘\n\n‘ + history
author=‘Kenneth Reitz‘
author_email=‘me@kennethreitz.com‘
url=‘http://python-requests.org‘
packages=packages
package_data={‘‘: [‘LICENSE‘ ‘NOTICE‘] ‘requests‘: [‘*.pem‘]}
package_dir={‘requests‘: ‘requests‘}
include_package_data=True
install_requires=requires
license=‘Apache 2.0‘
zip_safe=False
classifiers=(
‘Development Status :: 5 - Production/Stable‘
‘Intended Audience :: Developers‘
‘Natural Language :: English‘
‘License :: OSI Approved :: Apache Software License‘
‘Programming Language :: Python‘
‘Programming Language :: Python :: 2.6‘
‘Programming Language :: Python :: 2.7‘
‘Programming Language :: Python :: 3‘
‘Programming Language :: Python :: 3.3‘
‘Programming Language :: Python :: 3.4‘
‘Programming Language :: Python :: 3.5‘
‘Programming Language :: Python :: Implementation :: CPython‘
‘Programming Language :: Python :: Implementation :: PyPy‘
)
cmdclass={‘test‘: PyTest}
tests_require=test_requirements
extras_require={
‘security‘: [‘pyOpenSSL>=0.14‘ ‘cryptography>=1.3.4‘ ‘idna>=2.0.0‘]
‘socks‘: [‘PySocks>=1.5.6 !=1.5.7‘]
}
)
相关资源
- python实现SGBM图像匹配算法
- python实现灰度直方图均衡化
- scrapy_qunar_one
- Python学习全系列教程永久可用
- python简明教程.chm
- 抽奖大转盘python的图形化界面
- 双边滤波器实验报告及代码python
- python +MYSQL+HTML实现21蛋糕网上商城
- Python-直播答题助手自动检测出题搜索
- OpenCV入门教程+OpenCV官方教程中文版
- Python 串口工具源码+.exe文件
- Python开发的全栈股票系统.zip
- Python操作Excel表格并将其中部分数据写
- python书籍 PDF
- 利用python绘制散点图
- python+labview+No1.vi
- 老男孩python项目实战
- python源码制作whl文件.rar
- python3.5可用的scipy
- PYTHON3 经典50案例.pptx
- 计算机科学导论-python.pdf
- python模拟鼠标点击屏幕
- windows鼠标自动点击py脚本
- 鱼c小甲鱼零基础学python全套课后题和
- Python 练习题100道
- Practical Programming 2nd Edition
- wxPython Application Development Cookbook
- python 3.6
- Python 3.5.2 中文文档 互联网唯一CHM版本
- python3.5.2.chm官方文档
评论
共有 条评论