From 4676b0c27b847ad0bd099bb58ce7fae1a67a2bd1dac22d240e991b409925ccec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Schr=C3=B6ter?= Date: Fri, 13 Dec 2024 12:32:37 +0100 Subject: [PATCH] Sync from SUSE:SLFO:Main python-twine revision b80573941bd177969b54c87832a50ad6 --- 0001-remove-disable-socket-pytest-opt.patch | 3 +- license_files.patch | 13 -------- python-twine.changes | 32 ++++++++++++++++++ python-twine.spec | 35 ++++++++++---------- skip-unsupported-Metadata-Version-test.patch | 20 +++++++++++ twine-4.0.2.tar.gz | 3 -- twine-5.1.1.tar.gz | 3 ++ 7 files changed, 75 insertions(+), 34 deletions(-) delete mode 100644 license_files.patch create mode 100644 skip-unsupported-Metadata-Version-test.patch delete mode 100644 twine-4.0.2.tar.gz create mode 100644 twine-5.1.1.tar.gz diff --git a/0001-remove-disable-socket-pytest-opt.patch b/0001-remove-disable-socket-pytest-opt.patch index 40aba97..b91b8a2 100644 --- a/0001-remove-disable-socket-pytest-opt.patch +++ b/0001-remove-disable-socket-pytest-opt.patch @@ -6,8 +6,9 @@ Only in twine-3.4.1: .pytest_cache --- a/pytest.ini +++ b/pytest.ini -@@ -6,4 +6,3 @@ filterwarnings= +@@ -6,5 +6,4 @@ filterwarnings= ignore:the imp module is deprecated::setuptools addopts = - --disable-socket + --ignore-glob '*integration*.py' diff --git a/license_files.patch b/license_files.patch deleted file mode 100644 index 2182ee5..0000000 --- a/license_files.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- - setup.cfg | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/setup.cfg -+++ b/setup.cfg -@@ -1,5 +1,5 @@ - [metadata] --license_file = LICENSE -+license_files = LICENSE - name = twine - author = Donald Stufft and individual contributors - author_email = donald@stufft.io diff --git a/python-twine.changes b/python-twine.changes index b894740..80f4e8c 100644 --- a/python-twine.changes +++ b/python-twine.changes @@ -1,3 +1,35 @@ +------------------------------------------------------------------- +Fri Oct 11 11:50:51 UTC 2024 - John Paul Adrian Glaubitz + +- Update to 5.1.1 + * Resolve DeprecationWarnings when extracting ``twine`` metadata. + * Fix bug for Repository URLs with auth where the port was lost. When attempting + to prevent printing authentication credentials in URLs provided with username + and password, we did not properly handle the case where the URL also contains + a port (when reconstructing the URL). This is now handled and tested to + ensure no regressions. + +------------------------------------------------------------------- +Sat Jun 29 12:59:17 UTC 2024 - Dirk Müller + +- update to 5.1.0: + * Add the experimental --attestations flag. + +------------------------------------------------------------------- +Wed Apr 10 08:39:37 UTC 2024 - Ana Guerrero + +- Add BuildRequires on python-jaraco.packaging that was pulled + by other Build Requires. + +------------------------------------------------------------------- +Mon Mar 18 08:14:45 UTC 2024 - Matej Cepl + +- Update to 5.0.0: + - Use email.message instead of cgi as cgi has been deprecated +- Remove upstreamed patch license_files.patch +- Add skip-unsupported-Metadata-Version-test.patch + (gh#pypa/twine#1071) to skip failing test case. + ------------------------------------------------------------------- Fri May 5 13:44:23 UTC 2023 - Matej Cepl diff --git a/python-twine.spec b/python-twine.spec index 53dbb06..0cb50fd 100644 --- a/python-twine.spec +++ b/python-twine.spec @@ -1,7 +1,7 @@ # # spec file for package python-twine # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,48 +16,49 @@ # -%define skip_python2 1 %{?sle15_python_module_pythons} Name: python-twine -Version: 4.0.2 +Version: 5.1.1 Release: 0 Summary: Collection of utilities for interacting with PyPI License: Apache-2.0 URL: https://github.com/pypa/twine Source: https://files.pythonhosted.org/packages/source/t/twine/twine-%{version}.tar.gz Patch0: 0001-remove-disable-socket-pytest-opt.patch -# PATCH-FIX-UPSTREAM license_files.patch gh#pypa/twine!992 mcepl@suse.com -# license_file -> license_files -Patch1: license_files.patch -BuildRequires: %{python_module importlib-metadata} +# PATCH-FIX-UPSTREAM skip-unsupported-Metadata-Version-test.patch gh#pypa/twine#1071 mcepl@suse.com +# Skip failing test case +Patch1: skip-unsupported-Metadata-Version-test.patch +BuildRequires: %{python_module importlib-metadata >= 3.6} BuildRequires: %{python_module jaraco.envs} +BuildRequires: %{python_module jaraco.packaging >= 9} BuildRequires: %{python_module keyring >= 15.1} BuildRequires: %{python_module munch} BuildRequires: %{python_module pip} -BuildRequires: %{python_module pkginfo >= 1.4.2} +BuildRequires: %{python_module pkginfo >= 1.8.1} BuildRequires: %{python_module portend} BuildRequires: %{python_module pretend} BuildRequires: %{python_module pytest} -BuildRequires: %{python_module readme_renderer >= 21.0} +BuildRequires: %{python_module readme_renderer >= 35.0} BuildRequires: %{python_module requests >= 2.20} BuildRequires: %{python_module requests-toolbelt >= 0.8.0} BuildRequires: %{python_module rfc3986 >= 1.4.0} -BuildRequires: %{python_module rich} -BuildRequires: %{python_module setuptools >= 0.7.0} -BuildRequires: %{python_module setuptools_scm >= 1.15} +BuildRequires: %{python_module rich >= 12.0.0} +BuildRequires: %{python_module setuptools >= 45} +BuildRequires: %{python_module setuptools_scm >= 6.0} +BuildRequires: %{python_module urllib3 >= 1.26.0} BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: python-importlib-metadata +Requires: python-importlib-metadata >= 3.6 Requires: python-keyring >= 15.1 -Requires: python-pkginfo >= 1.4.2 -Requires: python-readme_renderer >= 21.0 +Requires: python-pkginfo >= 1.8.1 +Requires: python-readme_renderer >= 35.0 Requires: python-requests >= 2.20 Requires: python-requests-toolbelt >= 0.8.0 Requires: python-rfc3986 >= 1.4.0 -Requires: python-rich +Requires: python-rich >= 12.0.0 Requires(post): update-alternatives -Requires(postun):update-alternatives +Requires(postun): update-alternatives BuildArch: noarch %python_subpackages diff --git a/skip-unsupported-Metadata-Version-test.patch b/skip-unsupported-Metadata-Version-test.patch new file mode 100644 index 0000000..b0767b0 --- /dev/null +++ b/skip-unsupported-Metadata-Version-test.patch @@ -0,0 +1,20 @@ +--- + tests/test_package.py | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +Index: twine-5.1.0/tests/test_package.py +=================================================================== +--- twine-5.1.0.orig/tests/test_package.py ++++ twine-5.1.0/tests/test_package.py +@@ -384,11 +384,6 @@ def test_fips_metadata_excludes_md5_and_ + "read_data, missing_fields", + [ + pytest.param( +- b"Metadata-Version: 102.3\nName: test-package\nVersion: 1.0.0\n", +- "Name, Version", +- id="unsupported Metadata-Version", +- ), +- pytest.param( + b"Metadata-Version: 2.3\nName: UNKNOWN\nVersion: UNKNOWN\n", + "Name, Version", + id="missing Name and Version", diff --git a/twine-4.0.2.tar.gz b/twine-4.0.2.tar.gz deleted file mode 100644 index f9a79b3..0000000 --- a/twine-4.0.2.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9e102ef5fdd5a20661eb88fad46338806c3bd32cf1db729603fe3697b1bc83c8 -size 215249 diff --git a/twine-5.1.1.tar.gz b/twine-5.1.1.tar.gz new file mode 100644 index 0000000..ea51d73 --- /dev/null +++ b/twine-5.1.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9aa0825139c02b3434d913545c7b847a21c835e11597f5255842d457da2322db +size 225531