#1 Update to pyproject-rpm-macros, SPDX, rpmautospec
Merged 7 months ago by music. Opened 7 months ago by music.
rpms/ music/python-datrie maint-202310  into  main

85.patch 0001-BUG-Decode-string-based-on-byteorder-of-system.patch
file renamed
+7 -4
@@ -1,8 +1,11 @@ 

- commit 0b5e0aa3924e4e784257f89e8fc47b07ed5690ba

- Author: Aniket Pradhan <aniket17133@iiitd.ac.in>

- Date:   Wed Nov 4 13:53:15 2020 +0530

+ From 0b5e0aa3924e4e784257f89e8fc47b07ed5690ba Mon Sep 17 00:00:00 2001

+ From: Aniket Pradhan <aniket17133@iiitd.ac.in>

+ Date: Wed, 4 Nov 2020 13:53:15 +0530

+ Subject: [PATCH] BUG: Decode string based on byteorder of system

  

-     BUG: Decode string based on byteorder of system

+ ---

+  src/datrie.pyx | 5 ++++-

+  1 file changed, 4 insertions(+), 1 deletion(-)

  

  diff --git a/src/datrie.pyx b/src/datrie.pyx

  index 0f91a41..4fae913 100644

file added
+29
@@ -0,0 +1,29 @@ 

+ * Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-10

+ - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild

+ 

+ * Thu Jun 15 2023 Python Maint <python-maint@redhat.com> - 0.8.2-9

+ - Rebuilt for Python 3.12

+ 

+ * Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-8

+ - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild

+ 

+ * Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-7

+ - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild

+ 

+ * Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 0.8.2-6

+ - Rebuilt for Python 3.11

+ 

+ * Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-5

+ - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild

+ 

+ * Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-4

+ - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild

+ 

+ * Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 0.8.2-3

+ - Rebuilt for Python 3.10

+ 

+ * Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-2

+ - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild

+ 

+ * Sat Nov 21 2020 Aniket Pradhan <major AT fedoraproject DOT org> - 0.8.2-1

+ - Initial build

file modified
+29 -66
@@ -1,6 +1,4 @@ 

- %bcond_without tests

- 

- %global pypi_name datrie

+ %bcond tests 1

  

  %global _description %{expand:

  The library implements the Trie data structure. The trie variable is a
@@ -12,94 +10,59 @@ 

  items whose keys are prefixes of a given string. As a common special case,

  finding the longest-prefix item is also supported.}

  

- Name:           python-%{pypi_name}

+ Name:           python-datrie

  Version:        0.8.2

- Release:        10%{?dist}

+ Release:        %autorelease

  Summary:        Super-fast, efficiently stored Trie for Python

  

- License:        LGPLv2

- URL:            https://github.com/pytries/%{pypi_name}

- Source0:        %{pypi_source}

- # Patch to correctly decode on big/little endian systems

+ License:        LGPL-2.1-or-later

+ URL:            https://github.com/pytries/datrie

+ Source:         %{pypi_source datrie}

+ # BUGFIX: Decode string based on byteorder of system

+ # https://github.com/pytries/datrie/pull/85

+ #

+ # Fixes:

+ #

+ # UnicodeDecodeError: 'utf32' codec can't decode bytes in position 0-3: code

+ # point not in range(0x110000)

  # https://github.com/pytries/datrie/issues/38

- Patch0:			0001-BUG-Decode-string-based-on-byteorder-of-system.patch

+ Patch:          https://github.com/pytries/datrie/pull/85.patch

  

- %description %_description

+ BuildRequires:  python3-devel

  

- %package -n python3-%{pypi_name}

- Summary:        %{summary}

  BuildRequires:  gcc-c++

  BuildRequires:  libdatrie

- BuildRequires:  python3-devel

- BuildRequires:  %{py3_dist Cython}

- BuildRequires:  %{py3_dist setuptools}

  

- %if %{with tests}

- BuildRequires:  %{py3_dist pytest}

- BuildRequires:  %{py3_dist pytest-runner}

- BuildRequires:  %{py3_dist hypothesis}

- %endif

+ %description %_description

  

- %py_provides python3-%{pypi_name}

+ %package -n python3-datrie

+ Summary:        %{summary}

  

- %description -n python3-%{pypi_name} %_description

+ %description -n python3-datrie %_description

  

  %prep

- %autosetup -p1 -n %{pypi_name}-%{version}

- rm -rf %{pypi_name}.egg-info

+ %autosetup -p1 -n datrie-%{version}

  

  # use system's libdatrie

- sed -i -e 's/..\/libdatrie\///g' src/cdatrie.pxd

+ sed -r -i -e 's@\.\./libdatrie/@@g' src/cdatrie.pxd

  

- find . -type f -name "*.py" -exec sed -i '/^#![  ]*\/usr\/bin\/env.*$/ d' {} 2>/dev/null ';'

+ %generate_buildrequires

+ %pyproject_buildrequires -t

  

  %build

- %py3_build

+ %pyproject_wheel

  

  %install

- %py3_install

+ %pyproject_install

+ %pyproject_save_files datrie

  

  %check

  %if %{with tests}

- export PYTHONPATH=%{buildroot}%{python3_sitearch}

- pytest-%{python3_version}

+ %tox

  %endif

  

- %files -n python3-%{pypi_name}

+ %files -n python3-datrie -f %{pyproject_files}

  %doc README.rst

- %license COPYING

- 

- %{python3_sitearch}/datrie.cpython-*.so

- %{python3_sitearch}/%{pypi_name}-%{version}-py%{python3_version}.egg-info

- 

  

  %changelog

- * Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-10

- - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild

- 

- * Thu Jun 15 2023 Python Maint <python-maint@redhat.com> - 0.8.2-9

- - Rebuilt for Python 3.12

- 

- * Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-8

- - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild

- 

- * Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-7

- - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild

- 

- * Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 0.8.2-6

- - Rebuilt for Python 3.11

- 

- * Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-5

- - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild

- 

- * Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-4

- - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild

- 

- * Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 0.8.2-3

- - Rebuilt for Python 3.10

- 

- * Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.2-2

- - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild

- 

- * Sat Nov 21 2020 Aniket Pradhan <major AT fedoraproject DOT org> - 0.8.2-1

- - Initial build

+ %autochangelog

Full details in the changelog messages.

Happy to drop rpmautospec if you dislike it. The rest should be uncontroversial, I think.

Build succeeded.
https://fedora.softwarefactory-project.io/zuul/buildset/261abff066ab4af6b2deabc4900fc141

LGTM.

Let's try and keep rpmautospec unless there are particular issues with it---it does make life somewhat easier, and it'll be good to be consistent throughout our packages (otherwise, I'm sure I'll forget to add a changelog somewhere not realising that rpmautospec isn't used XD)

Pull-Request has been merged by music

7 months ago