summaryrefslogtreecommitdiff
path: root/dev-python/pyrate-limiter
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-03-18 06:49:50 +0000
committerV3n3RiX <venerix@koprulu.sector>2024-03-18 06:49:50 +0000
commit529bbf6d047ac6b80c0d9310ec0f666c145ec5fe (patch)
treeae415fb3fee6b16f7371a5d3597dcf98cca19b62 /dev-python/pyrate-limiter
parentec33f4bcbd3944dc39c56a98cde12232684932cf (diff)
gentoo auto-resync : 18:03:2024 - 06:49:50
Diffstat (limited to 'dev-python/pyrate-limiter')
-rw-r--r--dev-python/pyrate-limiter/Manifest2
-rw-r--r--dev-python/pyrate-limiter/pyrate-limiter-3.6.0.ebuild75
2 files changed, 77 insertions, 0 deletions
diff --git a/dev-python/pyrate-limiter/Manifest b/dev-python/pyrate-limiter/Manifest
index 8fedf3babf37..937e135ae482 100644
--- a/dev-python/pyrate-limiter/Manifest
+++ b/dev-python/pyrate-limiter/Manifest
@@ -2,8 +2,10 @@ DIST pyrate-limiter-2.10.0.gh.tar.gz 71838 BLAKE2B 3b8fd16684268870991c3a731c549
DIST pyrate_limiter-3.2.1.tar.gz 277166 BLAKE2B eb126b94bc9a113addd1e727ae21ee2df447e1f9fc0b3a1b77ab46464186a0cb62584fafbc9fac1ddbcc7c3289338208dfb39070e57e974e00442b1d7c5f0d21 SHA512 cb782766c2e1e47aeb35c3d7d03f9a82862a53e73b5afdab1b8a255866392cf0636340164c19e4181e8aa4327e9c346fc2fde64b2f50aaf227dd60633038f7c7
DIST pyrate_limiter-3.3.0.tar.gz 278153 BLAKE2B df0e3aaf53150fb905be994c8bcc268e45bafddf795514eb8a6ee56da25e998b85336f48331a2720cbf501cb6feee806c9c17d99adcb4647979f6d79f960cc9f SHA512 ee2cc0c573c7b696e6a6444eca85b4e5c8315c291b6ab64ed5e60cfd54298cd9aca1efdbfb7a669b92f8169848c03287ecb0a3f50c9281a4bc15acfc1713e300
DIST pyrate_limiter-3.4.1.tar.gz 278251 BLAKE2B c1894a190d0d70134683723d8ffa2b216ebf724cd409e9cc25301b9a9d70d73cf1e4fc1c7bf48e661935cc6f2c530b9d45f96d7c86ce2a20ab0e47892093e6d3 SHA512 64c06abaf540e21e4b085062eff83f1f9d1710156c2d22c0180858c31f731733d9db69bdc56e48aaf4220d874d9c5253f506decd0ce3743c8fb8aa695a4ff6b4
+DIST pyrate_limiter-3.6.0.tar.gz 280021 BLAKE2B 4ff5e115376cfb5d860c4cd6437ccbb323e40f96bb81a9933f6f648d029c0f3a1d6674e1a9e1c0309a7087a9d1eb670918ca60d3c960e8acab017e12ffa5c28e SHA512 1f7f92203be443c27e2825022462c51eec2e276a4e58afc129599eacde21da55ed8229b0e5c7af21e650eb896b22c73f5fd227f56c1455cbd8d506894fed73a9
EBUILD pyrate-limiter-2.10.0.ebuild 1616 BLAKE2B d349d41a6c4f25164f1fa1f86f990ffb61e69e97e4b23e7ec9e2800cc17f10afaa7904f325956a2cb9443be14bcb563da94c8733b54d1ce9e7b0011a4fe29fa1 SHA512 76d89db635828ed2ff88c46f090b0ba41d364b20787df37c4b162da8071558440124dfabd3f2a9b06bcc0540f28d974d234e65333fa095860e2bd00f9ba0cd1a
EBUILD pyrate-limiter-3.2.1.ebuild 1617 BLAKE2B f08fc50f04941d344b3f793a458050263f1fd35fac55a0984d7b940eac628d635105945441bb1fd4cf5d1b69e29265a1e141028410e741b30f8df0fc8251d117 SHA512 00037202a9491b2a0d6d141ac63c252aa3237610f7afbaba1290dd75ea1c853637320d96b32f9b0759ef7e64297ee3d6b13b8039091cf454153d08dcdd065be9
EBUILD pyrate-limiter-3.3.0.ebuild 1617 BLAKE2B f08fc50f04941d344b3f793a458050263f1fd35fac55a0984d7b940eac628d635105945441bb1fd4cf5d1b69e29265a1e141028410e741b30f8df0fc8251d117 SHA512 00037202a9491b2a0d6d141ac63c252aa3237610f7afbaba1290dd75ea1c853637320d96b32f9b0759ef7e64297ee3d6b13b8039091cf454153d08dcdd065be9
EBUILD pyrate-limiter-3.4.1.ebuild 1617 BLAKE2B f08fc50f04941d344b3f793a458050263f1fd35fac55a0984d7b940eac628d635105945441bb1fd4cf5d1b69e29265a1e141028410e741b30f8df0fc8251d117 SHA512 00037202a9491b2a0d6d141ac63c252aa3237610f7afbaba1290dd75ea1c853637320d96b32f9b0759ef7e64297ee3d6b13b8039091cf454153d08dcdd065be9
+EBUILD pyrate-limiter-3.6.0.ebuild 1674 BLAKE2B 228cd917e1c0da910f9381bd65f2853b345becf3d96dd62b5c30dbc4ca118859e6628fa0dd868c85d53577757436f533e5b2907ffd2ecbd03fd85ffdbb0716bf SHA512 a59f0a7f9c476bc4373863c2b84b59aa1dceaa35c2099abc8856ede0fd482be6585b6c58c96a3b683eb51ea42efb49b0029cce488b67cff9c06779cb9a195cfe
MISC metadata.xml 525 BLAKE2B 8daa0c59b247c8ec215a3868315f383614b24bf36a80950f3a94968856a27ee2eb90cedba36784355926c509a26b530f3de44be729beeee0f22595cc0b9467b5 SHA512 429e23f33cd2889a7e989333a03ee374cbec2e264d354bf1c299263f2c9167059eb17f1c975b67cd4af7011843c3478d5296033666566bca97749ca85dfcab44
diff --git a/dev-python/pyrate-limiter/pyrate-limiter-3.6.0.ebuild b/dev-python/pyrate-limiter/pyrate-limiter-3.6.0.ebuild
new file mode 100644
index 000000000000..276657b6cf9d
--- /dev/null
+++ b/dev-python/pyrate-limiter/pyrate-limiter-3.6.0.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=poetry
+PYTHON_COMPAT=( pypy3 python3_{10..12} )
+
+inherit distutils-r1 pypi
+
+DESCRIPTION="Python Rate-Limiter using Leaky-Bucket Algorimth Family"
+HOMEPAGE="
+ https://github.com/vutran1710/PyrateLimiter/
+ https://pypi.org/project/pyrate-limiter/
+"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="
+ dev-python/filelock[${PYTHON_USEDEP}]
+ dev-python/redis[${PYTHON_USEDEP}]
+"
+
+BDEPEND="
+ test? (
+ dev-db/redis
+ dev-python/pytest-asyncio[${PYTHON_USEDEP}]
+ dev-python/pytest-rerunfailures[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ )
+"
+
+EPYTEST_DESELECT=(
+ # Optional dependency redis-py-cluster not packaged
+ "tests/test_02.py::test_redis_cluster"
+)
+EPYTEST_XDIST=1
+
+distutils_enable_sphinx docs \
+ dev-python/sphinx-autodoc-typehints \
+ dev-python/sphinx-copybutton \
+ dev-python/furo \
+ dev-python/myst-parser \
+ dev-python/sphinxcontrib-apidoc
+distutils_enable_tests pytest
+
+src_test() {
+ local redis_pid="${T}"/redis.pid
+ local redis_port=6379
+
+ # Spawn Redis itself for testing purposes
+ einfo "Spawning Redis"
+ einfo "NOTE: Port ${redis_port} must be free"
+ "${EPREFIX}"/usr/sbin/redis-server - <<- EOF || die "Unable to start redis server"
+ daemonize yes
+ pidfile ${redis_pid}
+ port ${redis_port}
+ bind 127.0.0.1 ::1
+ ${extra_conf}
+ EOF
+
+ # Run the tests
+ distutils-r1_src_test
+
+ # Clean up afterwards
+ kill "$(<"${redis_pid}")" || die
+}
+
+python_test() {
+ local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
+ # postgres tests require psycopg-pool
+ epytest -p asyncio -p rerunfailures --reruns=5 -k "not postgres"
+}