From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (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 finch.gentoo.org (Postfix) with ESMTPS id 7E55E15808A for ; Fri, 18 Jul 2025 10:38:46 +0000 (UTC) Received: from lists.gentoo.org (bobolink.gentoo.org [140.211.166.189]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (No client certificate requested) (Authenticated sender: relay-lists.gentoo.org@gentoo.org) by smtp.gentoo.org (Postfix) with ESMTPSA id 64B0A335D9A for ; Fri, 18 Jul 2025 10:38:46 +0000 (UTC) Received: from bobolink.gentoo.org (localhost [127.0.0.1]) by bobolink.gentoo.org (Postfix) with ESMTP id 65687110280; Fri, 18 Jul 2025 10:38:45 +0000 (UTC) Received: from smtp.gentoo.org (smtp.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) (No client certificate requested) by bobolink.gentoo.org (Postfix) with ESMTPS id 59A50110280 for ; Fri, 18 Jul 2025 10:38:45 +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) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 0B33F335D9A for ; Fri, 18 Jul 2025 10:38:45 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 4877631CF for ; Fri, 18 Jul 2025 10:38:43 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1752834748.948ad8798c761c2f962d0042b1170cd972ee45ff.mgorny@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/distlib/files/, dev-python/distlib/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/distlib/Manifest dev-python/distlib/distlib-0.4.0.ebuild dev-python/distlib/files/distlib-0.4.0-py314-test.patch X-VCS-Directories: dev-python/distlib/files/ dev-python/distlib/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 948ad8798c761c2f962d0042b1170cd972ee45ff X-VCS-Branch: master Date: Fri, 18 Jul 2025 10:38:43 +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: 986dda67-83cd-44ec-9403-3af9259c871c X-Archives-Hash: e978f47521d2ba3fe0225db1bd466238 commit: 948ad8798c761c2f962d0042b1170cd972ee45ff Author: Michał Górny gentoo org> AuthorDate: Fri Jul 18 10:32:28 2025 +0000 Commit: Michał Górny gentoo org> CommitDate: Fri Jul 18 10:32:28 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=948ad879 dev-python/distlib: Bump to 0.4.0 Signed-off-by: Michał Górny gentoo.org> dev-python/distlib/Manifest | 1 + dev-python/distlib/distlib-0.4.0.ebuild | 58 ++++++++++++++++++++++ .../distlib/files/distlib-0.4.0-py314-test.patch | 28 +++++++++++ 3 files changed, 87 insertions(+) diff --git a/dev-python/distlib/Manifest b/dev-python/distlib/Manifest index 897a980c56b5..a1ccbd459239 100644 --- a/dev-python/distlib/Manifest +++ b/dev-python/distlib/Manifest @@ -1 +1,2 @@ DIST distlib-0.3.9.gh.tar.gz 1244538 BLAKE2B 08f5257f5a1125c1c76a23b9a78ded6a08f26d2f1491be9b104ab1e02a9737ae49f3750a607d3c7c744397879aeb3cd1a94a355743c95c702eec8a3cfebd70cb SHA512 d89b3ae450a02f634db10baef8d2ff445afa99cd69377f40ef07d591b4bbb2e24fff43c92eeeb93628eaee292fa1e8324eb1a842cf9401feb1f309dbb6f20a25 +DIST distlib-0.4.0.gh.tar.gz 1245571 BLAKE2B c36fe726918bc04849465a55a2708b8686d2ba0b05baa7ff0595e03b7ff95a1afc45b037dbeab9bd14ec7a26ec49807ea5a7c458d8f8da16038c92f32291c62e SHA512 ff61f9ab4e38061d5fee3168c8b26c741a21403d793476477e0733b28b2ba5b1fb31ae6ddb5275efe7ad6936b7e79a5e7ec1b160c86bfbfe6b4ecff10e0193d2 diff --git a/dev-python/distlib/distlib-0.4.0.ebuild b/dev-python/distlib/distlib-0.4.0.ebuild new file mode 100644 index 000000000000..16f1bea342b3 --- /dev/null +++ b/dev-python/distlib/distlib-0.4.0.ebuild @@ -0,0 +1,58 @@ +# Copyright 2021-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{11..14} python3_{13,14}t pypy3_11 ) + +inherit distutils-r1 + +DESCRIPTION="Low-level components of distutils2/packaging" +HOMEPAGE=" + https://pypi.org/project/distlib/ + https://github.com/pypa/distlib/ +" +SRC_URI=" + https://github.com/pypa/distlib/archive/${PV}.tar.gz -> ${P}.gh.tar.gz +" + +LICENSE="PSF-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" +IUSE="test" +RESTRICT="!test? ( test )" + +# pypiserver is called as external executable +BDEPEND=" + test? ( + dev-python/pypiserver + ) +" + +src_prepare() { + local PATCHES=( + # use system pypiserver instead of bundled one + "${FILESDIR}/distlib-0.3.9-system-pypiserver.py" + # https://github.com/pypa/distlib/commit/6286442857de9f734686d08f0e59ca8048ee357a + "${FILESDIR}/${P}-py314-test.patch" + ) + + # make sure it's not used + rm tests/pypi-server-standalone.py || die + + distutils-r1_src_prepare +} + +python_test() { + local -x SKIP_ONLINE=1 + local -x PYTHONHASHSEED=0 + + # disable system-site-packages -- distlib has no deps, and is very + # fragile to packages actually installed on the system + sed -i -e '/system-site-packages/s:true:false:' \ + "${BUILD_DIR}/install${EPREFIX}/usr/pyvenv.cfg" || die + + "${EPYTHON}" tests/test_all.py -v -x || + die "Tests failed with ${EPYTHON}" +} diff --git a/dev-python/distlib/files/distlib-0.4.0-py314-test.patch b/dev-python/distlib/files/distlib-0.4.0-py314-test.patch new file mode 100644 index 000000000000..cf08838092a4 --- /dev/null +++ b/dev-python/distlib/files/distlib-0.4.0-py314-test.patch @@ -0,0 +1,28 @@ +From 6286442857de9f734686d08f0e59ca8048ee357a Mon Sep 17 00:00:00 2001 +From: Vinay Sajip +Date: Fri, 18 Jul 2025 07:59:29 +0100 +Subject: [PATCH] Fix #251: Use more appropriate function in test. + +--- a/tests/test_scripts.py ++++ b/tests/test_scripts.py +@@ -341,10 +341,8 @@ def test_dry_run(self): + def test_script_run(self): + if sys.version_info[:2] < (3, 13): + target = 'cgi:print_directory' +- elif os.name != 'nt': +- target = 'test.support.interpreters:list_all' + else: +- raise unittest.SkipTest('test not available on Windows for Python >= 3.13') ++ target = 'logging:getHandlerNames' + files = self.maker.make('test = %s' % target) + self.assertEqual(len(files), 2) + p = subprocess.Popen([sys.executable, files[0]], stdout=subprocess.PIPE, stderr=subprocess.PIPE) +@@ -353,7 +351,7 @@ def test_script_run(self): + self.assertIn(b'

Current Working Directory:

', stdout) + self.assertIn(os.getcwd().encode('utf-8'), stdout) + else: +- self.assertIn(b'[Interpreter(0)]', stderr) ++ self.assertIn(b'frozenset(', stderr) + self.assertEqual(p.returncode, 1) + + @unittest.skipUnless(os.name == 'posix', 'Test only valid for POSIX')