Bug 1511554

Summary: Review Request: python-cypari2 - A Python interface to the number theory library pari
Product: [Fedora] Fedora Reporter: Paulo Andrade <paulo.cesar.pereira.de.andrade>
Component: Package ReviewAssignee: Robert-André Mauchin 🐧 <eclipseo>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: eclipseo, package-review, rebus
Target Milestone: ---Flags: eclipseo: fedora-review+
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-06-22 17:48:00 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Paulo Andrade 2017-11-09 14:50:01 UTC
Spec URL: https://pcpa.fedorapeople.org/python-cypari2.spec
SRPM URL: https://pcpa.fedorapeople.org/python-cypari2-1.0.0-1.fc28.src.rpm
Description: A Python interface to the number theory library pari.
Fedora Account System Username: pcpa

Comment 1 Robert-André Mauchin 🐧 2017-11-09 17:21:02 UTC
Hello,

 - Please use a more meaningful name for the archive, with:

Source0:	https://github.com/defeo/%{modname}/archive/%{version}/%{modname}-%{version}.tar.gz

 - Please package the latest version, currently 1.1.3: https://github.com/defeo/cypari2/releases/tag/1.1.3 Note that README.md has been replaced by README.rst, don't forget to update this in %files.

Package is fine otherwise, just fix the aforementioned points and it will be accepted.

Comment 2 Paulo Andrade 2017-11-09 18:25:51 UTC
Hi, many thanks for the initial review.

At first I would prefer keep version 1.0.0 because it is the version
used by sagemath 8.0. But after testing, later version should work with
sagemath 8.0.

I changed the Source line, but it will cause fedora-review to not be able
to download and validate it, other automated tools may also have trouble
with it.

Later version has documentation and self tests. Now added doc subpackage
and %check section.

Update:

Spec URL: https://pcpa.fedorapeople.org/python-cypari2.spec
SRPM URL: https://pcpa.fedorapeople.org/python-cypari2-1.1.3-1.fc28.src.rpm

Comment 3 Robert-André Mauchin 🐧 2017-11-09 19:52:50 UTC
>but it will cause fedora-review to not be able to download and validate it

No, it works fine. That is if you actually put the correct URL, which you didn't do:

Source0:	https://github.com/defeo/%{modname}/archive/%{version}/%{modname}-%{version}.tar.gz


The tests you've added don't work for me:

  File "tests/rundoctest.py", line 11, in <module>
    import cypari2
  File "/builddir/build/BUILDROOT/python-cypari2-1.1.3-1.fc28.x86_64/usr/lib64/python2.7/site-packages/cypari2/__init__.py", line 1, in <module>
    from .pari_instance import Pari
ImportError: /builddir/build/BUILDROOT/python-cypari2-1.1.3-1.fc28.x86_64/usr/lib64/python2.7/site-packages/cypari2/pari_instance.so: undefined symbol: sig_off
RPM build errors:
error: Bad exit status from /var/tmp/rpm-tmp.mUMhJO (%check)
    Bad exit status from /var/tmp/rpm-tmp.mUMhJO (%check)
Child return code was: 1

Comment 4 Paulo Andrade 2017-11-09 20:03:55 UTC
  Ops,

  Thanks for noting my error in the URL (s/name/modname/).

  I also forgot that to generate docs and run check, need to update
to a newer python-cysignals.

  If you want to check it I can upload the python-cysignals srpm.

  I am delaying it for a batch of required updates, before building
sagemath 8.0.

Update:

- Correct Source URL
- Temporarily disable doc and check as need to update cysignals

Spec URL: https://pcpa.fedorapeople.org/python-cypari2.spec
SRPM URL: https://pcpa.fedorapeople.org/python-cypari2-1.1.3-2.fc28.src.rpm

Comment 5 Robert-André Mauchin 🐧 2017-11-09 20:17:26 UTC
> If you want to check it I can upload the python-cysignals srpm.

Can't you just build it on Koji? Or link me to a scratch build of it so I can snatch the RPMs.

Comment 6 Paulo Andrade 2017-11-09 22:51:53 UTC
I prefer to not build a final package in koji as it may take significant
time to get all bits in place to build a newer sagemath, so, I prefer
to avoid an inconsistent state.

Scratch build of newer python-cysignals at:

https://koji.fedoraproject.org/koji/taskinfo?taskID=23026237

Updated package to build requires correct version, generate
doc subpackage and run %check:

Spec URL: https://pcpa.fedorapeople.org/python-cypari2.spec
SRPM URL: https://pcpa.fedorapeople.org/python-cypari2-1.1.3-3.fc28.src.rpm

Comment 7 Robert-André Mauchin 🐧 2017-11-09 23:35:41 UTC
Test fails:

File "/builddir/build/BUILDROOT/python-cypari2-1.1.3-3.fc28.x86_64/usr/lib64/python3.6/site-packages/cypari2/gen.cpython-36m-x86_64-linux-gnu.so", line ?, in cypari2.gen.__test__.list_of_Gens_to_Gen (line 4861)
Failed example:
    from six.moves import range
Exception raised:
    Traceback (most recent call last):
      File "/usr/lib64/python3.6/doctest.py", line 1330, in __run
        compileflags, 1), test.globs)
      File "<doctest cypari2.gen.__test__.list_of_Gens_to_Gen (line 4861)[0]>", line 1, in <module>
        from six.moves import range
    ModuleNotFoundError: No module named 'six'

Guess you need to add a BR to python-six.

I'll finish this tomorrow if you don't mind.

Comment 8 Paulo Andrade 2017-11-10 12:22:47 UTC
Fully verified, and indeed only python{2,3}-six BR were required.

Spec URL: https://pcpa.fedorapeople.org/python-cypari2.spec
SRPM URL: https://pcpa.fedorapeople.org/python-cypari2-1.1.3-4.fc28.src.rpm

Comment 9 Robert-André Mauchin 🐧 2017-11-10 12:57:41 UTC
All ok, package accepted.

Comment 10 Paulo Andrade 2017-11-10 13:15:28 UTC
Many thanks for the review!

Comment 11 Gwyn Ciesla 2017-11-10 14:24:46 UTC
(fedrepo-req-admin):  The Pagure repository was created at https://src.fedoraproject.org/rpms/python-cypari2. You may commit to the branch "f27" in about 10 minutes.

Comment 12 Paulo Andrade 2017-11-10 19:07:55 UTC
There was an a crash on 32 bit builds during %check, but the problem
would happen on 64 bit as well, just not crash.
Reported, with patch, at https://github.com/defeo/cypari2/issues/46

Comment 13 Michal Ambroz 2018-06-22 17:48:00 UTC
Pacgake already present in 28 so review can be probably closed.