Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 Mar 2022 17:20:21 GMT
From:      Po-Chuan Hsieh <sunpoet@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: fb5f8f301150 - main - www/py-requests: Fix build with py-idna 3.*
Message-ID:  <202203251720.22PHKLOD025684@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=fb5f8f301150da3a6cbd7b395788cb057fca6e9a

commit fb5f8f301150da3a6cbd7b395788cb057fca6e9a
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-03-25 17:15:39 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-03-25 17:19:24 +0000

    www/py-requests: Fix build with py-idna 3.*
    
    - Update version requirement of *_DEPENDS
    - Clean up TEST_DEPENDS
    - Update do-test:
    - Bump PORTREVISION for package change
---
 www/py-requests/Makefile             | 23 +++++++++++------------
 www/py-requests/files/patch-setup.py | 11 +++++++++++
 2 files changed, 22 insertions(+), 12 deletions(-)

diff --git a/www/py-requests/Makefile b/www/py-requests/Makefile
index 5795da3f24a3..0f240f59bbfa 100644
--- a/www/py-requests/Makefile
+++ b/www/py-requests/Makefile
@@ -2,6 +2,7 @@
 
 PORTNAME=	requests
 PORTVERSION=	2.25.1
+PORTREVISION=	1
 CATEGORIES=	www python
 MASTER_SITES=	CHEESESHOP
 PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
@@ -13,17 +14,15 @@ LICENSE=	APACHE20
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
 RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}certifi>=2017.4.17:security/py-certifi@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}chardet>=3.0.2:textproc/py-chardet@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}idna>=2.5:dns/py-idna@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}urllib3>=1.21.1:net/py-urllib3@${PY_FLAVOR}
-TEST_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pytest>=2.8.0:devel/py-pytest@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}pytest-cov>0:devel/py-pytest-cov@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}pytest-httpbin>0:devel/py-pytest-httpbin@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}pytest-mock>0:devel/py-pytest-mock@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}pytest-xdist>0:devel/py-pytest-xdist@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}httpbin>0:www/py-httpbin@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} \
-		${PYTHON_PKGNAMEPREFIX}blinker>0:devel/py-blinker@${PY_FLAVOR}
+		${PYTHON_PKGNAMEPREFIX}chardet>=3.0.2,1<5,1:textproc/py-chardet@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}idna>=2.5<4:dns/py-idna@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}urllib3>=1.21.1,1<1.27,1:net/py-urllib3@${PY_FLAVOR}
+TEST_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pysocks>=1.5.6:net/py-pysocks@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest>=3,1:devel/py-pytest@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-cov>=0:devel/py-pytest-cov@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-httpbin>=0.0.7:devel/py-pytest-httpbin@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-mock>=0:devel/py-pytest-mock@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest-xdist>=0,1:devel/py-pytest-xdist@${PY_FLAVOR}
 
 USES=		cpe python:3.6+
 USE_PYTHON=	autoplist concurrent distutils
@@ -42,6 +41,6 @@ SECURITY_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}cryptography>=1.3.4:security/py-cry
 SOCKS_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pysocks>=1.5.6:net/py-pysocks@${PY_FLAVOR}
 
 do-test:
-	@cd ${WRKSRC} && pytest tests -v
+	cd ${WRKSRC} && ${PYTHON_CMD} -m pytest -rs -v
 
 .include <bsd.port.mk>
diff --git a/www/py-requests/files/patch-setup.py b/www/py-requests/files/patch-setup.py
new file mode 100644
index 000000000000..601ce557a7df
--- /dev/null
+++ b/www/py-requests/files/patch-setup.py
@@ -0,0 +1,11 @@
+--- setup.py.orig	2020-12-16 17:43:25 UTC
++++ setup.py
+@@ -43,7 +43,7 @@ packages = ['requests']
+ 
+ requires = [
+     'chardet>=3.0.2,<5',
+-    'idna>=2.5,<3',
++    'idna>=2.5,<4',
+     'urllib3>=1.21.1,<1.27',
+     'certifi>=2017.4.17'
+ 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202203251720.22PHKLOD025684>