diff options
Diffstat (limited to 'dev-python')
25 files changed, 431 insertions, 15 deletions
diff --git a/dev-python/Manifest.gz b/dev-python/Manifest.gz Binary files differindex aaf013aa7c54..2ce69cc76063 100644 --- a/dev-python/Manifest.gz +++ b/dev-python/Manifest.gz diff --git a/dev-python/asyncstdlib/Manifest b/dev-python/asyncstdlib/Manifest index d1633b22c155..b73b3c832818 100644 --- a/dev-python/asyncstdlib/Manifest +++ b/dev-python/asyncstdlib/Manifest @@ -1,3 +1,5 @@ DIST asyncstdlib-3.10.9.tar.gz 43799 BLAKE2B f6812fa8bf84913c122d881e70945c68a7b0680dcd3db944c429ef050952c8c78c6858bec2075668445bfd0f81dbb5215d50a82bf563ab2bbcbff60d0d66c17f SHA512 f0f80d6c63e20790a74142c8438937f1f79314675ff2da3ea3776a33b867e2705ffcf7605726afe35bb1b96dc3a8b0a86a292d26c01ee727425938eda57e3915 +DIST asyncstdlib-3.12.0.tar.gz 44339 BLAKE2B ed96b676d6136de510f8e6223096120da946788264d0cdfde77edbbd63b1a56fc6f38c7bd998dd3f3b4659264852d14f4ec613f4007dd5931f2674f6746ca5cc SHA512 07c1683cbc9421790d27c0e694cb3a6a544236aaf62a3300cc886f6bae7c7e9525c9d2a92add9aaa72fd17604c8de41750f11236b3a7497130a12613658cec90 EBUILD asyncstdlib-3.10.9.ebuild 420 BLAKE2B 8b713b185d9a2878036032c0d6d294df59c019433606c4e782866e05515f4da3cfc811c7d1a7c62410bb3a8610814f00b5c72721f12b9971c72d4e54f385bf0f SHA512 c1415364528242cecf6e2249590c5c7a067b25a43441b46658ddb402db2f124e1014be31dca2a74eb5ecbade3028407018cb2873a0dc1db2eda6007ec4240e28 +EBUILD asyncstdlib-3.12.0.ebuild 420 BLAKE2B 019a316d86071a3639bf39dae38ba3a980e8b6f34601a49da7e255c7f946819f772f27359d3d61be0f518f77abc05170722441c46210e64219dd095ad6ba0a47 SHA512 87d154b213ab06ba3eb4bc9a38d4b6231c0d2b47b3b326491720ab54a188c0f9e4ea7c7d229dfe209526cf7bea4b05d0721238337f89b8ad5fb68a4f855a40e0 MISC metadata.xml 359 BLAKE2B 10bdbf5adba9cefa912d8e1f195f20d4040bc2e8e3efb3fdc6efcb8272bb58160c6d772de3fe9ad9c4cb43e2817139319ffece082c3c043f1d97cb36ed8ac7a8 SHA512 e56f712f7446a3e68137a945a1ab212f6254740ce2f962fc7ab0061f41cb0d314809ad4fe3317fd10d8ebb594fb20d690d06b0a73636b13b5fdb5184cde2e306 diff --git a/dev-python/asyncstdlib/asyncstdlib-3.12.0.ebuild b/dev-python/asyncstdlib/asyncstdlib-3.12.0.ebuild new file mode 100644 index 000000000000..4e6fb6ccdf12 --- /dev/null +++ b/dev-python/asyncstdlib/asyncstdlib-3.12.0.ebuild @@ -0,0 +1,21 @@ +# Copyright 2021-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=flit +PYTHON_COMPAT=( python3_{10..12} ) + +inherit distutils-r1 pypi + +DESCRIPTION="The missing async toolbox" +HOMEPAGE=" + https://github.com/maxfischer2781/asyncstdlib/ + https://pypi.org/project/asyncstdlib/ +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +distutils_enable_tests pytest diff --git a/dev-python/flake8/Manifest b/dev-python/flake8/Manifest index 727632232230..96bb2615f005 100644 --- a/dev-python/flake8/Manifest +++ b/dev-python/flake8/Manifest @@ -1,3 +1,5 @@ DIST flake8-6.1.0.gh.tar.gz 139267 BLAKE2B 69210f4ebe5dd4b56425fca9289349820cc5dcee515f75cb855b095dc1a0a6ba380448f14fca19423940d853383576ddc665c5a7bd27f8aa96940ac410d8742b SHA512 a44d245b023acbb89e64071f6cb76f5543e538472a8815fa329a3b3671133cc6f96f246d83877a2a9ac91c32ecdf65858f8edf996efba77906af74b1632b74c8 +DIST flake8-7.0.0.gh.tar.gz 138456 BLAKE2B faf0b54ede3c3184e12986fb9247f73a149a5fd9ebba90578aae8550d2749bcacdab1fa4699ea0b8d69309d0bd5c26dd5162c54a8f8eb33ed64009c919e147fe SHA512 cebcd61d266c6d2f837178d0708217b471662e81dabaa911850883657307747180173c5f6cde11abc2b14381baecff9d6adeca2979bcb85be03a4a6ff57de2c4 EBUILD flake8-6.1.0.ebuild 1623 BLAKE2B 15b8af981c1f96e17edff272ae97aeb382c9359088c82142f3edbac78a6fb9466e86e90b1b2b32bd55400a5bca3c70e73649878f09fff511c551f63a661b9171 SHA512 3e7713502ca13cf0b28ac9ec49d07baca4daffbdced406fa896f5d5960d346348b0393097b5cc7017a6cc7765243cb2a1a7100c87bbfb68625a316c5eed523a5 +EBUILD flake8-7.0.0.ebuild 1631 BLAKE2B c26f4e2c083ea72fd5603bd9df6175f35dd3c7160dd8353095dc106c8968187e6bcd7f105eb214f56c9bd4988e3bf59388eddcd0112f50e24bceafde931bc44c SHA512 ce61c66f159901ce38ff48840c41be17527bfa7cf06b1a48edd928a25af164df9deba6506b371cfa5fe8a906a9ef3112d8802349252767f4b14162d0948072ea MISC metadata.xml 399 BLAKE2B 01ae165c898af67195582e1aaf867b9f9fc937e56b87f09a812d21c9d1175131c25561524ba76857c1630a117a21bc43eeef907c2a34ab9e9b38866dc2f9430e SHA512 8f149a017f4fef8f8fe0fef037e589694e0c3b3689990f97f38ed23fb9b5c5170985fc1fd7814ef70b8200db66cb9367dcfc9bf6453f8742092335a1c3c8fae6 diff --git a/dev-python/flake8/flake8-7.0.0.ebuild b/dev-python/flake8/flake8-7.0.0.ebuild new file mode 100644 index 000000000000..7fdd6be6d8d4 --- /dev/null +++ b/dev-python/flake8/flake8-7.0.0.ebuild @@ -0,0 +1,63 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( pypy3 python3_{10..12} ) + +inherit distutils-r1 + +DESCRIPTION="A wrapper around PyFlakes, pep8 & mccabe" +HOMEPAGE=" + https://github.com/PyCQA/flake8/ + https://pypi.org/project/flake8/ +" +SRC_URI=" + https://github.com/PyCQA/flake8/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" + +RDEPEND=" + <dev-python/pyflakes-3.3.0[${PYTHON_USEDEP}] + >=dev-python/pyflakes-3.2.0[${PYTHON_USEDEP}] + <dev-python/pycodestyle-2.12.0[${PYTHON_USEDEP}] + >=dev-python/pycodestyle-2.11.0[${PYTHON_USEDEP}] +" +PDEPEND=" + >=dev-python/mccabe-0.7.0[${PYTHON_USEDEP}] + <dev-python/mccabe-0.8.0[${PYTHON_USEDEP}] +" +BDEPEND=" + ${RDEPEND} + test? ( + ${PDEPEND} + ) +" + +distutils_enable_sphinx docs/source \ + dev-python/sphinx-prompt \ + dev-python/sphinx-rtd-theme +distutils_enable_tests pytest + +python_test() { + local EPYTEST_DESELECT=( + # fails if additional flake8 plugins are installed + tests/integration/test_plugins.py::test_local_plugin_can_add_option + ) + if [[ ${EPYTHON} == pypy3 ]]; then + EPYTEST_DESELECT+=( + # problem with pypy3.10 in dev-python/pyflakes + # https://github.com/PyCQA/pyflakes/issues/779 + tests/integration/test_main.py::test_malformed_per_file_ignores_error + tests/integration/test_main.py::test_tokenization_error_but_not_syntax_error + tests/integration/test_main.py::test_tokenization_error_is_a_syntax_error + ) + fi + + epytest +} diff --git a/dev-python/mkdocs-monorepo-plugin/Manifest b/dev-python/mkdocs-monorepo-plugin/Manifest index 6c1e5b2c0993..1311c7f93c76 100644 --- a/dev-python/mkdocs-monorepo-plugin/Manifest +++ b/dev-python/mkdocs-monorepo-plugin/Manifest @@ -1,3 +1,5 @@ DIST mkdocs-monorepo-plugin-1.0.5.tar.gz 9510 BLAKE2B 96b63fabe344f99aaefd0d3d0f547f0695fcee5b7f6d5ce027fc52ef27c1a70353c3835d0a0d02c753c48a67123bc6776a8060fa0a07640ca26f008df8f3611d SHA512 ed3c011d9a7b5a32868a4a16cbdfa1fd4ce036da2d73d59645aa5f42895f12ce7fe6d1681b53d72248b09fbdb343b2cfad3846e7005dbc8977c7ae40b8e29b30 +DIST mkdocs-monorepo-plugin-1.1.0.tar.gz 13435 BLAKE2B 5e3b0af987f0125595c32e9a68fbc5d41936081fff17a69f381789df03870cfc7efcca768de4de5663998e5437d25d24b91ab60a32106e027c5c76204aaeeaaa SHA512 8820bea9dc7e8754832c85e8b8a5e369f5ab28d388d6386912b0903739dd8bafc7dfda59bf7e4b98938ac171c7d76c9bd2e836a9c0fd05f0a61e1787e959f5da EBUILD mkdocs-monorepo-plugin-1.0.5.ebuild 896 BLAKE2B e3dae37d5f3bc62a08e5702046b04ada9f26073928547c1a71623f0b895fc845a69444ce3ef6a0068ea41be3c1bf52885b6bf4f84272367b2b18befccbe486ab SHA512 f35d3c461b62125713153559f85f6919abac08ff0471e2ff0ab1f9a7b0a0c52605184cae3a3f657bc75d0aeb56b0352f5ffd556146cd8f97cfe8d3c43e256978 +EBUILD mkdocs-monorepo-plugin-1.1.0.ebuild 896 BLAKE2B b46aecbb949e713a6f6f897ca4c5a858ca44bd7201be106e84fedd4b50379d56b7bc2b63e50359910f63fbee8066bed1e80f1f8804e87ac2a70049bccecc709b SHA512 adf815cb9e84bbf792b7b7798ef4b673e6918b5145a3a9def0c210a86d14966291daff83f07f905eaccf69a35f9f668aaa9342f96fe6d27c1617869c07c91809 MISC metadata.xml 427 BLAKE2B 547ba024501ca9073fbd53d272f3fb1992ca0f0e3a9bf640d077125735f9792840b21b40165532976ec14a63d30722907c318008ea224f82a14dd4c2d32f0ca2 SHA512 663c49070591ec88eb0c530cd18a1c2b8a19ad44902d71251d147505658b6779e5c13507419c0a9688a8c454f2d3c58fa43e898f0a47abcbe715ca8c6285d3c7 diff --git a/dev-python/mkdocs-monorepo-plugin/mkdocs-monorepo-plugin-1.1.0.ebuild b/dev-python/mkdocs-monorepo-plugin/mkdocs-monorepo-plugin-1.1.0.ebuild new file mode 100644 index 000000000000..cd27da0f29df --- /dev/null +++ b/dev-python/mkdocs-monorepo-plugin/mkdocs-monorepo-plugin-1.1.0.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYPI_NO_NORMALIZE=1 +PYTHON_COMPAT=( python3_{10..12} pypy3 ) + +inherit distutils-r1 pypi + +DESCRIPTION="Build multiple documentation folders in a single Mkdocs" +HOMEPAGE=" + https://backstage.github.io/mkdocs-monorepo-plugin/ + https://pypi.org/project/mkdocs-monorepo-plugin/ +" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~riscv" + +RDEPEND=" + >=dev-python/mkdocs-1.0.4[${PYTHON_USEDEP}] + >=dev-python/python-slugify-4.0.1[${PYTHON_USEDEP}] +" + +# Data files required by this test are not included in PyPI tarballs, +# and upstream has not tagged any releases in their GitHub repository since 2019. +EPYTEST_DESELECT=( + mkdocs_monorepo_plugin/tests/test_plugin.py::TestMonorepoPlugin::test_plugin_on_config_with_nav +) + +distutils_enable_tests pytest diff --git a/dev-python/patsy/Manifest b/dev-python/patsy/Manifest index 1839df5f2182..4177a52143ee 100644 --- a/dev-python/patsy/Manifest +++ b/dev-python/patsy/Manifest @@ -1,5 +1,7 @@ DIST patsy-0.5.4.tar.gz 397809 BLAKE2B d10a4a155d3346b7a5968af914e68f1c2508208eda5658091b40c4df421c6b5566278bfe7db856793a477cb9c78ed7bc8aae4209dde7b476d0d8a19164602797 SHA512 4fa6b099a12464b1ad1685e0d9ca0e9640c059d5021631e6c52f4025ff100899824e722d9b12107c49dc987e8f3e377aeeb007889d8b35b3f1e4cdf5ca491d2f DIST patsy-0.5.5.tar.gz 398073 BLAKE2B 39f2f0d7d855fc3a4ae4a8930847c859aeacd74232fbc46c5455d10fe9cf0940ce5dea5322927df7b6aed61799e9ecbb6156cd2d142e0e965dc3b208896b1f7d SHA512 9df823094223e4929ece2d35696288cfb1ce0395cc3a322b88b582439dbe85ae69d81c876deef2cedebcd4763a57cc7289bdc74f77cb6a514d1f2c3a9332a7f4 +DIST patsy-0.5.6.tar.gz 398011 BLAKE2B c5fb15c57e270e3545cfdc8c13f8e745c94822be6684aa6703bdbc1da15ea63eb7a21d1e0bd1aaed2a4d919f4848fd9089dbcd3c304676e0a9512d13f94302bb SHA512 df73ddfa0e66088cb50133240e2d67e2a833d8f691e17b443cdc0661adf580eb8908b1e1082e8debd91439bbe7b990a9a455f16bd6773173c7e86273f2c1051b EBUILD patsy-0.5.4.ebuild 704 BLAKE2B 02c943ea179567c6bd727a975ab68969cab295862244ee32954a72f6e2d0beafeabd81040bc550ee7dc0ab1a0d8756f407025379c0a41497f41f250102851fab SHA512 99a0b3ae4e6599ccd4ebb8784a1bb5f7f0e9045202f8414308702b13c57de922cc92f370ebf5eed7300fb5f99b2f797c1f01633156a574b1e2c91a5a5a69c665 EBUILD patsy-0.5.5.ebuild 716 BLAKE2B e5b5a4407991b5c1e0ac0df42de59f49e4cc435c6de8765670c00650d98ba35fa929bbfaef761492fee4debacf725cd24d223cee3865afa45e2870064cf51536 SHA512 b2d927ae9b0430717e61779454d8b19a5f3518408338371e518a1fbd0638c342b792a598a2dd875e0a27aef6f6c00b669627f1d4e87abd9204f1fdea275be63c +EBUILD patsy-0.5.6.ebuild 716 BLAKE2B e5b5a4407991b5c1e0ac0df42de59f49e4cc435c6de8765670c00650d98ba35fa929bbfaef761492fee4debacf725cd24d223cee3865afa45e2870064cf51536 SHA512 b2d927ae9b0430717e61779454d8b19a5f3518408338371e518a1fbd0638c342b792a598a2dd875e0a27aef6f6c00b669627f1d4e87abd9204f1fdea275be63c MISC metadata.xml 732 BLAKE2B cf0e18d97605d69bae87a3553b89d551c03b908ec5a41da2ca11490cce6abd9aa6533d9155b7c19e3e12e5996aa8d5c3ea1f4cfb15e6c70916a4e2119fa54399 SHA512 f68d1e8645fee5af27d72062cc36b3700bff6c9f9eb6cb38a3b6c085211fb1b8502257d5d09edbd858e10ff4ef9f6661c577e336c3881e3c88e54d0db889a2b4 diff --git a/dev-python/patsy/patsy-0.5.6.ebuild b/dev-python/patsy/patsy-0.5.6.ebuild new file mode 100644 index 000000000000..bbe8e7904364 --- /dev/null +++ b/dev-python/patsy/patsy-0.5.6.ebuild @@ -0,0 +1,30 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( pypy3 python3_{10..12} ) + +inherit distutils-r1 pypi + +DESCRIPTION="Python module to describe statistical models and design matrices" +HOMEPAGE=" + https://patsy.readthedocs.io/en/latest/index.html + https://github.com/pydata/patsy/ + https://pypi.org/project/patsy/ +" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" + +RDEPEND=" + dev-python/numpy[${PYTHON_USEDEP}] + dev-python/six[${PYTHON_USEDEP}] + !hppa? ( + dev-python/scipy[${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest diff --git a/dev-python/pycryptodome/Manifest b/dev-python/pycryptodome/Manifest index 91aeb904bf00..eb218d73918a 100644 --- a/dev-python/pycryptodome/Manifest +++ b/dev-python/pycryptodome/Manifest @@ -1,4 +1,6 @@ AUX pycryptodome-3.10.1-system-libtomcrypt.patch 1729 BLAKE2B 57a2022ef17e0b86e98b085336f5ce815304e326a5a2bd5cc8ff5d33b6efba440505767517b79c2f0bba39ab33f04d7434a3f0ee529b880ff7552aee2805dab5 SHA512 d53677c0ad96f161f9aed14b8f353a8cc12c92f31de9733789f9c4151710376d33e974fd611b763de94c631796d7a57cd8787656e3c1e985696e20537b34760e +AUX pycryptodome-3.19.1-gcc14-configure.patch 1344 BLAKE2B 13a6aab0d5eea704b33b80858d5b0df6219e1faa7984dde2cc483ab536a765bc245db331bed3d50689dd7eac01b0a6f52d3658acf3972a03f4e567696a052b87 SHA512 f79ab3841468f1f5da1c65ae2f385dc8a52f79701a9457f392c51ae7e1b2771a17d67f25d76d913ff5caf5fe09d10c0bdef5be5ec30e6226cc09eb83220b926d DIST pycryptodome-3.19.1.gh.tar.gz 17158420 BLAKE2B 2180bb37e2295f0499c6d00237207513ad6c186ff8fd8fac466cc43efa9b068cf8a272b5ae30da08d37db88d354d41c0b426643743251ea8460abb6ff627e3be SHA512 103910b385578732e356145247d3c1a4a3b0fe8acf22ce91f1c1155500cce2342e5caa0dff0a30825b11d7a614853c2dcb8657628f4d65682f6e543adb4db240 +EBUILD pycryptodome-3.19.1-r1.ebuild 1432 BLAKE2B 8bf42ef6036d8d848092e9f6df4820b8efab316927c74c8e29862adbb73714cfec0d507dc10f16b75991d5f1773346f5acedcbe9a0565843cd1c0950e67fb948 SHA512 5d5673fc01d6514dd6403a4502f153f3ac8439437fbb6400f0eefbbaf0f815045f200e087623cf76d294bc98ffdad651541d79f6240080df48417f16d2c9c078 EBUILD pycryptodome-3.19.1.ebuild 1368 BLAKE2B 5eca123b120504866f88490be4a53f36bbd27ec4f40bff397bf0b89f92309cf62dd4e77e8b67a0db62fd2d6912f38733a8813832aba2f8c8465a26c26314ea8f SHA512 ba0b239319f25c26667d0fc51a600d716aa77d4519be17dc05a51b9adae759559f0a530f804d32f0d7a8bff1a500a88b9560d2857cec3bfad0e384efb3d9913a MISC metadata.xml 386 BLAKE2B 1ec04c0cb752414f063177e637f1fc3e3c401db0c1f245cb33a3690e25597098b25fb2cd5f3ab99838a8bf8339906e2b23e325af5c7248fd880563c872c6fb60 SHA512 f19e2537c5a985389182860eaa45ae68a37ef1167c4b76b452513987fae6fcfb3534d102a079a003770372bbdb4f1997460c982b355f76d09f2387996e18091b diff --git a/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch b/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch new file mode 100644 index 000000000000..ee87f615b814 --- /dev/null +++ b/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch @@ -0,0 +1,48 @@ +https://github.com/Legrandin/pycryptodome/issues/787 +https://github.com/Legrandin/pycryptodome/commit/b4083688fde0580de6c2a4d36d84da31a2549a2c + +From b4083688fde0580de6c2a4d36d84da31a2549a2c Mon Sep 17 00:00:00 2001 +From: Helder Eijs <helderijs@gmail.com> +Date: Fri, 29 Dec 2023 14:36:19 +0100 +Subject: [PATCH] Better autodetect of AES support, in case of aggressive + optimization + +--- a/compiler_opt.py ++++ b/compiler_opt.py +@@ -140,7 +140,7 @@ def compiler_has_intrin_h(): + { + int a, b[4]; + __cpuid(b, a); +- return 0; ++ return a; + } + """ + return test_compilation(source, msg="intrin.h header") +@@ -154,7 +154,7 @@ def compiler_has_cpuid_h(): + { + unsigned int eax, ebx, ecx, edx; + __get_cpuid(1, &eax, &ebx, &ecx, &edx); +- return 0; ++ return eax; + } + """ + return test_compilation(source, msg="cpuid.h header") +@@ -163,11 +163,16 @@ def compiler_has_cpuid_h(): + def compiler_supports_aesni(): + source = """ + #include <wmmintrin.h> ++ #include <string.h> + __m128i f(__m128i x, __m128i y) { + return _mm_aesenc_si128(x, y); + } + int main(void) { +- return 0; ++ int ret; ++ __m128i x = _mm_setzero_si128(); ++ x = f(x, x); ++ memcpy(&ret, &x, sizeof(ret)); ++ return ret; + } + """ + + diff --git a/dev-python/pycryptodome/pycryptodome-3.19.1-r1.ebuild b/dev-python/pycryptodome/pycryptodome-3.19.1-r1.ebuild new file mode 100644 index 000000000000..89a5edcca25b --- /dev/null +++ b/dev-python/pycryptodome/pycryptodome-3.19.1-r1.ebuild @@ -0,0 +1,61 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..12} pypy3 ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 + +DESCRIPTION="A self-contained cryptographic library for Python" +HOMEPAGE=" + https://www.pycryptodome.org/ + https://github.com/Legrandin/pycryptodome/ + https://pypi.org/project/pycryptodome/ +" +SRC_URI=" + https://github.com/Legrandin/pycryptodome/archive/v${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="BSD-2 Unlicense" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris" + +DEPEND=" + dev-libs/gmp:= + >=dev-libs/libtomcrypt-1.18.2-r1:= +" +BDEPEND=" + $(python_gen_cond_dep 'dev-python/cffi[${PYTHON_USEDEP}]' 'python*') +" +RDEPEND=" + ${DEPEND} + ${BDEPEND} +" + +PATCHES=( + "${FILESDIR}/pycryptodome-3.10.1-system-libtomcrypt.patch" + "${FILESDIR}/pycryptodome-3.19.1-gcc14-configure.patch" +) + +python_prepare_all() { + # make sure we're unbundling it correctly + rm -r src/libtom || die + + distutils-r1_python_prepare_all +} + +python_test() { + local -x PYTHONPATH=${S}/test_vectors:${PYTHONPATH} + "${EPYTHON}" - <<-EOF || die + import sys + from Crypto import SelfTest + SelfTest.run(verbosity=2, stream=sys.stdout) + EOF + + # TODO: run cmake tests from src/test? +} diff --git a/dev-python/pyflakes/Manifest b/dev-python/pyflakes/Manifest index bd84124528c3..6e239f352d4b 100644 --- a/dev-python/pyflakes/Manifest +++ b/dev-python/pyflakes/Manifest @@ -1,3 +1,5 @@ DIST pyflakes-3.1.0.tar.gz 63636 BLAKE2B 89e5fae6bba9efc820e348ddac37fd8590478c64363a5f295cc620ebbc7b51d4d51e0cff30b6a54ee573612e5309d7fff9462bc31c9e89c34cf7cdbecffabd30 SHA512 6277eaa82a3d94f8052b3da865cfcc8e99846738b5869fca1be92bb5b9a4db0088859d811da565200e640ad0555d46e0ebcaf831cd422b84304514592270b02e +DIST pyflakes-3.2.0.tar.gz 63788 BLAKE2B 12547bc1ef69d11efb86198c091072085df8a5435608aace18eab9da92b428980ad62fc4b7b6e182bee7963c511b637c17191db9138fc811256f553b902dbd66 SHA512 bd413b2ad80ae942bc13cef5ecb3a47b09abb0641fe468d427717b32895eb1702c9e8831867fbaa1de6fff71ab16bc3dae96f745bbc3e7d99de104a008f397ba EBUILD pyflakes-3.1.0.ebuild 957 BLAKE2B e7e4ad272e514d4ee5c95aa28c2447e34dd7f293b5593c47838eecbc4091353a54a1bf7759fae65d91972ea643004a23f16d5c4a4fda46713d16257e065ecfab SHA512 2915e2c33df051b73083e986df506c988db1fb19e265318b36a02a684927b700a8e9cfa52272ab189623121f865f653ba4bccee715b415e6065c7624a9d6a1f2 +EBUILD pyflakes-3.2.0.ebuild 965 BLAKE2B 817c77bf5e9a1b74a70cebd397f180fda723f5c6edb3d3f2bde837eae7cfad5e193aaa10ac2a3beb5e2446ece1c0f8f6f71dd5c378277361e700ec4801aa20f4 SHA512 7736f0cba16f052887e1417a7fb72d3c8f6bd8ed2e4ef971e5025961951743c80af444c8ad37f85e86f54c05adac1195480823d9a816a407a25994ca4729aef0 MISC metadata.xml 763 BLAKE2B e15bc4240e0cc54bd0d7ecca523bcc43c5ae6ebd4f195815f7b2c3494e0366f1cc6feadbc63fce82390ed414e8f52a7bdf15f5c56909ab39879814ff1b178558 SHA512 bb8e0b6f746c99e5185a8bca736f0af36068ae0de45d1bde9663f0e732770366ac20f2116ddd9d7a85239146cf5d7b8fbbfc5c225d7bca4650001f86468a0142 diff --git a/dev-python/pyflakes/pyflakes-3.2.0.ebuild b/dev-python/pyflakes/pyflakes-3.2.0.ebuild new file mode 100644 index 000000000000..65b5994d6679 --- /dev/null +++ b/dev-python/pyflakes/pyflakes-3.2.0.ebuild @@ -0,0 +1,36 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..12} pypy3 ) + +inherit distutils-r1 pypi + +DESCRIPTION="Passive checker for Python programs" +HOMEPAGE=" + https://github.com/PyCQA/pyflakes/ + https://pypi.org/project/pyflakes/ +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" + +distutils_enable_tests pytest + +python_test() { + local EPYTEST_DESELECT=() + if [[ ${EPYTHON} == pypy3 ]]; then + # regressions with pypy3.10 + # https://github.com/PyCQA/pyflakes/issues/779 + EPYTEST_DESELECT+=( + pyflakes/test/test_api.py::CheckTests::test_eofSyntaxError + pyflakes/test/test_api.py::CheckTests::test_misencodedFileUTF8 + pyflakes/test/test_api.py::CheckTests::test_multilineSyntaxError + ) + fi + + epytest +} diff --git a/dev-python/pyopengl/Manifest b/dev-python/pyopengl/Manifest index b6eb8f95a940..5370853acd27 100644 --- a/dev-python/pyopengl/Manifest +++ b/dev-python/pyopengl/Manifest @@ -1,5 +1,5 @@ AUX pyopengl-3.1.7-py312.patch 829 BLAKE2B a00bbf0bf0a2766ae798222a0b70ed86b1446171251b7c12e2690b8ba9a36f0b2303cabb0000d423753ab3c25215a474bf97d64cac68ba0900f7fbb3e7de6466 SHA512 366ae4070a9be37a8da960619d31a0f7a7d4915081d82d84b85904e52cf011114d804fe228c9794319e400f1ba75f9e1cc4e0be7fa2709de1c88824cc8f29ece AUX pyopengl-3.1.7-pypy3.patch 836 BLAKE2B 1ebae535d8ffc73b38c55d47ac43ca1345023af119b8622559af76edd5be3eafade93346abf4d8df282350835a0dd0580879c3cd5da32a60473acc041eac4cf0 SHA512 f45853577b05802152d5bb2019bc389c04b51de51d85275370754f4d5c76277d09ae33e158e194a6fb188d78fa72f87046cfef4be886942600311f94420c2a4b DIST PyOpenGL-3.1.7.tar.gz 1896446 BLAKE2B 3fd4c84bb59157b4a6ee09c2a5ecd0e4f548bf03a84d735acfd92453eafb92102677a2b9c98831a92be33e873630c815dee453745d630a4d6b044771a13c945c SHA512 add1b4d02e7297f00f82a9c9249d6665029073fe620a1650491af9102a76a16e9320b5f227275b0c273ff5a616c284fd9f25f0f425848676c37cab9f3c22ae2e -EBUILD pyopengl-3.1.7-r1.ebuild 1501 BLAKE2B 32de93ca71ad3d227b6f2b395936684588b479f714be5d35ee356fb4e8fdb2eedecdff49cdbaefaea959a5038775410001bc0102653e191be5fcdc78c498cb45 SHA512 73a77ffd9f04e76f5b38bdf66764e5a766342c9102c4de2325afdbbc6b45dfb08d65f0004675a360ff510932bd87ab068b2851d69f2df0214fd7400e59478d98 +EBUILD pyopengl-3.1.7-r1.ebuild 1560 BLAKE2B 963dc80e509bed57b61b46796625fecb17955914c2409ce44a0c9b80209723e45a691fed32be1a355f877e901f22033068478d51544bdb49c9db6745ea28d987 SHA512 9d8124f16b0e9d43b374e38cd8e1f3480a7207463fcd7808a44addff824e7bcdcf6b9b510dcdc3d12859abd7913958c5738dd2489552bc7648ee3a30514ec377 MISC metadata.xml 422 BLAKE2B c9ee324fb408e8d0856193fde1324109e77c97f28fff0dc83d9c903cf3e2385c3401d8f949d50fc2e2a9c41b79c421298e04fc79639b79352138f41aeafb7018 SHA512 bedbbc7fcafc2c625f79241e75faeafd0d3c37b4186b5ef8842e8612d9527a4991f208b1878b1f1e28f4056eab2104e7acb57814e39ee82c0208d6f93fbb7b85 diff --git a/dev-python/pyopengl/pyopengl-3.1.7-r1.ebuild b/dev-python/pyopengl/pyopengl-3.1.7-r1.ebuild index c062ef4860ca..7dd53e7e560f 100644 --- a/dev-python/pyopengl/pyopengl-3.1.7-r1.ebuild +++ b/dev-python/pyopengl/pyopengl-3.1.7-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -56,13 +56,14 @@ PATCHES=( "${FILESDIR}/${P}-pypy3.patch" ) -EPYTEST_DESELECT=( - # unreliable memory counting test - tests/test_vbo_memusage.py::test_sf_2980896 -) - python_test() { - nonfatal epytest || die "Tests failed with ${EPYTHON}" + local EPYTEST_DESELECT=( + # unreliable memory counting test + tests/test_vbo_memusage.py::test_sf_2980896 + ) + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + + nonfatal epytest tests || die "Tests failed with ${EPYTHON}" } src_test() { diff --git a/dev-python/pysol-cards/Manifest b/dev-python/pysol-cards/Manifest new file mode 100644 index 000000000000..298833c59672 --- /dev/null +++ b/dev-python/pysol-cards/Manifest @@ -0,0 +1,5 @@ +DIST pysol_cards-0.14.3.tar.gz 18322 BLAKE2B 730da3d597377305c86e528606edd3db9f07390d333283a228c2411d35f2e19da61d27f21e3d2650b84ba0f4b0d48e87cf7004d518845fe2a40b041e286d5a28 SHA512 00bb25393eab855d7444324b33e0561bfbcc86ae53306b58623fa15ea005378aff6af51846aab4634b43fdba5497c3872c32baf3a51013ee01d5ab2d7a7a9d51 +DIST pysol_cards-0.16.0.tar.gz 18987 BLAKE2B 5f4174462aaadd75b325a6c3e7e16bcc8e9694bb2e9a45eab3caa325959b1870531b71332728851bcbffba8f5a2022ae0a5b2fd81b75212a77e3fce8177d128f SHA512 728e76017cab27b5e67ed234951bff0608285caf1a79ab5f60a72d58530f4107fdb28749c4a2b4744830ecabaade1f413ad657149afa6aee8cb792b5dbcc8bce +EBUILD pysol-cards-0.14.3.ebuild 535 BLAKE2B 2a33ccf7f1d9f6a03d5ee26bddb17fc8f2247e7b48c99c4e14df19ba71cf3f1b36a745c772943f911ece5ee358ae41ce703e56cb4fe4855a9469858adc6c659b SHA512 02767095ee5360ed68caac030fae36cecdfb207e12f92a96e028aaf5ab4048bbc032140b29314695f659382a7b82fb4f884d019839eca5d9c3fd0ad25a01af80 +EBUILD pysol-cards-0.16.0.ebuild 538 BLAKE2B fe35acca668f17c6e906adf329e4d718a89e487089ed0841096c4637af13d7f589c7cfaee2404b5e7328f62f2c05143d8274e2d4f5caaf4aae0efaa9928cc548 SHA512 918feabb13cfbe78699c9287351c93bb5867b85a34fb357b98c7f6854ca4d5692773ee1676e812bc37737cf4e591dc451ecbab292e774d44889e4f070cfbe973 +MISC metadata.xml 474 BLAKE2B 47398a90962b1059e1d2725f7b20dbc10586cee53ab27eff6a9d0c8d93cde1b103580494a38aad77a3ae04c7f7a95bcbe52722ce18476a77994e49cb64076e58 SHA512 b8cba71875a546d130fbc94e3a76a3e0dd27552ce14de46a8b6bd79f12584b59ea8e9354fadd272c4e21ac9df7f43e9c1db9087338acfbed3dc680a6d812ffa6 diff --git a/dev-python/pysol_cards/metadata.xml b/dev-python/pysol-cards/metadata.xml index 474258121ee8..474258121ee8 100644 --- a/dev-python/pysol_cards/metadata.xml +++ b/dev-python/pysol-cards/metadata.xml diff --git a/dev-python/pysol_cards/pysol_cards-0.14.3.ebuild b/dev-python/pysol-cards/pysol-cards-0.14.3.ebuild index 03ff0f6e7ea2..fc9fbb72135f 100644 --- a/dev-python/pysol_cards/pysol_cards-0.14.3.ebuild +++ b/dev-python/pysol-cards/pysol-cards-0.14.3.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 diff --git a/dev-python/pysol-cards/pysol-cards-0.16.0.ebuild b/dev-python/pysol-cards/pysol-cards-0.16.0.ebuild new file mode 100644 index 000000000000..277d07d6becc --- /dev/null +++ b/dev-python/pysol-cards/pysol-cards-0.16.0.ebuild @@ -0,0 +1,26 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..12} ) + +inherit distutils-r1 pypi + +DESCRIPTION="Deal PySol FreeCell cards" +HOMEPAGE=" + https://github.com/shlomif/pysol_cards/ + https://pypi.org/project/pysol-cards/ +" + +LICENSE="Apache-2.0 MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~loong ~riscv ~x86" + +RDEPEND=" + dev-python/random2[${PYTHON_USEDEP}] + dev-python/six[${PYTHON_USEDEP}] +" + +distutils_enable_tests unittest diff --git a/dev-python/pysol_cards/Manifest b/dev-python/pysol_cards/Manifest deleted file mode 100644 index f54506afca64..000000000000 --- a/dev-python/pysol_cards/Manifest +++ /dev/null @@ -1,3 +0,0 @@ -DIST pysol_cards-0.14.3.tar.gz 18322 BLAKE2B 730da3d597377305c86e528606edd3db9f07390d333283a228c2411d35f2e19da61d27f21e3d2650b84ba0f4b0d48e87cf7004d518845fe2a40b041e286d5a28 SHA512 00bb25393eab855d7444324b33e0561bfbcc86ae53306b58623fa15ea005378aff6af51846aab4634b43fdba5497c3872c32baf3a51013ee01d5ab2d7a7a9d51 -EBUILD pysol_cards-0.14.3.ebuild 535 BLAKE2B a7a5ce715a798c0612c4c27245a5ce1f56c58d3a77df3d4f387083a9b21ad2f4bdf1aabae3117b63f4cf6e5020e0e3b5ab51dfa655583791f01f13acb0ff5aab SHA512 bf965660c089914bb3a763d61eb734a03db2a4eb2025dca1bc18023e2d0f883f9e945bbad2a9ae702f295b5333ef6eaade8f9ded7de2a1f9e76308a5e367e301 -MISC metadata.xml 474 BLAKE2B 47398a90962b1059e1d2725f7b20dbc10586cee53ab27eff6a9d0c8d93cde1b103580494a38aad77a3ae04c7f7a95bcbe52722ce18476a77994e49cb64076e58 SHA512 b8cba71875a546d130fbc94e3a76a3e0dd27552ce14de46a8b6bd79f12584b59ea8e9354fadd272c4e21ac9df7f43e9c1db9087338acfbed3dc680a6d812ffa6 diff --git a/dev-python/python-distutils-extra/Manifest b/dev-python/python-distutils-extra/Manifest index a4fcc03c4a21..c8e9d75334a6 100644 --- a/dev-python/python-distutils-extra/Manifest +++ b/dev-python/python-distutils-extra/Manifest @@ -1,3 +1,3 @@ DIST python-distutils-extra-2.47.tar.bz2 38346 BLAKE2B 2f9ad3c8c429570bd45c06af3eb2b12bf5f539c49e3b3a40c3558e67a4e4fc9f0bca0c4217bac6c8792e0514d75ac2b4b112dbeaffa96d626fffcc237860342d SHA512 b848b8ccfd84289e5482ba264a8d8d81cdbeba97358c9fff6fb02040eeb740bacfcc19b302e56a95b400528f7e03390ea4073b8c80d1e5a5e61e1b6c46b39648 -EBUILD python-distutils-extra-2.47.ebuild 960 BLAKE2B f2cbe3df689963a7b26912422171ab6776d1b81393080f0dd6f41df3770398064395e2d4498b5ff07220bf69f7484c4d2f1b6a3234dc381f5cda08540523146a SHA512 e16b5cc6ca5400fedd77aab404b24f469eb439b21d7bf9daded4a3ca1e63fb58b06906d554c452f701984e511c86e0cf0a4f09eb44d9cb8dc139889c3b919137 +EBUILD python-distutils-extra-2.47.ebuild 967 BLAKE2B a82d19219907ec7042fc89b80821ff4435c0a40b4b58a1493bab9efacf4a8b2e5cb2c324f58f32545174d8701f6e5413dc165761f1858f66f37f3d13405f9fe9 SHA512 8561dc13119a83764efca6d4c60e451d7fc65b0be1050febcdc2892893b129a3783464ec1cee7837203ef40bb9fc8f5657c96ddc53e86d0eb2e35c11f5afb873 MISC metadata.xml 340 BLAKE2B 21821b0f3d5483e62c4e84a0d98acb7a9984cc7a72d9c3fd140dd37fb2b93b724c8b92a80da9880d2cf314cb457f7f328efa5313fecc361dcebb1d4ea61ae504 SHA512 a7413179a36b347c297d304e24ea7ba9995fb8e66d2d0498923da83dde5e657855e6d875bc9f10b62f4c7342bf0e07a42bb0c1033d74b7a07422d29273c46857 diff --git a/dev-python/python-distutils-extra/python-distutils-extra-2.47.ebuild b/dev-python/python-distutils-extra/python-distutils-extra-2.47.ebuild index 3a6c802e0da9..862e56984b62 100644 --- a/dev-python/python-distutils-extra/python-distutils-extra-2.47.ebuild +++ b/dev-python/python-distutils-extra/python-distutils-extra-2.47.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -19,7 +19,7 @@ SRC_URI=" LICENSE="GPL-2+" SLOT="0" -KEYWORDS="amd64 ~arm arm64 ~loong ppc x86" +KEYWORDS="amd64 ~arm arm64 ~loong ppc ~riscv x86" IUSE="test" RESTRICT="!test? ( test )" diff --git a/dev-python/stripe/Manifest b/dev-python/stripe/Manifest index 59a718aa6061..c6c5fbb78db0 100644 --- a/dev-python/stripe/Manifest +++ b/dev-python/stripe/Manifest @@ -1,5 +1,7 @@ DIST stripe-7.10.0.tar.gz 783205 BLAKE2B ab06c4f81bd3f2492a1e5982995f5205f345f395b8cc7e470a22af62d57421789208c76097a08019550a61ab65b41ea24305bd303a9e3d6e3cb791fe552bcbc7 SHA512 dbdfd2ca11f592caa31fb53b0204e64292d4471d5d3e607447bbcfabe24db684331d77f0ff12da77ec5c4ad20709328a7366eb55b9c3d804ca39442971cefcde +DIST stripe-7.11.0.tar.gz 783456 BLAKE2B 9317526b9c19d98b921f3fa8222486537b3bfa3a9c239d83098be1d9856a258a67276690c1f1ced6087a8d7f1fb180240f737d67f9ded5605e82de7fc4355fc0 SHA512 5cfa650d43745c8a3ab5588f30c6eaab0952aff060b9fdb84027db3422c88002d074eb29b3e2a40ed1457be6e8cd883b3323e8da538af0991114a10976b86842 DIST stripe-7.9.0.tar.gz 772219 BLAKE2B d119308b12589c4de1f54705f80ae627bd7ca26b565f42bfb4569db42183f20c29086933becdaee65177f01fbcf0481a4b9ec0119ef984b471d083600d75b362 SHA512 6d73ef7e2a366634dd5736733d9b798e9df103a9d25a361f649c5d97924fc7d65efd80f2d471b47dfccbc8080a87a18a96c3f40258ca0a9aef7d1b21f7919bb5 EBUILD stripe-7.10.0.ebuild 2142 BLAKE2B f8a043887b514a6cb95de4e19509ee5bfa8ddf5b95354e0f65b206a43d701c38ef1f236480e927abc9081598495dc306631714c75d7a12b3da99ad7c1620a828 SHA512 8b718b0cee64bbbd49c324821423b4d343d48e92c8a2c011ec9744279e5b5a0a55ff558c48ad18f76d1f5780c60aa1471db3d862dad074572f8f959f9d5f52fc +EBUILD stripe-7.11.0.ebuild 2142 BLAKE2B c24257d04dba834019b94e0128f08d446f6953dfa87faf7b9fb79c14eadf2a525333a8ee9fec920637b899c4b467244978ac1677b01af79b68c975ba8adf81b0 SHA512 fd89abedaec2309bd6186ead14456c119e9ae9ab942feca5c9f85fb3ff6429cb0c38b52f0a406ed3994d34166cf2c848f37a9353546e3137fc0db7b3f15f2be5 EBUILD stripe-7.9.0.ebuild 2139 BLAKE2B 2c6f3765f6309ffbccf97ff2f8383cbd527ddc0e6c358343832a482381db34f2a87ce5966365dda88c2358383624703d9a690f94c721f4217ed2e752b1c6b7d0 SHA512 ab8682ba92a39235b7c4daa5377cf1ba5a096951c0c4e020e17645e4fc67f6f3898a64908a0163eca99f23d48fde69f5aee09f8a4a6347f65df5e6a887fb381a MISC metadata.xml 673 BLAKE2B 6b85b1f88713d2365274fcff21648748039b48028b3c34c1192e16ca12d0f3b4d14ab13c7c2a744c381898ea0c1304bda8be52d3fadddc1a1b787f010b001398 SHA512 e3178927a69d14f59673acc5eaedda59db5a07e2145ed6fb0597363b60183cb3e7a7b0feefc1d4c9095d52ed96e0be32ef5dc23ad0c20fd6e6b33c830177c0be diff --git a/dev-python/stripe/stripe-7.11.0.ebuild b/dev-python/stripe/stripe-7.11.0.ebuild new file mode 100644 index 000000000000..59f175a1076a --- /dev/null +++ b/dev-python/stripe/stripe-7.11.0.ebuild @@ -0,0 +1,81 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..12} pypy3 ) + +inherit distutils-r1 pypi + +DESCRIPTION="Stripe python bindings" +HOMEPAGE=" + https://github.com/stripe/stripe-python/ + https://pypi.org/project/stripe/ +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="telemetry" + +RDEPEND=" + >=dev-python/requests-2.20[${PYTHON_USEDEP}] + >=dev-python/typing-extensions-4.5.0[${PYTHON_USEDEP}] +" +# please bump dev-util/stripe-mock dep to the latest version on every bump +BDEPEND=" + test? ( + >=dev-util/stripe-mock-0.179.0 + dev-python/pytest-mock[${PYTHON_USEDEP}] + net-misc/curl + ) +" + +distutils_enable_tests pytest + +DOCS=( LONG_DESCRIPTION.rst CHANGELOG.md README.md ) + +src_prepare() { + if ! use telemetry; then + sed -i -e '/enable_telemetry/s:True:False:' stripe/__init__.py || die + fi + distutils-r1_src_prepare +} + +python_test() { + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + epytest tests -p pytest_mock +} + +src_test() { + local stripe_mock_port=12111 + local stripe_mock_max_port=12121 + local stripe_mock_logfile="${T}/stripe_mock_${EPYTHON}.log" + # Try to start stripe-mock until we find a free port + while [[ ${stripe_mock_port} -le ${stripe_mock_max_port} ]]; do + ebegin "Trying to start stripe-mock on port ${stripe_mock_port}" + stripe-mock --http-port "${stripe_mock_port}" &> "${stripe_mock_logfile}" & + local stripe_mock_pid=${!} + sleep 2 + # Did stripe-mock start? + curl --fail -u "sk_test_123:" \ + "http://127.0.0.1:${stripe_mock_port}/v1/customers" &> /dev/null + eend ${?} "Port ${stripe_mock_port} unavailable" + if [[ ${?} -eq 0 ]]; then + einfo "stripe-mock running on port ${stripe_mock_port}" + break + fi + (( stripe_mock_port++ )) + done + if [[ ${stripe_mock_port} -gt ${stripe_mock_max_port} ]]; then + eerror "Unable to start stripe-mock for tests" + die "Please see the logfile located at: ${stripe_mock_logfile}" + fi + + local -x STRIPE_MOCK_PORT=${stripe_mock_port} + distutils-r1_src_test + + # Tear down stripe-mock + kill "${stripe_mock_pid}" || die "Unable to stop stripe-mock" +} |