Bug 1302744 - Review Request: python-resumable-urlretrieve - Small library to fetch files over HTTP and resuming their download
Summary: Review Request: python-resumable-urlretrieve - Small library to fetch files o...
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Haïkel Guémar
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1385223
Blocks: 1385237
TreeView+ depends on / blocked
 
Reported: 2016-01-28 14:05 UTC by Mathieu Bridon
Modified: 2017-01-15 21:40 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2017-01-15 21:40:40 UTC
Type: ---
Embargoed:
karlthered: fedora-review+


Attachments (Terms of Use)

Description Mathieu Bridon 2016-01-28 14:05:29 UTC
Spec URL: https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve.spen
SRPM URL: https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve-0.1.1-1.fc23.src.rpm

Description:
Small library to fetch files over HTTP and resuming their download.

Fedora Account System Username: bochecha

Comment 1 Mathieu Bridon 2016-01-28 14:11:01 UTC
As hguemar found on IRC, the Spec URL had a typo, here's the correct info.

---

Spec URL:
https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve.spec
SRPM URL:
https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve-0.1.1-1.fc23.src.rpm

Description:
Small library to fetch files over HTTP and resuming their download.

Fedora Account System Username: bochecha

Comment 2 Mathieu Bridon 2016-01-28 14:57:47 UTC
hguemar found we seem to be missing a few requirements here, the requirements.txt file contains:

  requests==2.7.0
  py==1.4.30
  pytest==2.7.3
  https://github.com/danvk/RangeHTTPServer/tarball/ebb5c5d7af44b3279bdd4b57ddf3093eec3e8794#egg=rangehttpserver
  https://github.com/JukkaL/mypy/tarball/dcff596be878798fbd43af7b50d95c3eed7ebbc1#egg=mypy-lang

The first one, requests, is already a Requires/BuildRequires in the spec file, though I didn't specify the version.

The next one, py, is not used at all. It is a dependency of pytest though, which makes me think this requirements.txt file was generated with "pip freeze", rather than carefully curated by the author. Which means the versioned dependencies are probably "whatever was in the virtualenv" rather that trueliy required versions.

The next one, pytest, is required for the unit tests. As such, I should definitely add it as a BuildRequires.

And the last one, mypy, is the typing thing from Python 3.5, for older Python versions. Since I'm only planning on pushing this package in Rawhide, which has Python 3.5, then this dependency is unnecessary.

Finally, there is the case of rangehttpserver, which is required for the tests, and therefore should be a BuildRequires.

In summary, I need to add to this package:

  BuildRequires: python3-pytest
  BuildRequires: python3-rangehttpserver

And then change %check to be:

  %check
  py.test-3

I'm going to submit a new Spec/SRPM that does just that.

Unfortunately, rangehttpserver isn't in Fedora yet, so I'll need to submit a new review request for it.

And in addition, it is not compatible with Python 3 yet: https://github.com/danvk/RangeHTTPServer/pull/12

So I guess we can leave this review request for the time being, until I get it all settled.

Sorry for the trouble, and thanks hguemar for the quick comments on IRC!

Comment 3 Mathieu Bridon 2016-10-15 13:48:59 UTC
Here's a new version of the package for review, now that python-rangehttpserver has been approved.

Spec URL:
https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve.spec
SRPM URL:
https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve-0.1.2-1.fc24.src.rpm

Comment 4 Haïkel Guémar 2016-12-06 17:10:44 UTC
Tests fails in mock as it tries to bind a socket already in use, if you silence them, build's ok. 
Failing test is test_norange

Comment 5 Haïkel Guémar 2016-12-06 17:16:26 UTC
Used port is PORT + 1, so 8001 according code.
8001 is used on my local machine by weechat but it'd better to randomize port (and check if it's unused before running tests)

Comment 6 Mathieu Bridon 2016-12-12 10:51:03 UTC
Port is now randomized in the latest upstream release, here's the new package.

Spec URL:
https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve.spec
SRPM URL:
https://bochecha.fedorapeople.org/packages/python-resumable-urlretrieve-0.1.3-1.fc24.src.rpm

Comment 7 Haïkel Guémar 2017-01-11 16:02:55 UTC
Please request upstream to add license file in tarball for next releases.
Package approved.



Package Review
==============

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



===== 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]: 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]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "Unknown or generated". 15 files have unknown license. Detailed
     output of licensecheck in /home/hguemar/1302744-python-resumable-
     urlretrieve/licensecheck.txt
[x]: Package requires other packages for directories it uses.
     Note: No known owner of /usr/lib/python3.6/site-packages,
     /usr/lib/python3.6
[x]: Package must own all directories that it creates.
     Note: Directories without known owners: /usr/lib/python3.6/site-
     packages, /usr/lib/python3.6
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[x]: Macros in Summary, %description expandable at SRPM build time.
     Note: Macros in: python3-resumable-urlretrieve (description)
[-]: 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.
[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 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]: 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]: 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

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
[x]: Package contains BR: python2-devel or python3-devel
[x]: Binary eggs must be removed in %prep

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

Generic:
[-]: 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).
[x]: 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]: 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]: 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 =====

Generic:
[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).
[x]: Spec file according to URL is the same as in SRPM.


Rpmlint
-------
Checking: python3-resumable-urlretrieve-0.1.3-1.fc26.noarch.rpm
          python-resumable-urlretrieve-0.1.3-1.fc26.src.rpm
python3-resumable-urlretrieve.noarch: W: unexpanded-macro %description -l C %{description}
python3-resumable-urlretrieve.noarch: W: no-documentation
python3-resumable-urlretrieve.noarch: E: python-bytecode-wrong-magic-value /usr/lib/python3.6/site-packages/resumable/__pycache__/__init__.cpython-36.opt-1.pyc expected 3361 (3.6), found 3379 (unknown)
python3-resumable-urlretrieve.noarch: E: python-bytecode-wrong-magic-value /usr/lib/python3.6/site-packages/resumable/__pycache__/__init__.cpython-36.pyc expected 3361 (3.6), found 3379 (unknown)
2 packages and 0 specfiles checked; 2 errors, 2 warnings.




Rpmlint (installed packages)
----------------------------
sh: /usr/bin/python: No such file or directory
python3-resumable-urlretrieve.noarch: W: unexpanded-macro %description -l C %{description}
python3-resumable-urlretrieve.noarch: W: no-documentation
1 packages and 0 specfiles checked; 0 errors, 2 warnings.



Requires
--------
python3-resumable-urlretrieve (rpmlib, GLIBC filtered):
    python(abi)
    python3-requests



Provides
--------
python3-resumable-urlretrieve:
    python3-resumable-urlretrieve
    python3.6dist(resumable-urlretrieve)
    python3dist(resumable-urlretrieve)



Source checksums
----------------
https://files.pythonhosted.org/packages/source/r/resumable-urlretrieve/resumable-urlretrieve-0.1.3.tar.gz :
  CHECKSUM(SHA256) this package     : d5154bbc02c88a401496294adfc82c003516ccbe51df69bcdadcc7d7190ff44e
  CHECKSUM(SHA256) upstream package : d5154bbc02c88a401496294adfc82c003516ccbe51df69bcdadcc7d7190ff44e


Generated by fedora-review 0.6.1 (f03e4e7) last change: 2016-05-02
Command line :/usr/bin/fedora-review -b 1302744 -m fedora-rawhide-x86_64
Buildroot used: fedora-rawhide-x86_64
Active plugins: Python, Generic, Shell-api
Disabled plugins: Java, C/C++, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP
Disabled flags: EXARCH, DISTTAG, EPEL5, BATCH, EPEL6

Comment 8 Gwyn Ciesla 2017-01-15 19:22:24 UTC
Package request has been approved: https://admin.fedoraproject.org/pkgdb/package/rpms/python-resumable-urlretrieve

Comment 9 Mathieu Bridon 2017-01-15 21:40:40 UTC
Package built in Rawhide and Fedora 25, closing.

Thanks Haikel for the review, and Jon for the admin process!


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