git: c08853f49ac7 - main - devel/py-retry2: New port: Easy to use retry decorator in python

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Tue, 31 May 2022 03:18:09 UTC
The branch main has been updated by yuri:

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

commit c08853f49ac748908004d2cfa81022fd59b76b9d
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2022-05-31 02:37:09 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2022-05-31 03:18:02 +0000

    devel/py-retry2: New port: Easy to use retry decorator in python
---
 devel/Makefile                       |  1 +
 devel/py-retry2/Makefile             | 28 ++++++++++++++++++++++++++++
 devel/py-retry2/distinfo             |  3 +++
 devel/py-retry2/files/patch-setup.py | 13 +++++++++++++
 devel/py-retry2/pkg-descr            |  8 ++++++++
 5 files changed, 53 insertions(+)

diff --git a/devel/Makefile b/devel/Makefile
index b55986f47874..b97ff1004f7c 100644
--- a/devel/Makefile
+++ b/devel/Makefile
@@ -5241,6 +5241,7 @@
     SUBDIR += py-resolver
     SUBDIR += py-resource
     SUBDIR += py-responses
+    SUBDIR += py-retry2
     SUBDIR += py-retrying
     SUBDIR += py-retype
     SUBDIR += py-rfc3339
diff --git a/devel/py-retry2/Makefile b/devel/py-retry2/Makefile
new file mode 100644
index 000000000000..dfb2c8b1cfcc
--- /dev/null
+++ b/devel/py-retry2/Makefile
@@ -0,0 +1,28 @@
+PORTNAME=	retry2
+DISTVERSION=	0.9.3
+CATEGORIES=	devel python
+#MASTER_SITES=	CHEESESHOP # no tarball
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	yuri@FreeBSD.org
+COMMENT=	Easy to use retry decorator in python
+
+LICENSE=	APACHE20
+
+RUN_DEPENDS=	${PYNUMPY} \
+		${PYTHON_PKGNAMEPREFIX}py>=1.4.26:devel/py-py@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}decorator>=3.4.2:devel/py-decorator@${PY_FLAVOR}
+
+USES=		python:3.6+
+USE_PYTHON=	distutils autoplist
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	eSAMTrade
+GH_PROJECT=	retry
+
+NO_ARCH=	yes
+
+do-test: install
+	@cd ${WRKSRC} && ${PYTHON_CMD} tests/test_retry.py && ${ECHO} "Tests succeeded"
+
+.include <bsd.port.mk>
diff --git a/devel/py-retry2/distinfo b/devel/py-retry2/distinfo
new file mode 100644
index 000000000000..bb71921d78cd
--- /dev/null
+++ b/devel/py-retry2/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1653963869
+SHA256 (eSAMTrade-retry-0.9.3_GH0.tar.gz) = 4e5faaf2c944275336d1e81e3c1100eb62a325cb5ba019af33e50b3384e155a1
+SIZE (eSAMTrade-retry-0.9.3_GH0.tar.gz) = 6004
diff --git a/devel/py-retry2/files/patch-setup.py b/devel/py-retry2/files/patch-setup.py
new file mode 100644
index 000000000000..51cdf0675c00
--- /dev/null
+++ b/devel/py-retry2/files/patch-setup.py
@@ -0,0 +1,13 @@
+- prevent versioning via git
+
+--- setup.py.orig	2022-05-31 02:31:10 UTC
++++ setup.py
+@@ -3,6 +3,6 @@ from setuptools import find_packages, setup
+ 
+ setup(
+     packages=find_packages(),
+-    pbr=True,
+-    setup_requires=['pbr'],
++    #pbr=True,
++    #setup_requires=['pbr'],
+ )
diff --git a/devel/py-retry2/pkg-descr b/devel/py-retry2/pkg-descr
new file mode 100644
index 000000000000..8619a08602f4
--- /dev/null
+++ b/devel/py-retry2/pkg-descr
@@ -0,0 +1,8 @@
+Easy to use retry decorator.
+Features
+
+* No external dependency (stdlib only).
+* (Optionally) Preserve function signatures (pip install decorator).
+* Original traceback, easy to debug.
+
+WWW: https://github.com/eSAMTrade/retry