From b12cfe25d7e2db1389500d7bf397d17adbcad5d9 Mon Sep 17 00:00:00 2001 From: YiFei Zhu Date: Fri, 3 Jan 2025 04:45:10 -0800 Subject: [PATCH] dev-python/guppy3: add 3.1.5, drop 3.1.3-r1 Signed-off-by: YiFei Zhu --- dev-python/guppy3/Manifest | 2 +- .../guppy3-3.1.3-py311-refcount-assert.patch | 44 ------------------- ...y3-3.1.3-r1.ebuild => guppy3-3.1.5.ebuild} | 8 +--- 3 files changed, 3 insertions(+), 51 deletions(-) delete mode 100644 dev-python/guppy3/files/guppy3-3.1.3-py311-refcount-assert.patch rename dev-python/guppy3/{guppy3-3.1.3-r1.ebuild => guppy3-3.1.5.ebuild} (76%) diff --git a/dev-python/guppy3/Manifest b/dev-python/guppy3/Manifest index 9cc3512a93..eee4aebc71 100644 --- a/dev-python/guppy3/Manifest +++ b/dev-python/guppy3/Manifest @@ -1,2 +1,2 @@ -DIST guppy3-3.1.3.tar.gz 343281 BLAKE2B cbc17a26dff0c9f217843575054aed4925461e3525f1f3785aa535fc125d7455b155dc69755edce9b7b6b43e04b18b685051644dee12935a8af8bba384da0e0d SHA512 f35219ecea5fa20edf3f064109b16ea3b022fea666415751000329fb35726759a697b79efe6a93c29d1a422a57c6dbb881bb313e267a569b621fef6cb0971c68 DIST guppy3-3.1.4.tar.gz 344051 BLAKE2B 1578ad1d467e3492e6d6ce4142b18670e7e4357c4ca24237b41b478069504a48ff36c9c14af67c8164396a7b2797c0d14d9884de9e251f00fc89e3f2b14e572b SHA512 6f551989ab296d974cf372c8ccfdc7768e17eed35d25e4b14e95a66c35d2ecb6813bad1158ad0b005c730216d33b87d71833cfa9048d9f349851444f39782b9c +DIST guppy3-3.1.5.tar.gz 334938 BLAKE2B 0d5f4fcd2a0d95cf1db7c7d389d5c3ad3fc2513416b6c20c8571a3a72965280ccdc3117992d7b4aaa71b4e360c10c07452a28ed7106bc20394dc7b60c9f8c59f SHA512 1baf2be2b94c37a4021197c3627b3fb30b525b93fe016adefc872a984738832d2bdad8efc3174f7bc94b7a06b670d195bfd053c5dd1b48c5a60086ba9aeb2932 diff --git a/dev-python/guppy3/files/guppy3-3.1.3-py311-refcount-assert.patch b/dev-python/guppy3/files/guppy3-3.1.3-py311-refcount-assert.patch deleted file mode 100644 index 8a8840d553..0000000000 --- a/dev-python/guppy3/files/guppy3-3.1.3-py311-refcount-assert.patch +++ /dev/null @@ -1,44 +0,0 @@ -From 71f3455f73eedef78ccf79c17ed5adbb36d11eeb Mon Sep 17 00:00:00 2001 -From: YiFei Zhu -Date: Mon, 22 May 2023 15:54:24 -0700 -Subject: [PATCH] nodegraph: Fix refcount sanity assertion for Python 3.11 - -Python 3.11 created immortal objects whose initial refcount is -999999999, larger than 0xa000000. This breaks the assertin here. - -Caught by https://bugs.gentoo.org/906937 - -Fortunately I don't seem to need to do a new release with this fix -because the wheels are built with -DNDEBUG. ---- - src/heapy/nodegraph.c | 14 ++++++++++++-- - 1 file changed, 12 insertions(+), 2 deletions(-) - -diff --git a/src/heapy/nodegraph.c b/src/heapy/nodegraph.c -index 2fd9c83..765f5ee 100644 ---- a/src/heapy/nodegraph.c -+++ b/src/heapy/nodegraph.c -@@ -148,8 +148,18 @@ NyNodeGraph_AddEdge(NyNodeGraphObject *ng, PyObject *src, PyObject *tgt) - ng->edges[ng->used_size-1].tgt == tgt) - return 0; - -- assert(Py_REFCNT(src) < 0xa000000 && (Py_uintptr_t)Py_TYPE(src) > 0x1000); -- assert(Py_REFCNT(tgt) < 0xa000000 && (Py_uintptr_t)Py_TYPE(tgt) > 0x1000); -+#if PY_MAJOR_VERSION >= 3 && PY_MINOR_VERSION >= 11 -+ /* Py >= 3.11 _PyObject_IMMORTAL_INIT sets initial refcount of 999999999 */ -+ assert((Py_uintptr_t)Py_TYPE(src) > 0x1000 && -+ (Py_REFCNT(src) < 0xa000000 || -+ (Py_REFCNT(src) >= 999999999 && Py_REFCNT(src) < 999999999 + 0xa000000))); -+ assert((Py_uintptr_t)Py_TYPE(tgt) > 0x1000 && -+ (Py_REFCNT(tgt) < 0xa000000 || -+ (Py_REFCNT(tgt) >= 999999999 && Py_REFCNT(tgt) < 999999999 + 0xa000000))); -+#else -+ assert((Py_uintptr_t)Py_TYPE(src) > 0x1000 && Py_REFCNT(src) < 0xa000000); -+ assert((Py_uintptr_t)Py_TYPE(tgt) > 0x1000 && Py_REFCNT(tgt) < 0xa000000); -+#endif - - if (ng->used_size >= ng->allo_size) { - Py_ssize_t allo = roundupsize(ng->used_size + 1); --- -2.40.1 - diff --git a/dev-python/guppy3/guppy3-3.1.3-r1.ebuild b/dev-python/guppy3/guppy3-3.1.5.ebuild similarity index 76% rename from dev-python/guppy3/guppy3-3.1.3-r1.ebuild rename to dev-python/guppy3/guppy3-3.1.5.ebuild index 6167d85612..94b05f53a4 100644 --- a/dev-python/guppy3/guppy3-3.1.3-r1.ebuild +++ b/dev-python/guppy3/guppy3-3.1.5.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 -PYTHON_COMPAT=( python3_{10..12} ) +PYTHON_COMPAT=( python3_{10..13} ) DISTUTILS_USE_PEP517=setuptools DISTUTILS_EXT=1 inherit distutils-r1 pypi @@ -18,10 +18,6 @@ LICENSE="MIT" SLOT="0" KEYWORDS="~amd64 ~x86" -PATCHES=( - "${FILESDIR}"/guppy3-3.1.3-py311-refcount-assert.patch -) - python_test() { cd "${T}" || die "${EPYTHON}" "${S}"/guppy/heapy/test/test_all.py || die