Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at
Bug 2144838 - Review Request: python-cattrs - Python library for structuring and unstructuring data
Summary: Review Request: python-cattrs - Python library for structuring and unstructur...
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Arthur Bols
QA Contact: Fedora Extras Quality Assurance
Depends On:
Blocks: fedora-neuro, NeuroFedora
TreeView+ depends on / blocked
Reported: 2022-11-22 13:50 UTC by Ankur Sinha (FranciscoD)
Modified: 2022-12-07 14:04 UTC (History)
3 users (show)

Fixed In Version: python-cattrs-22.2.0-7.fc38
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2022-12-07 14:04:45 UTC
Type: ---
arthur: fedora-review+

Attachments (Terms of Use)

Description Ankur Sinha (FranciscoD) 2022-11-22 13:50:13 UTC
Spec URL:

cattrs is an open source Python library for structuring and
unstructuring data. cattrs works best with attrs classes and the usual
Python collections, but other kinds of classes are supported by
manually registering converters.

Fedora Account System Username: ankursinha

Comment 1 Ankur Sinha (FranciscoD) 2022-11-22 13:50:15 UTC
This package built on koji:

Comment 2 Ankur Sinha (FranciscoD) 2022-11-22 13:51:33 UTC
This is a re-review since the package was retired:

Blocking fedora-neuro since some of our COPR packages need this.

Comment 4 Arthur Bols 2022-12-01 22:34:32 UTC
- License file seems to be missing 

Package Review

[x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated

- If (and only if) the source package includes the text of the license(s)
  in its own file, then that file, containing the text of the license(s)
  for the package is included in %license.
  Note: License file LICENSE is not marked as %license
- Package does not use a name that already exists.
  Note: A package with this name already exists. Please check

===== MUST items =====

[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "MIT License", "*No copyright* MIT License", "Unknown or
     generated". 33 files have unknown license. Detailed output of
     licensecheck in /home/arthur/fedora-review/2144838-python-
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[x]: Package contains desktop file if it is a GUI application.
[x]: Development files must be in a -devel package
[x]: Package uses nothing in %doc for runtime.
[x]: Package consistently uses macros (instead of hard-coded directory
[x]: Package is named according to the Package Naming Guidelines.
[x]: Package does not generate any conflict.
[x]: Package obeys FHS, except libexecdir and /usr/target.
[x]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[x]: Requires correct, justified where necessary.
[x]: Spec file is legible and written in American English.
[x]: Package contains systemd file(s) if in need.
[x]: Package is not known to require an ExcludeArch tag.
[x]: Package complies to the Packaging Guidelines
[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
[x]: Package installs properly.
[x]: Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: Package requires other packages for directories it uses.
[x]: Package must own all directories that it creates.
[x]: Package does not own files or directories owned by other packages.
[x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Dist tag is present.
[x]: Package does not contain duplicates in %files.
[x]: Permissions on files are set properly.
[x]: Package must not depend on deprecated() packages.
[x]: Package use %makeinstall only when make install DESTDIR=... doesn't
[x]: Package is named using only allowed ASCII characters.
[x]: Package is not relocatable.
[x]: Sources used to build the package match the upstream source, as
     provided in the spec URL.
[x]: Spec file name must match the spec package %{name}, in the format
[x]: File names are valid UTF-8.
[x]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 0 bytes in 0 files.
[x]: Packages must not store files under /srv, /opt or /usr/local

[x]: Python eggs must not download any dependencies during the build
[x]: A package which is used by another package via an egg interface should
     provide egg info.
[x]: Package meets the Packaging Guidelines::Python
[x]: Package contains BR: python2-devel or python3-devel
[x]: Packages MUST NOT have dependencies (either build-time or runtime) on
     packages named with the unversioned python- prefix unless no properly
     versioned package exists. Dependencies on Python packages instead MUST
     use names beginning with python2- or python3- as appropriate.
[x]: Python packages must not contain %{pythonX_site(lib|arch)}/* in %files
[x]: Binary eggs must be removed in %prep

===== SHOULD items =====

[-]: If the source package does not include license text(s) as a separate
     file from upstream, the packager SHOULD query upstream to include it.
[x]: Final provides and requires are sane (see attachments).
[?]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[-]: Sources are verified with gpgverify first in %prep if upstream
     publishes signatures.
     Note: gpgverify is not used.
[x]: Package should compile and build into binary rpms on all supported
[x]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
[x]: Reviewer should test that the package builds in mock.
[x]: Buildroot is not present
[x]: Package has no %clean section with rm -rf %{buildroot} (or
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

===== EXTRA items =====

[!]: Spec file according to URL is the same as in SRPM.
     Note: Spec file as given by url is not the same as in SRPM (see
     attached diff).
     See: (this test has no URL)
[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).

Cannot parse rpmlint output:

Rpmlint (installed packages)
============================ rpmlint session starts ============================
rpmlint: 2.4.0
checks: 31, packages: 1

python3-cattrs.noarch: W: no-documentation
 1 packages and 0 specfiles checked; 0 errors, 1 warnings, 0 badness; has taken 0.0 s 

Source checksums
---------------- :
  CHECKSUM(SHA256) this package     : f0eed5642399423cf656e7b66ce92cdc5b963ecafd041d1b24d136fdde7acf6d
  CHECKSUM(SHA256) upstream package : f0eed5642399423cf656e7b66ce92cdc5b963ecafd041d1b24d136fdde7acf6d

python3-cattrs (rpmlib, GLIBC filtered):


Diff spec file in url and in SRPM
--- /home/arthur/fedora-review/2144838-python-cattrs/srpm/python-cattrs.spec	2022-12-01 23:17:40.582573677 +0100
+++ /home/arthur/fedora-review/2144838-python-cattrs/srpm-unpacked/python-cattrs.spec	2022-11-22 14:55:15.000000000 +0100
@@ -1,2 +1,12 @@
+## START: Set by rpmautospec
+## (rpmautospec version 0.3.1)
+## RPMAUTOSPEC: autorelease, autochangelog
+%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
+    release_number = 2;
+    base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}"));
+    print(release_number + base_release_number - 1);
+## END: Set by rpmautospec
 %global _description %{expand:
 cattrs is an open source Python library for structuring and
@@ -61,3 +71,42 @@
+* Tue Nov 22 2022 Ankur Sinha (Ankur Sinha Gmail) <sanjay.ankur> - 22.2.0-2
+- Uncommitted changes
+* Tue Nov 22 2022 Ankur Sinha (Ankur Sinha Gmail) <sanjay.ankur> - 22.2.0-1
+- feat: ready for re-review
+* Mon Sep 12 2022 Ankur Sinha (Ankur Sinha Gmail) <sanjay.ankur> - 22.1.0-1
+- wip: requires orjson, which requires maturin
+* Mon Aug 19 2019 Miro Hrončok <mhroncok> - 0.9.0-5
+- Rebuilt for Python 3.8
+* Fri Jul 26 2019 Fedora Release Engineering <releng> - 0.9.0-4
+- Rebuilt for
+* Sat Feb 02 2019 Fedora Release Engineering <releng> - 0.9.0-3
+- Rebuilt for
+* Wed Oct 17 2018 Zbigniew Jędrzejewski-Szmek <> - 0.9.0-2
+- Subpackage python2-cattrs has been removed
+  See
+* Thu Sep 13 2018 Miro Hrončok <mhroncok> - 0.9.0-1
+- Update to 0.9.0 to fix Python 3.7 FTBFS (#1605625)
+* Fri Jul 13 2018 Fedora Release Engineering <releng> - 0.6.0-5
+- Rebuilt for
+* Tue Jun 19 2018 Miro Hrončok <mhroncok> - 0.6.0-4
+- Rebuilt for Python 3.7
+* Fri Feb 09 2018 Fedora Release Engineering <releng> - 0.6.0-3
+- Rebuilt for
+* Mon Jan 29 2018 Eric Smith <brouhaha> 0.6.0-2
+- Added missing BuildRequires for python2-enum34.
+* Thu Jan 11 2018 Eric Smith <brouhaha> 0.6.0-1
+- Initial version.

Generated by fedora-review 0.9.0 (6761b6c) last change: 2022-08-23
Command line :/usr/bin/fedora-review -b 2144838
Buildroot used: fedora-rawhide-x86_64
Active plugins: Shell-api, Python, Generic
Disabled plugins: R, Perl, SugarActivity, Java, Ocaml, Haskell, PHP, C/C++, fonts

Comment 5 Arthur Bols 2022-12-01 22:38:38 UTC
Also add the README.rst ;)

Comment 6 Ankur Sinha (FranciscoD) 2022-12-02 10:39:19 UTC
Thanks for the review, Arthur.

Hrm, weirdly enough it's included but not marked as a %license by the pyproject macros from the looks of it:

rpm -ql -p ./results_python-cattrs/22.2.0/2.fc38/python3-cattrs-22.2.0-2.fc38.noarch.rpm  | grep LIC

I've added it explicitly now along with the readme:

$ rpm -ql --licensefiles -p ./results_python-cattrs/22.2.0/3.fc38/python3-cattrs-22.2.0-3.fc38.noarch.rpm 

Updated spec/srpm:

Spec URL:


Comment 7 Arthur Bols 2022-12-02 11:02:41 UTC
Thanks for the changes. 

There's one thing I find a little bit strange. The subpackage is defined using %{python3_pkgversion}, but everywhere else it's just "python3-cattrs". I'm not sure if that's correct.

Please verify this before import. Package approved!

Comment 8 Ankur Sinha (FranciscoD) 2022-12-02 11:20:34 UTC
Thanks for that. It was leftover from the original package spec. The macro does expand to 3 at the moment, but I've removed it for consistency:

$ rpm -E %python3_pkgversion

I'll go ask releng to unretire the package now.

Comment 9 Ankur Sinha (FranciscoD) 2022-12-02 11:22:06 UTC

Comment 10 Miro Hrončok 2022-12-02 12:01:28 UTC
Why is this needed?

BuildRequires:  python3-setuptools

The packatge has: build-backend = "poetry.core.masonry.api"

So if setuptools is needed, it is likely for tests? But the tests don't run. For the same reason, BuildRequiring pytest and pytest-benchmark is probably overkill.

Comment 11 Ankur Sinha (FranciscoD) 2022-12-02 12:58:05 UTC
Good catch. Removed them all, and it still builds:

Comment 12 Miro Hrončok 2022-12-02 13:52:34 UTC
I'm pretty sure this applies to hypothesis as well and possibly all the manually listed build dependencies other than python3-devel.

Comment 13 Ankur Sinha (FranciscoD) 2022-12-02 14:06:13 UTC
Yeh, neither hypothesis nor immutables are imported. Removed too:

Comment 14 Arthur Bols 2022-12-02 23:03:23 UTC
Sorry, should've looked better. Thanks for catching it!

Note You need to log in before you can comment on or make changes to this bug.