Bug 1275057 - Review Request: python-appstream - Parse AppStream files when you don't have libappstream-glib
Summary: Review Request: python-appstream - Parse AppStream files when you don't have ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: William Moreno
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-10-25 13:12 UTC by Ralph Bean
Modified: 2015-11-23 20:57 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-23 20:57:17 UTC
Type: ---
Embargoed:
williamjmorenor: fedora-review+


Attachments (Terms of Use)

Description Ralph Bean 2015-10-25 13:12:02 UTC
Spec URL: http://ralph.fedorapeople.org//python-appstream.spec
SRPM URL: http://ralph.fedorapeople.org//python-appstream-0.2-1.fc22.src.rpm

Description:
If you want to parse AppStream files in Python you probably should
just install libappstream-glib, and use the GObjectIntrospection bindings
for that. AppStreamGlib is a much better library than this and handles
many more kinds of component.

If AppStreamGlib is not available to you (e.g. you're trying to run in an
OpenShift instance on RHEL 6.2), this project might be somewhat useful.

Comment 1 Ralph Bean 2015-10-25 13:12:07 UTC
This package built on koji:  http://koji.fedoraproject.org/koji/taskinfo?taskID=11577332

Comment 2 Ralph Bean 2015-10-25 13:22:44 UTC
I only intend to build this for epel-6 and the 0.2 release from upstream has problems on python-2.7 (so, any Fedora release).  For whoever reviews this, you'll need to use an el6 buildroot.

Comment 3 Upstream Release Monitoring 2015-10-26 13:37:11 UTC
ralph's scratch build of python-appstream-0.3-1.fc22.src.rpm for el6-candidate completed http://koji.fedoraproject.org/koji/taskinfo?taskID=11582265

Comment 4 Ralph Bean 2015-10-26 13:38:25 UTC
Latest upstream, which builds for both rawhide and epel6:

Spec URL: http://threebean.org/rpm/SPECS/python-appstream.spec
SRPM URL: http://threebean.org/rpm/SRPMS/python-appstream-0.3-1.fc22.src.rpm

Comment 5 Ralph Bean 2015-10-29 18:38:23 UTC
Latest upstream, with some bugfixes:

Spec URL: http://threebean.org/rpm/SPECS/python-appstream.spec
SRPM URL: http://threebean.org/rpm/SRPMS/python-appstream-0.5-1.fc22.src.rpm

Comment 6 Upstream Release Monitoring 2015-10-29 18:55:33 UTC
williamjmorenor's scratch build of python-appstream-0.5-1.fc22.src.rpm for rawhide completed http://koji.fedoraproject.org/koji/taskinfo?taskID=11630504

Comment 7 William Moreno 2015-10-29 21:42:35 UTC
This package it is only for epel6? Or you are goint to build for Fedora and Epel7?

It may be usefull in Fedora, but Python Packaging Guidelines for Fedora have changed a lot from epel6.

If you are to build for Fedora at less consider:

1- Use the $%license macro and define it in %%files for epel6 with:
%{!?_licensedir:%global license %%doc}
%license LICENSE

2- Use a %if 0%{?fedora} conditional to build a python2-appstream and use the python-provides macro.

3- In %%files use a %if 0%{?rhel} && 0%{?rhel} <= 6 to create the python-appstream rpm and use a %if 0%{?fedora} to create the python2-appstream rpm.

In the other hand this spec build fine in epel6 but fails in the others build.

http://copr.fedoraproject.org/coprs/williamjmorenor/fedora-review-test/build/131404/

Comment 8 William Moreno 2015-10-29 21:46:11 UTC
Epel7 and Fedora Builds all then fails in %%chech with python2.7 the check pass fine with python2.6 in epel6, will yoo go only for epel6?

Comment 9 William Moreno 2015-10-29 21:58:00 UTC
Sorry for the last to comments, I was looking at the 0.2 version.

I am working with the 0.5 versión but now the epel6 fails in check:
http://copr.fedoraproject.org/coprs/williamjmorenor/fedora-review-test/build/131408/

The problem is with %%check again:
+ python test.py
Traceback (most recent call last):
  File "test.py", line 147, in <module>

Comment 10 Ralph Bean 2015-10-30 14:38:15 UTC
Doh!  Good catch.

I do only plan to ship it for epel6.

Upstream recommends that people not use this module when they can instead use appstream-glib (which is available in Fedora and RHEL7).  This lib is just a tool to be used when that better lib is not available (like, on EL6 for instance).

Comment 11 Upstream Release Monitoring 2015-10-30 14:52:47 UTC
ralph's scratch build of python-appstream-0.8-1.fc22.src.rpm for el6-candidate completed http://koji.fedoraproject.org/koji/taskinfo?taskID=11640811

Comment 13 William Moreno 2015-11-03 23:25:51 UTC
OK last package build fine in epel 6 and 7 and all suported Fedoras, I will rerun the review.

http://copr.fedoraproject.org/coprs/williamjmorenor/fedora-review-test/build/132441/

Comment 14 Upstream Release Monitoring 2015-11-03 23:29:51 UTC
williamjmorenor's scratch build of python-appstream-0.8-1.fc22.src.rpm for rawhide completed http://koji.fedoraproject.org/koji/taskinfo?taskID=11692174

Comment 15 William Moreno 2015-11-05 20:46:48 UTC
Package Aproved
================

I am fine whit this packaging for epel6

If you want to package for Fedora and epel 7 you MUST:

1. Use the License Macro
2. Drop python3 conditionals
3. Provide a python2 and python3 subpackage
4. Use the python provides macro

===== MUST items =====
Generic:
[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.
[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
[x]: Package uses nothing in %doc for runtime.
[x]: Package consistently uses macros (instead of hard-coded directory
     names).
[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.
[-]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
[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]: 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]: All build dependencies are listed in BuildRequires, except for any
     that are listed in the exceptions section of Packaging Guidelines.
[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 use %makeinstall only when make install DESTDIR=... doesn't
     work.
[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
     %{name}.spec.
[x]: File names are valid UTF-8.
[x]: Packages must not store files under /srv, /opt or /usr/local

Python:
[x]: Python eggs must not download any dependencies during the build
     process.
[x]: A package which is used by another package via an egg interface should
     provide egg info.
[x]: Package meets the Packaging Guidelines::Python (epel6)
[x]: Package contains BR: python2-devel or python3-devel
[x]: Binary eggs must be removed in %prep

===== SHOULD items =====
Generic:
[X]: 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.
[-]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[x]: Package should compile and build into binary rpms on all supported
     architectures.
[x]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
     files.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[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
     $RPM_BUILD_ROOT)
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

Comment 16 Ralph Bean 2015-11-06 15:13:57 UTC
Thanks William!  I filed the new package request in pkgdb.

Comment 17 Gwyn Ciesla 2015-11-06 15:37:56 UTC
Package request has been approved: https://admin.fedoraproject.org/pkgdb/package/python-appstream

Comment 18 Fedora Update System 2015-11-06 16:04:52 UTC
python-appstream-0.8-1.el6 has been submitted as an update to Fedora EPEL 6. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2015-1211b6095b

Comment 19 Fedora Update System 2015-11-08 18:48:00 UTC
python-appstream-0.8-1.el6 has been pushed to the Fedora EPEL 6 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
$ su -c 'yum --enablerepo=epel-testing update python-appstream'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2015-1211b6095b

Comment 20 Fedora Update System 2015-11-23 20:57:15 UTC
python-appstream-0.8-1.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report.


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