From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 1D263158094 for ; Fri, 26 Aug 2022 11:38:23 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3AF9BE0976; Fri, 26 Aug 2022 11:38:22 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 043F7E0976 for ; Fri, 26 Aug 2022 11:38:22 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 268A734108D for ; Fri, 26 Aug 2022 11:38:21 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id A5F28596 for ; Fri, 26 Aug 2022 11:38:19 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1661513892.43e960831dcf4bd231453f9b223e5f03e321f861.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pytest-twisted/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/pytest-twisted/pytest-twisted-1.13.4-r1.ebuild dev-python/pytest-twisted/pytest-twisted-1.13.4.ebuild X-VCS-Directories: dev-python/pytest-twisted/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 43e960831dcf4bd231453f9b223e5f03e321f861 X-VCS-Branch: master Date: Fri, 26 Aug 2022 11:38:19 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: e1aed4ad-fad0-4c35-9c17-869eb3ff6bae X-Archives-Hash: e913382dfb0b43d7ac430712f74ef9e4 commit: 43e960831dcf4bd231453f9b223e5f03e321f861 Author: Sam James gentoo org> AuthorDate: Fri Aug 26 11:37:16 2022 +0000 Commit: Sam James gentoo org> CommitDate: Fri Aug 26 11:38:12 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=43e96083 dev-python/pytest-twisted: fix disabling autoload Need to do it in src_prepare before the wheel is created (the old hack doesn't work for PEP517 builds). With the fix (ignore lack of revision as did it after): ``` * CMP: =dev-python/pytest-twisted-1.13.4 with dev-python/pytest-twisted-1.13.4/image * FILES:-usr/lib/python3.10/site-packages/pytest_twisted-*.dist-info/entry_points.txt * FILES:-usr/lib/python3.11/site-packages/pytest_twisted-*.dist-info/entry_points.txt * FILES:-usr/lib/python3.8/site-packages/pytest_twisted-*.dist-info/entry_points.txt * FILES:-usr/lib/python3.9/site-packages/pytest_twisted-*.dist-info/entry_points.txt * SIZE: 0.28MiB -> 0.28MiB, 37 -> 33 files * ------> FILES(-4) SIZE(-0.22%) ``` Closes: https://bugs.gentoo.org/866677 Signed-off-by: Sam James gentoo.org> ...-1.13.4.ebuild => pytest-twisted-1.13.4-r1.ebuild} | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/dev-python/pytest-twisted/pytest-twisted-1.13.4.ebuild b/dev-python/pytest-twisted/pytest-twisted-1.13.4-r1.ebuild similarity index 93% rename from dev-python/pytest-twisted/pytest-twisted-1.13.4.ebuild rename to dev-python/pytest-twisted/pytest-twisted-1.13.4-r1.ebuild index 9f14cee4b540..c855d5fd9c88 100644 --- a/dev-python/pytest-twisted/pytest-twisted-1.13.4.ebuild +++ b/dev-python/pytest-twisted/pytest-twisted-1.13.4-r1.ebuild @@ -25,6 +25,12 @@ RDEPEND=" distutils_enable_tests pytest src_prepare() { + # If we let pytest-twisted autoload everywhere, it breaks tests in + # packages that don't expect it. Apply a similar hack as for bug + # #661218. We can't do this in src_prepare() because the tests need + # autoloading enabled. + sed -e 's/"pytest11": \[[^]]*\]//' -i setup.py || die + # https://github.com/pytest-dev/pytest/issues/9280 sed -e '/^pytest_plugins =/d' -i testing/conftest.py || die @@ -32,15 +38,8 @@ src_prepare() { } python_test() { - epytest -p pytester -} + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + local -x PYTEST_PLUGINS=pytest_twisted -src_install() { - # If we let pytest-twisted autoload everywhere, it breaks tests in - # packages that don't expect it. Apply a similar hack as for bug - # #661218. We can't do this in src_prepare() because the tests need - # autoloading enabled. - sed -e 's/"pytest11": \[[^]]*\]//' -i setup.py || die - - distutils-r1_src_install + epytest -p pytester }