diff --git a/www/Makefile b/www/Makefile index 042daaf2fa83..10ad3c5f0c2c 100644 --- a/www/Makefile +++ b/www/Makefile @@ -1669,6 +1669,7 @@ SUBDIR += py-httpretty SUBDIR += py-httptools SUBDIR += py-httpx + SUBDIR += py-httpx-oauth SUBDIR += py-httpx-socks SUBDIR += py-httpx013 SUBDIR += py-hyper diff --git a/www/py-httpx-oauth/Makefile b/www/py-httpx-oauth/Makefile new file mode 100644 index 000000000000..e076dc3c954c --- /dev/null +++ b/www/py-httpx-oauth/Makefile @@ -0,0 +1,29 @@ +PORTNAME= httpx-oauth +DISTVERSION= 0.4.1 +CATEGORIES= www devel python +MASTER_SITES= CHEESESHOP +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= meka@tilda.center +COMMENT= Async OAuth client using HTTPX + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}httpx>=0:www/py-httpx@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}respx>=0:www/py-respx@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}typing-extensions>=0:devel/py-typing-extensions@${PY_FLAVOR} +TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest>=0:devel/py-pytest@${PY_FLAVOR} + +USES= python:3.7+ +USE_PYTHON= autoplist distutils + +TEST_ENV= PYTHONPATH=${WRKSRC}/src + +NO_ARCH= yes + +# Tests fail with current ports +# do-test: + # cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m pytest -v -rs -o addopts= + +.include diff --git a/www/py-httpx-oauth/distinfo b/www/py-httpx-oauth/distinfo new file mode 100644 index 000000000000..b3751120c20d --- /dev/null +++ b/www/py-httpx-oauth/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1643132368 +SHA256 (httpx-oauth-0.4.1.tar.gz) = ee777ee8c33ab521b8bee26158bed1c5eb709034559bd53442509e736458ffee +SIZE (httpx-oauth-0.4.1.tar.gz) = 15272 diff --git a/www/py-httpx-oauth/files/patch-setup.py b/www/py-httpx-oauth/files/patch-setup.py new file mode 100644 index 000000000000..a02860017a80 --- /dev/null +++ b/www/py-httpx-oauth/files/patch-setup.py @@ -0,0 +1,28 @@ +--- setup.py.orig 2022-01-25 17:47:55 UTC ++++ setup.py +@@ -0,0 +1,25 @@ ++#!/usr/bin/env python ++# setup.py generated by flit for tools that don't yet use PEP 517 ++ ++from distutils.core import setup ++ ++packages = \ ++['httpx_oauth', 'httpx_oauth.clients', 'httpx_oauth.integrations'] ++ ++package_data = \ ++{'': ['*']} ++ ++install_requires = \ ++['httpx >=0.18,<0.22', 'typing-extensions'] ++ ++setup(name='httpx-oauth', ++ version='0.4.1', ++ description='Async OAuth client using HTTPX.', ++ author='François Voron', ++ author_email='fvoron@gmail.com', ++ url='https://github.com/frankie567/httpx-oauth', ++ packages=packages, ++ package_data=package_data, ++ install_requires=install_requires, ++ python_requires='>=3.7', ++ ) diff --git a/www/py-httpx-oauth/pkg-descr b/www/py-httpx-oauth/pkg-descr new file mode 100644 index 000000000000..ca5848907739 --- /dev/null +++ b/www/py-httpx-oauth/pkg-descr @@ -0,0 +1,4 @@ +A generic OAuth2 class is provided to adapt to any OAuth2-compliant service. +Utilities are provided to ease the integration of an OAuth2 process in FastAPI. + +WWW: https://github.com/frankie567/httpx-oauth