summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2022-02-23 21:55:10 +0100
committerMichał Górny <mgorny@gentoo.org>2022-02-23 22:30:08 +0100
commit9ab08bfd9470c338cc42714a60af1f0fc84205dc (patch)
treeaf2874f5e8e68649ba76b5f12d51ed349dca8c5c /dev-python/flit_core
parentdev-python/flit_core: Bump to 3.7.1 (diff)
downloadgentoo-9ab08bfd9470c338cc42714a60af1f0fc84205dc.tar.gz
gentoo-9ab08bfd9470c338cc42714a60af1f0fc84205dc.tar.bz2
gentoo-9ab08bfd9470c338cc42714a60af1f0fc84205dc.zip
dev-python/flit_core: Remove old
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/flit_core')
-rw-r--r--dev-python/flit_core/Manifest1
-rw-r--r--dev-python/flit_core/files/flit_core-3.7.0-fix-relative-imports-init-version.patch107
-rw-r--r--dev-python/flit_core/flit_core-3.7.0-r1.ebuild38
3 files changed, 0 insertions, 146 deletions
diff --git a/dev-python/flit_core/Manifest b/dev-python/flit_core/Manifest
index 7096b6450862..c748767a964a 100644
--- a/dev-python/flit_core/Manifest
+++ b/dev-python/flit_core/Manifest
@@ -1,4 +1,3 @@
DIST flit_core-3.5.1.tar.gz 27497 BLAKE2B 0e47576a05afa306a17e0fe64bd48e4a141fa51df225365495692aeae1c693635f1ea13ba23fdd93543c9b152dcfc2424bd8101a544ad25be2c4561964a8a8bb SHA512 c83b5bd54ffdf2d7dbea340939cb5f0210ffd36aa0f61b02519837843ebbab206a2456a007f76cbae45c2133ef3d21949d1834083c8dddb505ed5bb127a5fdba
DIST flit_core-3.6.0.tar.gz 37534 BLAKE2B 7450dcddc0719e17b79b82a07fbfee3116ea9eface5cba8f7d6fa27011f6b20822f8f5c02633ac75456b30327328ef60e05e15ca78a26935dfac5a66e2538a1e SHA512 6a217a6e7d8c4f81491314987ff1510f1cede233213982d9f7b2705ab5b1a7fb4b337ad9daa5ff824ed00034ba1d53215d56def86909240d49265e628ffb83b2
-DIST flit_core-3.7.0.tar.gz 39892 BLAKE2B 19521ea85d72986dc532618bc13bd646178c10caf012bdae7a5a1d6a45d233228aaa16ac1096170bf88074272078202fa340e1d4aa88dd998868c730209e3060 SHA512 13059aeda4694a110a8777ddf13458723cec6ab9f8eeeff6ed237e7a1c2c1873128553d33e605704ef7b5ffc9438087f0f5cf52d9c3208fedafcecbe5ebfa67c
DIST flit_core-3.7.1.tar.gz 40330 BLAKE2B 67a938ef576a70ce1bfe1f1bf996f1d2e468ea46f76ed2a363b278cebc42602b38fbf44a6bc45294996549d673d3145e2db2293780b8d157fd4f3b3876dc88cd SHA512 8c477bcd2924a93b51e6f3d8bbc3599929663c8d5addf16062e8e1b6c5acd740a4e4905b144092efb6e38e9700479525013831a53e055438f94c1e53ff5c6f8d
diff --git a/dev-python/flit_core/files/flit_core-3.7.0-fix-relative-imports-init-version.patch b/dev-python/flit_core/files/flit_core-3.7.0-fix-relative-imports-init-version.patch
deleted file mode 100644
index 858e66aee0b0..000000000000
--- a/dev-python/flit_core/files/flit_core-3.7.0-fix-relative-imports-init-version.patch
+++ /dev/null
@@ -1,107 +0,0 @@
-https://github.com/pypa/flit/issues/530
-https://github.com/pypa/flit/pull/531
-
-From c7c79459b61fe11ff0179d0ca7a72e8a90c0ee7b Mon Sep 17 00:00:00 2001
-From: Thomas Kluyver <thomas@kluyver.me.uk>
-Date: Tue, 22 Feb 2022 16:21:11 +0000
-Subject: [PATCH 1/2] Add failing test for issue gh-530
-
----
- .../samples/imported_version/package1/__init__.py | 3 +++
- .../samples/imported_version/package1/_version.py | 1 +
- .../tests/samples/imported_version/pyproject.toml | 10 ++++++++++
- flit_core/flit_core/tests/test_common.py | 5 +++++
- 4 files changed, 19 insertions(+)
- create mode 100644 flit_core/flit_core/tests/samples/imported_version/package1/__init__.py
- create mode 100644 flit_core/flit_core/tests/samples/imported_version/package1/_version.py
- create mode 100644 flit_core/flit_core/tests/samples/imported_version/pyproject.toml
-
-diff --git a/flit_core/tests/samples/imported_version/package1/__init__.py b/flit_core/tests/samples/imported_version/package1/__init__.py
-new file mode 100644
-index 0000000..49adc42
---- /dev/null
-+++ b/flit_core/tests/samples/imported_version/package1/__init__.py
-@@ -0,0 +1,3 @@
-+"""This module has a __version__ that requires a relative import"""
-+
-+from ._version import __version__
-diff --git a/flit_core/tests/samples/imported_version/package1/_version.py b/flit_core/tests/samples/imported_version/package1/_version.py
-new file mode 100644
-index 0000000..91201fc
---- /dev/null
-+++ b/flit_core/tests/samples/imported_version/package1/_version.py
-@@ -0,0 +1 @@
-+__version__ = '0.5.8'
-diff --git a/flit_core/tests/samples/imported_version/pyproject.toml b/flit_core/tests/samples/imported_version/pyproject.toml
-new file mode 100644
-index 0000000..b6d44e1
---- /dev/null
-+++ b/flit_core/tests/samples/imported_version/pyproject.toml
-@@ -0,0 +1,10 @@
-+[build-system]
-+requires = ["flit_core >=3.2,<4"]
-+build-backend = "flit_core.buildapi"
-+
-+[project]
-+name = "package1"
-+authors = [
-+ {name = "Sir Röbin", email = "robin@camelot.uk"}
-+]
-+dynamic = ["version", "description"]
-diff --git a/flit_core/tests/test_common.py b/flit_core/tests/test_common.py
-index 02cfab7..bd0995b 100644
---- a/flit_core/tests/test_common.py
-+++ b/flit_core/tests/test_common.py
-@@ -75,6 +75,11 @@ def test_get_info_from_module(self):
- 'version': '1.2.3'}
- )
-
-+ info = get_info_from_module(Module('package1', samples_dir / 'imported_version'))
-+ self.assertEqual(info, {'summary': 'This module has a __version__ that requires a relative import',
-+ 'version': '0.5.8'}
-+ )
-+
- with self.assertRaises(InvalidVersion):
- get_info_from_module(Module('invalid_version1', samples_dir))
-
-
-From 8a0ce8897a743dde3b82cca02f1d82516ad393fd Mon Sep 17 00:00:00 2001
-From: Thomas Kluyver <thomas@kluyver.me.uk>
-Date: Tue, 22 Feb 2022 16:49:46 +0000
-Subject: [PATCH 2/2] Fix relative imports in __init__.py when exec-ing to get
- __version__
-
----
- flit_core/flit_core/common.py | 11 ++++++++++-
- 1 file changed, 10 insertions(+), 1 deletion(-)
-
-diff --git a/flit_core/common.py b/flit_core/common.py
-index 0d6716c..ce69c95 100644
---- a/flit_core/common.py
-+++ b/flit_core/common.py
-@@ -3,6 +3,7 @@
- import hashlib
- import logging
- import os
-+import sys
-
- from pathlib import Path
- import re
-@@ -168,7 +169,15 @@ def get_docstring_and_version_via_import(target):
- spec = spec_from_file_location(mod_name, target.file)
- with _module_load_ctx():
- m = module_from_spec(spec)
-- spec.loader.exec_module(m)
-+ # Add the module to sys.modules to allow relative imports to work.
-+ # importlib has more code around this to handle the case where two
-+ # threads are trying to load the same module at the same time, but Flit
-+ # should always be running a single thread, so we won't duplicate that.
-+ sys.modules[mod_name] = m
-+ try:
-+ spec.loader.exec_module(m)
-+ finally:
-+ sys.modules.pop(mod_name, None)
-
- docstring = m.__dict__.get('__doc__', None)
- version = m.__dict__.get('__version__', None)
-
diff --git a/dev-python/flit_core/flit_core-3.7.0-r1.ebuild b/dev-python/flit_core/flit_core-3.7.0-r1.ebuild
deleted file mode 100644
index 65fd6ed76f45..000000000000
--- a/dev-python/flit_core/flit_core-3.7.0-r1.ebuild
+++ /dev/null
@@ -1,38 +0,0 @@
-# Copyright 2019-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-# please keep this ebuild at EAPI 7 -- sys-apps/portage dep
-EAPI=7
-
-DISTUTILS_USE_PEP517=standalone
-PYTHON_COMPAT=( python3_{8..10} pypy3 )
-inherit distutils-r1
-
-DESCRIPTION="Simplified packaging of Python modules (core module)"
-HOMEPAGE="
- https://pypi.org/project/flit_core/
- https://github.com/pypa/flit/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-
-RDEPEND="
- dev-python/tomli[${PYTHON_USEDEP}]
-"
-BDEPEND="
- test? ( dev-python/testpath[${PYTHON_USEDEP}] )
-"
-
-PATCHES=(
- "${FILESDIR}"/${P}-fix-relative-imports-init-version.patch
-)
-
-distutils_enable_tests pytest
-
-src_prepare() {
- rm -r flit_core/vendor || die
- sed -i -e 's:from \.vendor ::' flit_core/*.py || die
- distutils-r1_src_prepare
-}