From 2d588fa8dd04c44d03e75e74fbe6903d8e27d72a Mon Sep 17 00:00:00 2001 From: eabdullin Date: Wed, 14 May 2025 16:06:33 +0000 Subject: [PATCH] import UBI python-prettytable-3.6.0-10.el10 --- .gitignore | 3 +- 0001-Drop-depedency-on-hatch-vcs.patch | 54 +++++++++ disable-encoding-check.patch | 12 -- gating.yaml | 6 - python-prettytable.spec | 155 +++++++++++++++++-------- sources | 2 +- 6 files changed, 163 insertions(+), 69 deletions(-) create mode 100644 0001-Drop-depedency-on-hatch-vcs.patch delete mode 100644 disable-encoding-check.patch delete mode 100644 gating.yaml diff --git a/.gitignore b/.gitignore index 0bdfa61..e58dfe8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ -SOURCES/prettytable-0.7.2.tar.gz -/prettytable-0.7.2.tar.gz +prettytable-3.6.0.tar.gz diff --git a/0001-Drop-depedency-on-hatch-vcs.patch b/0001-Drop-depedency-on-hatch-vcs.patch new file mode 100644 index 0000000..b54c808 --- /dev/null +++ b/0001-Drop-depedency-on-hatch-vcs.patch @@ -0,0 +1,54 @@ +From c34f3d01eb258ca6f97fc72d7bf8162aa40b4cab Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ond=C5=99ej=20Budai?= +Date: Tue, 6 Aug 2024 11:00:39 +0200 +Subject: [PATCH] Drop depedency on hatch-vcs + +We want to remove it from EL10, we don't need automatic versions there. +--- + pyproject.toml | 12 +----------- + 1 file changed, 1 insertion(+), 11 deletions(-) + +diff --git a/pyproject.toml b/pyproject.toml +index 410c5de..d7c3cb0 100644 +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -1,12 +1,12 @@ + [build-system] + build-backend = "hatchling.build" + requires = [ +- "hatch-vcs", + "hatchling", + ] + + [project] + name = "prettytable" ++version = "3.6.0" + description = "A simple Python library for easily displaying tabular data in a visually appealing ASCII table format" + readme = "README.md" + license = {text = "BSD (3 clause)"} +@@ -17,9 +17,6 @@ dependencies = [ + 'importlib-metadata; python_version < "3.8"', + "wcwidth", + ] +-dynamic = [ +- "version", +-] + classifiers = [ + "License :: OSI Approved :: BSD License", + "Programming Language :: Python", +@@ -46,12 +43,5 @@ tests = [ + Homepage = "https://github.com/jazzband/prettytable" + Source = "https://github.com/jazzband/prettytable" + +- +-[tool.hatch] +-version.source = "vcs" +- +-[tool.hatch.version.raw-options] +-local_scheme = "no-local-version" +- + [tool.isort] + profile = "black" +-- +2.45.2 + diff --git a/disable-encoding-check.patch b/disable-encoding-check.patch deleted file mode 100644 index 581c8f5..0000000 --- a/disable-encoding-check.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -Naur -Naru prettytable-0.7.2.orig/prettytable_test.py prettytable-0.7.2/prettytable_test.py ---- prettytable-0.7.2.orig/prettytable_test.py 2013-04-06 23:43:12.000000000 +0000 -+++ prettytable-0.7.2/prettytable_test.py 2014-01-07 18:49:26.017977139 +0000 -@@ -582,7 +582,7 @@ - - def testPrint(self): - print() -- print(self.x) -+ #print(self.x) - - if __name__ == "__main__": - unittest.main() diff --git a/gating.yaml b/gating.yaml deleted file mode 100644 index e60e254..0000000 --- a/gating.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- !Policy -product_versions: - - rhel-8 -decision_context: osci_compose_gate -rules: - - !PassingTestCaseRule {test_case_name: 3rd-azure-ci.brew-build.tier1.functional} diff --git a/python-prettytable.spec b/python-prettytable.spec index ee9d430..298d99b 100644 --- a/python-prettytable.spec +++ b/python-prettytable.spec @@ -1,39 +1,37 @@ -%global modname prettytable +## START: Set by rpmautospec +## (rpmautospec version 0.6.5) +## RPMAUTOSPEC: autorelease +%define autorelease(e:s:pb:n) %{?-p:0.}%{lua: + release_number = 10; + base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); + print(release_number + base_release_number - 1); +}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} +## END: Set by rpmautospec +%global pypi_name prettytable -Name: python-%{modname} -Version: 0.7.2 -Release: 14%{?dist} -Summary: Python library to display tabular data in tables +Name: python-%{pypi_name} +Version: 3.6.0 +Release: %autorelease +Summary: Python library to display tabular data in tables -Group: Development/Languages -License: BSD -Source0: http://pypi.python.org/packages/source/P/PrettyTable/%{modname}-%{version}.tar.gz -URL: http://pypi.python.org/pypi/PrettyTable +License: BSD-3-Clause +URL: https://github.com/jazzband/prettytable +Source0: %{pypi_source} +Patch0: 0001-Drop-depedency-on-hatch-vcs.patch -Patch0: disable-encoding-check.patch - -BuildArch: noarch +BuildArch: noarch BuildRequires: python3-devel BuildRequires: python3-setuptools +BuildRequires: python3-setuptools_scm +BuildRequires: sed +BuildRequires: python3dist(pytest) +BuildRequires: python3dist(pytest-lazy-fixture) +BuildRequires: python3dist(wcwidth) -%global _description\ -PrettyTable is a simple Python library designed to make it quick and easy to\ -represent tabular data in visually appealing ASCII tables. It was inspired by\ -the ASCII tables used in the PostgreSQL shell psql. PrettyTable allows for\ -selection of which columns are to be printed, independent alignment of columns\ -(left or right justified or centred) and printing of "sub-tables" by specifying\ -a row range. - -%description %_description - -%package -n python3-%{modname} -Summary: Python library to display tabular data in tables -Group: Development/Languages - -%description -n python3-%{modname} +%description PrettyTable is a simple Python library designed to make it quick and easy to represent tabular data in visually appealing ASCII tables. It was inspired by the ASCII tables used in the PostgreSQL shell psql. PrettyTable allows for @@ -41,38 +39,99 @@ selection of which columns are to be printed, independent alignment of columns (left or right justified or centred) and printing of "sub-tables" by specifying a row range. +%package -n python3-%{pypi_name} +Summary: Python library to display tabular data in tables + +%description -n python3-%{pypi_name} +PrettyTable is a simple Python library designed to make it quick and easy to +represent tabular data in visually appealing ASCII tables. It was inspired by +the ASCII tables used in the PostgreSQL shell psql. PrettyTable allows for +selection of which columns are to be printed, independent alignment of columns +(left or right justified or centred) and printing of "sub-tables" by specifying +a row range. %prep -%setup -q -n %{modname}-%{version} - -%patch0 -p1 - +%autosetup -n %{pypi_name}-%{version} -p1 +sed -i -e '/^*!\//, 1d' src/prettytable/*.py +%generate_buildrequires +%pyproject_buildrequires -r %build -%py3_build - -%check -%{__python3} %{modname}_test.py - +%pyproject_wheel %install -%py3_install +%pyproject_install +%pyproject_save_files prettytable +%check +%pytest -%files -n python3-%{modname} -%{!?_licensedir:%global license %%doc} -%license COPYING -%doc README CHANGELOG -%{python3_sitelib}/%{modname}.py* -%{python3_sitelib}/__pycache__/%{modname}* -%{python3_sitelib}/%{modname}-%{version}* - +%files -n python3-%{pypi_name} -f %{pyproject_files} +%doc README.md CHANGELOG.md %changelog -* Wed Jul 11 2018 Petr Viktorin - 0.7.2-14 -- Remove the Python 2 subpackage - https://bugzilla.redhat.com/show_bug.cgi?id=1567293 +* Tue Aug 06 2024 Ondřej Budai - 3.6.0-9 +- Drop the python-hatch-vcs dependency + +* Sat Mar 04 2023 Mikel Olasagasti Uranga - 3.6.0-1 +- Update to upstream 3.6.0 + +* Fri Jan 20 2023 Fedora Release Engineering - 0.7.2-31 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Fri Jul 22 2022 Fedora Release Engineering - 0.7.2-30 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Mon Jun 13 2022 Python Maint - 0.7.2-29 +- Rebuilt for Python 3.11 + +* Fri Jan 21 2022 Fedora Release Engineering - 0.7.2-28 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Fri Jul 23 2021 Fedora Release Engineering - 0.7.2-27 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Thu Jun 03 2021 Python Maint - 0.7.2-26 +- Rebuilt for Python 3.10 + +* Wed Jan 27 2021 Fedora Release Engineering - 0.7.2-25 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Wed Jul 29 2020 Fedora Release Engineering - 0.7.2-24 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Sat May 23 2020 Miro Hrončok - 0.7.2-23 +- Rebuilt for Python 3.9 + +* Thu Jan 30 2020 Fedora Release Engineering - 0.7.2-22 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Sun Nov 17 2019 Miro Hrončok - 0.7.2-21 +- Subpackage python2-prettytable has been removed + See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal + +* Thu Oct 03 2019 Miro Hrončok - 0.7.2-20 +- Rebuilt for Python 3.8.0rc1 (#1748018) + +* Fri Aug 16 2019 Miro Hrončok - 0.7.2-19 +- Rebuilt for Python 3.8 + +* Fri Jul 26 2019 Fedora Release Engineering - 0.7.2-18 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + +* Sat Feb 02 2019 Fedora Release Engineering - 0.7.2-17 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + +* Sat Jul 14 2018 Fedora Release Engineering - 0.7.2-16 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Fri Jun 15 2018 Miro Hrončok - 0.7.2-15 +- Rebuilt for Python 3.7 + +* Mon Feb 12 2018 Iryna Shcherbina - 0.7.2-14 +- Update Python 2 dependency declarations to new packaging standards + (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3) * Fri Feb 09 2018 Fedora Release Engineering - 0.7.2-13 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild diff --git a/sources b/sources index be6ef10..37c21bc 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (prettytable-0.7.2.tar.gz) = 84611b9ad11bd428cdb00795e0a9baff44d027331b73ed1742596acda8acc8aca3df4276fa2f2ca2289f10b2989b3c86556de70bca6a9773b15cd80c54c33117 +SHA512 (prettytable-3.6.0.tar.gz) = 845ecb38e34c0c8455d9e7c7dddbd8ca7db06195c8ae13964e05762aaacc1ec1e3da45efcc9b09c6bcf0c5874bb251b975fa3f37112cbfc583d40e637537fbbd