%global srcname pydenticon Name: python-%{srcname} Version: 0.3.1 Release: 1%{?dist} Summary: Generate identicons: deterministic images derived from a hash # BSD-3-Clause: the licence carries the "Neither the name of Branko Majic nor # the names of any other contributors may be used to endorse" clause, so it is # the three-clause form, not the two. License: BSD-3-Clause URL: https://github.com/azaghal/%{srcname} Source0: %{pypi_source %{srcname}} BuildArch: noarch BuildRequires: python3-devel BuildRequires: pyproject-rpm-macros # %%check BuildRequires: python3-pytest # Upstream's tests import the standalone mock shim rather than unittest.mock. BuildRequires: python3-mock # Pillow is the runtime dependency and the tests compare rendered output to the # PNGs in tests/samples/ with PIL.ImageChops. BuildRequires: python3-pillow %global _description %{expand: Pydenticon renders an identicon for any piece of data: it hashes the input and draws a small symmetric pattern of blocks from the digest, so the same input always gives the same image and different inputs look obviously different. It writes PNG through Pillow, or an ASCII grid. It is packaged here under sequenticon, which uses it to give a DNA sequence a recognisable visual fingerprint -- a way to tell at a glance that two records are or are not the same construct.} %description %_description %package -n python3-%{srcname} Summary: %{summary} %description -n python3-%{srcname} %_description %prep %autosetup -p1 -n %{srcname}-%{version} %generate_buildrequires %pyproject_buildrequires %build %pyproject_wheel %install %pyproject_install %pyproject_save_files -l %{srcname} %check # Upstream's suite, all of it. The PyPI sdist ships tests/ and tests/samples/ # together, so unusually for this stack the sdist is enough. # # Expect around 250 DeprecationWarnings, none of them from this package: the # tests use the standalone mock shim, and Fedora's python3-mock 4.0.3 calls # asyncio.iscoroutinefunction, deprecated in 3.14. Harmless here and not worth # patching the imports over. %pytest -q tests %files -n python3-%{srcname} -f %{pyproject_files} %doc README.rst %changelog * Sun Sep 27 2026 Morgan Hough - 0.3.1-1 - Initial package: Pydenticon 0.3.1. Net-new to Fedora. - Packaged for sequenticon, which is between here and genedom. - From the PyPI sdist: it ships the tests and their reference PNGs, so there was no reason to reach for the GitHub tag. - Pillow is the only runtime dependency.