diff options
author | Michał Górny <mgorny@gentoo.org> | 2023-05-30 04:50:42 +0200 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2023-05-30 04:53:58 +0200 |
commit | 1e7ce870693a036512d1e5ba169b7fad36ef9395 (patch) | |
tree | 6ac43d1a4c12ec7e388d2d6195296c91308f5834 /dev-python/poetry-core | |
parent | dev-python/pip-run: Bump to 11.0.0 (diff) | |
download | gentoo-1e7ce870693a036512d1e5ba169b7fad36ef9395.tar.gz gentoo-1e7ce870693a036512d1e5ba169b7fad36ef9395.tar.bz2 gentoo-1e7ce870693a036512d1e5ba169b7fad36ef9395.zip |
dev-python/poetry-core: Bump to 1.6.1
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/poetry-core')
-rw-r--r-- | dev-python/poetry-core/Manifest | 1 | ||||
-rw-r--r-- | dev-python/poetry-core/files/poetry-core-1.6.1-pypy3.patch | 60 | ||||
-rw-r--r-- | dev-python/poetry-core/poetry-core-1.6.1.ebuild | 79 |
3 files changed, 140 insertions, 0 deletions
diff --git a/dev-python/poetry-core/Manifest b/dev-python/poetry-core/Manifest index 96c65feff1ed..ad4523de67f5 100644 --- a/dev-python/poetry-core/Manifest +++ b/dev-python/poetry-core/Manifest @@ -1,2 +1,3 @@ DIST poetry-core-1.5.2.gh.tar.gz 484004 BLAKE2B 56fe974bb37233ee75a220d35dab3d246b9a4145a3abd88981a0c2b9f51cb894b3534746638d7fa75a41451c856261b0b8e737af8778f78fcc9ae894a4b2430f SHA512 e0eab97bcf678f8fd329074d14cb394db8732666b0387384d273db49ec020ff34e15e9982e049bce62e9ba80443404de7646e66433164a2358f9802a8ce2fbb1 DIST poetry-core-1.6.0.gh.tar.gz 476282 BLAKE2B 9c78b60b0578c9e882c468d8523587e8ddf799764efc1d343fdbcbc7e1ac56cc642ecfa5e74a6b134d190491e06105579951fd4bc8d41264358032c2a6bd5fb7 SHA512 a8a36feda81fdf5b74de77cb718680a12edda44d0b6e87f5b80704d7a5898780b89dfa8168c55e4e8b2352f1a6051072e7e9f35dc5936d1b0b24a1704063ed1d +DIST poetry-core-1.6.1.gh.tar.gz 477291 BLAKE2B 4e1bd77302005d344693fe7a08b0c55e8a9ea0aad3112915a18950e40cc51116740b9eff5ae851b1d7280454716e3a86b1d8d37d85749f64fcef3bc726eeaf83 SHA512 53db0e4f4d5bc6ed2b201cd88a84e07dc6421e910292b8b5efb0dcce1af6e8c62836458a6409aac0394b5063b7c4a6be93784b0bce8592d74f61800f54916706 diff --git a/dev-python/poetry-core/files/poetry-core-1.6.1-pypy3.patch b/dev-python/poetry-core/files/poetry-core-1.6.1-pypy3.patch new file mode 100644 index 000000000000..ab0979a71cf0 --- /dev/null +++ b/dev-python/poetry-core/files/poetry-core-1.6.1-pypy3.patch @@ -0,0 +1,60 @@ +From 12d231eeb3d853217dd6e0527da7e286cdc1346b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Randy=20D=C3=B6ring?= + <30527984+radoering@users.noreply.github.com> +Date: Mon, 29 May 2023 18:40:35 +0200 +Subject: [PATCH 1/2] chore: update dev dependencies for Python 3.12 + compatibility (#597) + +--- + poetry.lock | 170 ++++++++++++------------ + tests/masonry/builders/test_complete.py | 3 +- + tests/masonry/builders/test_wheel.py | 5 +- + 3 files changed, 91 insertions(+), 87 deletions(-) + +diff --git a/tests/masonry/builders/test_complete.py b/tests/masonry/builders/test_complete.py +index 4e4dff0..c9429c1 100644 +--- a/tests/masonry/builders/test_complete.py ++++ b/tests/masonry/builders/test_complete.py +@@ -19,6 +19,7 @@ import pytest + from poetry.core import __version__ + from poetry.core.factory import Factory + from poetry.core.masonry.builder import Builder ++from tests.masonry.builders.test_wheel import WHEEL_TAG_REGEX + + + if TYPE_CHECKING: +@@ -82,7 +83,7 @@ def test_wheel_c_extension(project: str, exptected_c_dir: str) -> None: + Wheel-Version: 1.0 + Generator: poetry-core {__version__} + Root-Is-Purelib: false +-Tag: cp[23]_?\\d+-cp[23]_?\\d+m?u?-.+ ++Tag: {WHEEL_TAG_REGEX} + $""", + wheel_data, + ) +diff --git a/tests/masonry/builders/test_wheel.py b/tests/masonry/builders/test_wheel.py +index d25d642..c41e4a5 100644 +--- a/tests/masonry/builders/test_wheel.py ++++ b/tests/masonry/builders/test_wheel.py +@@ -25,6 +25,9 @@ if TYPE_CHECKING: + fixtures_dir = Path(__file__).parent / "fixtures" + + ++WHEEL_TAG_REGEX = "[cp]p[23]_?\\d+-(?:cp[23]_?\\d+m?u?|pypy[23]_?\\d+_pp\\d+)-.+" ++ ++ + @pytest.fixture(autouse=True) + def setup() -> Iterator[None]: + clear_samples_dist() +@@ -365,7 +368,7 @@ def test_tag(in_venv_build: bool, mocker: MockerFixture) -> None: + if not in_venv_build: + mocker.patch("sys.executable", "other/python") + +- assert re.match("^cp[23]_?\\d+-cp[23]_?\\d+m?u?-.+$", builder.tag) ++ assert re.match(f"^{WHEEL_TAG_REGEX}$", builder.tag) + if in_venv_build: + get_sys_tags_spy.assert_not_called() + else: +-- +2.40.1 + diff --git a/dev-python/poetry-core/poetry-core-1.6.1.ebuild b/dev-python/poetry-core/poetry-core-1.6.1.ebuild new file mode 100644 index 000000000000..304711f93c75 --- /dev/null +++ b/dev-python/poetry-core/poetry-core-1.6.1.ebuild @@ -0,0 +1,79 @@ +# Copyright 2022-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=standalone +PYTHON_TESTED=( pypy3 python3_{10..12} ) +PYTHON_COMPAT=( "${PYTHON_TESTED[@]}" ) + +inherit distutils-r1 + +DESCRIPTION="Poetry PEP 517 Build Backend" +HOMEPAGE=" + https://github.com/python-poetry/poetry-core/ + https://pypi.org/project/poetry-core/ +" +SRC_URI=" + https://github.com/python-poetry/poetry-core/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" + +# check inside src/poetry/core/_vendor/vendor.txt +# (note that some are indirect deps) +RDEPEND=" + dev-python/jsonschema[${PYTHON_USEDEP}] + dev-python/lark[${PYTHON_USEDEP}] + dev-python/packaging[${PYTHON_USEDEP}] + $(python_gen_cond_dep ' + dev-python/tomli[${PYTHON_USEDEP}] + ' 3.9 3.10) +" +BDEPEND=" + ${RDEPEND} + test? ( + $(python_gen_cond_dep ' + dev-python/build[${PYTHON_USEDEP}] + dev-python/pytest-mock[${PYTHON_USEDEP}] + dev-python/tomli-w[${PYTHON_USEDEP}] + dev-python/virtualenv[${PYTHON_USEDEP}] + dev-vcs/git + ' "${PYTHON_TESTED[@]}") + ) +" + +distutils_enable_tests pytest + +PATCHES=( + "${FILESDIR}/${P}-pypy3.patch" +) + +EPYTEST_DESELECT=( + # These "fail" bacause of glob file path resulting from newer versions + # in our tree than vendored. But those don't affect anything. + tests/masonry/builders/test_sdist.py::test_default_with_excluded_data + tests/masonry/builders/test_wheel.py::test_default_src_with_excluded_data +) + +src_prepare() { + # remove vendoring of dependencies + rm -r src/poetry/core/_vendor || die + sed -e '/__vendor_site__/d' -i src/poetry/core/__init__.py || die + + distutils-r1_src_prepare +} + +python_test() { + if ! has "${EPYTHON/./_}" "${PYTHON_TESTED[@]}"; then + einfo "Skippin tests on ${EPYTHON} (unported deps)" + return + fi + + # needed for migration from <1.1 + distutils_write_namespace poetry + epytest +} |