setup.py
This file
Path
setup.py
87 lines · 2.5 KiB · Python
Last changed by
Add `charset_normalizer` detection. (#1791)Tom Christiebefore adoptionacb5e6a
History of this fileTake it
The walk stopped after 200 commits: lines older than 84ca201 point at it.
Add `proxies` parameter to top-level API functions (#1198)Joebefore adoption84ca201
lines 1–43why, one step back1#!/usr/bin/env python2# -*- coding: utf-8 -*-34import re5from pathlib import Path67from setuptools import setup8910def get_version(package):11 """12 Return package version as listed in `__version__` in `init.py`.13 """14 version = Path(package, "__version__.py").read_text()15 return re.search("__version__ = ['\"]([^'\"]+)['\"]", version).group(1)161718def get_long_description():19 """20 Return the README.21 """22 long_description = ""23 with open("README.md", encoding="utf8") as f:24 long_description += f.read()25 long_description += "\n\n"26 with open("CHANGELOG.md", encoding="utf8") as f:27 long_description += f.read()28 return long_description293031def get_packages(package):32 """33 Return root package and all sub-packages.34 """35 return [str(path.parent) for path in Path(package).glob("**/__init__.py")]363738setup(39 name="httpx",40 python_requires=">=3.6",41 version=get_version("httpx"),42 url="https://github.com/encode/httpx",43 project_urls={Add Changelog link to PyPI page (#1462)Adam Johnsonbefore adoptiond964343
line 44why, one step back44 "Changelog": "https://github.com/encode/httpx/blob/master/CHANGELOG.md",Add `proxies` parameter to top-level API functions (#1198)Joebefore adoption84ca201
lines 45–59why, one step back45 "Documentation": "https://www.python-httpx.org",46 "Source": "https://github.com/encode/httpx",47 },48 license="BSD",49 description="The next generation HTTP client.",50 long_description=get_long_description(),51 long_description_content_type="text/markdown",52 author="Tom Christie",53 author_email="tom@tomchristie.com",54 package_data={"httpx": ["py.typed"]},55 packages=get_packages("httpx"),56 include_package_data=True,57 zip_safe=False,58 install_requires=[59 "certifi",Add `charset_normalizer` detection. (#1791)Tom Christiebefore adoptionacb5e6a
line 60why, one step back60 "charset_normalizer",Add `proxies` parameter to top-level API functions (#1198)Joebefore adoption84ca201
line 61why, one step back61 "sniffio",Packaging dependancy tweaks (#1206)Joebefore adoption15c1e42
line 62why, one step back62 "rfc3986[idna2008]>=1.3,<2",Support HTTP/2 prior-knowledge, using `httpx.Client(http1=False, http2=True)`. (#1624)bli74before adoption9b17671
line 63why, one step back63 "httpcore>=0.13.3,<0.14.0",Drop StreamContextManager in favour of `contextlib.contextmanager`/`asynccontextmanager` (#1577)Tom Christiebefore adoption8fd5b71
line 64why, one step back64 "async_generator; python_version < '3.7'"Add `proxies` parameter to top-level API functions (#1198)Joebefore adoption84ca201
lines 65–66why, one step back65 ],66 extras_require={Update HTTP/2 support in `extras_require` (#1799)Tom Christiebefore adoption50790af
line 67why, one step back67 "http2": "h2>=3,<5",Update brotli support to use the brotlicffi package (#1605)Tom Christiebefore adoption760af43
line 68why, one step back68 "brotli": "brotlicffi==1.*",Add `proxies` parameter to top-level API functions (#1198)Joebefore adoption84ca201
lines 69–82why, one step back69 },70 classifiers=[71 "Development Status :: 4 - Beta",72 "Environment :: Web Environment",73 "Intended Audience :: Developers",74 "License :: OSI Approved :: BSD License",75 "Operating System :: OS Independent",76 "Topic :: Internet :: WWW/HTTP",77 "Framework :: AsyncIO",78 "Framework :: Trio",79 "Programming Language :: Python :: 3",80 "Programming Language :: Python :: 3.6",81 "Programming Language :: Python :: 3.7",82 "Programming Language :: Python :: 3.8",Run tests against Python 3.9 and add trove classifier (#1342)Michael Kbefore adoptiona3eb0f9
line 83why, one step back83 "Programming Language :: Python :: 3.9",Test under Python 3.10b3 (#1707)Joebefore adoption6b93787
line 84why, one step back84 "Programming Language :: Python :: 3.10",Add `proxies` parameter to top-level API functions (#1198)Joebefore adoption84ca201
lines 85–87why, one step back85 "Programming Language :: Python :: 3 :: Only",86 ],87)