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 2140076 - Review Request: python-interface-meta - Provides a convenient way to expose an extensible API
Summary: Review Request: python-interface-meta - Provides a convenient way to expose a...
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Sandro
QA Contact: Fedora Extras Quality Assurance
Whiteboard: Trivial
Depends On:
Blocks: fedora-neuro, NeuroFedora
TreeView+ depends on / blocked
Reported: 2022-11-04 11:07 UTC by Ankur Sinha (FranciscoD)
Modified: 2022-11-04 16:27 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2022-11-04 16:27:27 UTC
Type: ---
gui1ty: fedora-review+

Attachments (Terms of Use)

Description Ankur Sinha (FranciscoD) 2022-11-04 11:07:42 UTC
Spec URL:

interface_meta provides a convenient way to expose an extensible API with
enforced method signatures and consistent documentation.

This library has been extracted (with some modifications) from omniduct, a
library also principally written by this author, where it was central to the
extensible plugin architecture. It places an emphasis on the functionality
required to create a well-documented extensible plugin system, whereby the act
of subclassing is sufficient to register the plugin and ensure compliance to
the parent API. As such, this library boasts the following features:

- All subclasses of an interface must conform to the parent's API.
- Hierarchical runtime property existence and method signature checking.
  Methods are permitted to add additional optional arguments, but otherwise
  must conform to the API of their parent class (which themselves may have
  extended the API of the interface).
- Subclass definition time hooks (e.g. for registration of subclasses into a
  library of plugins, etc).
- Optional requirement for methods in subclasses to explicity decorate methods
  with an override decorator when replacing methods on an interface, making it
  clearer as to when a class is introducing new methods versus replacing those
  that form the part of the interface API.
- Generation of clear docstrings on implementations that stitches together the
  base interface documentation with any downstream extensions and quirks.
- Support for extracting the quirks documentation for a method from other
  method docstrings, in the event that subclass implementations are done in an
  internal method.
- Compatibility with ABCMeta from the standard library.

Fedora Account System Username: ankursinha

Comment 1 Ankur Sinha (FranciscoD) 2022-11-04 11:07:45 UTC
This package built on koji:

Comment 2 Sandro 2022-11-04 12:03:55 UTC

Comment 3 Sandro 2022-11-04 13:01:51 UTC

One minor nitpick: Since you have tests conditionalized, I would suggest the following in %check:

%if %{with tests}

This way the minimal import tests are run as required by Python Packaging Guidelines.

Nonetheless, APPROVED!

Package Review

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

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

[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
     Note: Using prebuilt packages
[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.
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[-]: Package contains desktop file if it is a GUI application.
[-]: Development files must be in a -devel package
[-]: 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.
[-]: 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.
[-]: Package contains systemd file(s) if in need.
[x]: Package is not known to require an ExcludeArch tag.
[x]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 10240 bytes in 1 files.
[x]: Package complies to the Packaging Guidelines
[x]: Package installs properly.
[x]: Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: 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.
[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]: 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 does not use a name that already exists.
[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]: Packages must not store files under /srv, /opt or /usr/local

[-]: Python eggs must not download any dependencies during the build
[-]: 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 =====

[x]: Reviewer should test that the package builds in mock.
[-]: 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]: Spec use %global instead of %define unless justified.
[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.

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

[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).

=> no errors, no warnings

Rpmlint (installed packages)
Cannot parse rpmlint output:

Source checksums
---------------- :
  CHECKSUM(SHA256) this package     : 6a96da34ef2a319cab788f6b0cb8afca03186adcc21e1da36f4985329cf86511
  CHECKSUM(SHA256) upstream package : 6a96da34ef2a319cab788f6b0cb8afca03186adcc21e1da36f4985329cf86511

python3-interface-meta (rpmlib, GLIBC filtered):


Generated by fedora-review 0.8.0 (e988316) last change: 2022-04-07
Command line :/usr/bin/fedora-review --no-colors --prebuilt --rpm-spec --name python-interface-meta --mock-config /var/lib/copr-rpmbuild/results/configs/child.cfg
Buildroot used: fedora-rawhide-x86_64
Active plugins: Shell-api, Python, Generic
Disabled plugins: Java, SugarActivity, fonts, Perl, PHP, C/C++, Haskell, Ocaml, R

Comment 4 Sandro 2022-11-04 13:03:32 UTC
(In reply to Sandro from comment #3)
> Issues:
> =======
> One minor nitpick: Since you have tests conditionalized, I would suggest the
> following in %check:
> %if %{with tests}
> %{pytest}
> %else
> %pyproject_import_test
> %endif

Sorry the correct macro is %pyproject_check_import

Comment 5 Ankur Sinha (FranciscoD) 2022-11-04 14:09:48 UTC
Thanks very much again, Sandro.

I've removed the conditional entirely. It was just there from the spec template that I use---mostly for packages that sometimes need networking for tests. No need for it here.

Updated spec/srpm:

Spec URL:

Requesting SCM now.

Comment 6 Gwyn Ciesla 2022-11-04 14:49:44 UTC
(fedscm-admin):  The Pagure repository was created at

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