Bug 1914333

Summary: python-pint: FTBFS in Fedora rawhide: ValueError: invalid version number '1.20.0rc2' (numpy version)
Product: [Fedora] Fedora Reporter: Tomáš Hrnčiar <thrnciar>
Component: python-pintAssignee: Matthias Runge <mrunge>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: mhroncok, mrunge
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
URL: https://koschei.fedoraproject.org/package/python-pint
Whiteboard:
Fixed In Version: python-pint-0.16.1-2.fc34 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-01-25 07:38:44 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1868278, 1890881    

Description Tomáš Hrnčiar 2021-01-08 15:36:52 UTC
Description of problem:
Package python-pint fails to build from source in Fedora rawhide.

Version-Release number of selected component (if applicable):
0.16-1.fc34~bootstrap

Steps to Reproduce:
koji build --scratch f34 python-pint-0.16-1.fc34~bootstrap.src.rpm

Additional info:
This package is tracked by Koschei. See:
https://koschei.fedoraproject.org/package/python-pint

==================================== ERRORS ====================================
_______________ ERROR collecting pint/testsuite/test_quantity.py _______________
pint/testsuite/test_quantity.py:1032: in <module>
    class TestOffsetUnitMath(QuantityTestCase, ParameterizedTestCase):
pint/testsuite/test_quantity.py:1544: in TestOffsetUnitMath
    ???
pint/testsuite/helpers.py:45: in requires_numpy_at_least
    StrictVersion(NUMPY_VER) >= StrictVersion(version),
/usr/lib64/python3.10/distutils/version.py:40: in __init__
    self.parse(vstring)
/usr/lib64/python3.10/distutils/version.py:137: in parse
    raise ValueError("invalid version number '%s'" % vstring)
E   ValueError: invalid version number '1.20.0rc2'
=========================== short test summary info ============================
ERROR pint/testsuite/test_quantity.py - ValueError: invalid version number '1...
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
========================= 3 skipped, 1 error in 3.07s ==========================

Comment 1 Miro Hrončok 2021-01-08 16:03:26 UTC
It is the version of numpy. StrictVersion cannot parse rc versions:
                                                                                                                                                                                                        
Init signature: StrictVersion(vstring=None)
Docstring:     
Version numbering for anal retentives and software idealists.
Implements the standard interface for version number classes as
described above.  A version number consists of two or three
dot-separated numeric components, with an optional "pre-release" tag
on the end.  The pre-release tag consists of the letter 'a' or 'b'
followed by a number.  If the numeric components of two version
numbers are equal, then one with a pre-release tag will always
be deemed earlier (lesser) than one without.

The following are valid version numbers (shown in the order that
would be obtained by sorting according to the supplied cmp function):

    0.4       0.4.0  (these two are equivalent)
    0.4.1
    0.5a1
    0.5b3
    0.5
    0.9.6
    1.0
    1.0.4a3
    1.0.4b1
    1.0.4

The following are examples of invalid version numbers:

    1
    2.7.2.2
    1.3.a4
    1.3pl1
    1.3c4

The rationale for this version numbering system will be explained
in the distutils documentation.

Comment 2 Miro Hrončok 2021-01-08 16:05:36 UTC
A fix: https://github.com/hgrecco/pint/pull/1226

Comment 3 Fedora Release Engineering 2021-01-24 04:22:44 UTC
Dear Maintainer,

your package has an open Fails To Build From Source bug for Fedora 34.
Action is required from you.

If you can fix your package to build, perform a build in koji, and either create
an update in bodhi, or close this bug without creating an update, if updating is
not appropriate [1]. If you are working on a fix, set the status to ASSIGNED to
acknowledge this. If you have already fixed this issue, please close this Bugzilla report.

Following the policy for such packages [2], your package will be orphaned if
this bug remains in NEW state more than 8 weeks (not sooner than 2021-03-05).

A week before the mass branching of Fedora 35 according to the schedule [3],
any packages not successfully rebuilt at least on Fedora 33 will be
retired regardless of the status of this bug.

[1] https://docs.fedoraproject.org/en-US/fesco/Updates_Policy/
[2] https://docs.fedoraproject.org/en-US/fesco/Fails_to_build_from_source_Fails_to_install/
[3] https://fedorapeople.org/groups/schedule/f-35/f-35-key-tasks.html

Comment 4 Matthias Runge 2021-01-25 07:38:44 UTC
built 0.16.1 for rawhide.