Bug 1721083

Summary: python-biopython fails to build with Python 3.8
Product: [Fedora] Fedora Reporter: Miro Hrončok <mhroncok>
Component: python-biopythonAssignee: Antonio T. (sagitter) <anto.trande>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: rawhideCC: alex, anto.trande, bazanluis20, dominik, jaruga, neuro-sig, tir.karthi
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-21 17:28:41 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: 1686977    

Description Miro Hrončok 2019-06-17 10:01:35 UTC
python-biopython 1.73-4 fails to build with Python 3.8.0b1:

+ export PYTHONPATH=/builddir/build/BUILDROOT/python-biopython-1.73-4.fc31.x86_64/usr/lib64/python3.8/site-packages
+ PYTHONPATH=/builddir/build/BUILDROOT/python-biopython-1.73-4.fc31.x86_64/usr/lib64/python3.8/site-packages
+ /usr/bin/python3 run_tests.py --offline -v test_Ace.py
test_Ace ... ok
test_check_ACEParser (test_Ace.AceTestOne)
Test to check that ACEParser can parse the whole file into one record. ... ok
test_check_record_parser (test_Ace.AceTestOne)
Test to check that contig parser parses each contig into a contig. ... ok
test_check_ACEParser (test_Ace.AceTestThree)
Test to check that ACEParser can parse the whole file into one record. ... ok
test_check_record_parser (test_Ace.AceTestThree)
Test to check that record parser parses each contig into a record. ... ok
test_check_ACEParser (test_Ace.AceTestTwo)
Test to check that ACEParser can parse the whole file into one record. ... ok
test_check_record_parser (test_Ace.AceTestTwo)
Test to check that record parser parses each contig into a record. ... ok
----------------------------------------------------------------------
Ran 1 test in 0.106 seconds

+ for test in `ls test_*.py | grep -v Nexus | grep -v Phylo | grep -v Tutorial | grep -v bgzf | grep -v SearchIO_blast`
+ echo C
+ export PYTHONPATH=/builddir/build/BUILDROOT/python-biopython-1.73-4.fc31.x86_64/usr/lib64/python3.8/site-packages
+ PYTHONPATH=/builddir/build/BUILDROOT/python-biopython-1.73-4.fc31.x86_64/usr/lib64/python3.8/site-packages
+ /usr/bin/python3 run_tests.py --offline -v test_Affy.py
test_Affy ... FAIL
testAffy3 (test_Affy.AffyTest) ... ok
testAffy3Backwards (test_Affy.AffyTest) ... ok
testAffy4 (test_Affy.AffyTest) ... ok
testAffyBadHeader (test_Affy.AffyTest) ... ok
testAffyStrict (test_Affy.AffyTest) ... ok
testAffyWrongModeRead (test_Affy.AffyTest) ... ERROR
testAffyWrongModeReadV4 (test_Affy.AffyTest) ... ERROR

======================================================================
ERROR: testAffyWrongModeRead (test_Affy.AffyTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/python-biopython-1.73/python3/Tests/test_Affy.py", line 117, in testAffyWrongModeRead
    record = CelFile.read(f)
  File "/builddir/build/BUILD/python-biopython-1.73/python3/build/lib.linux-x86_64-3.8/Bio/Affy/CelFile.py", line 136, in read
    return read_v3(handle)
  File "/builddir/build/BUILD/python-biopython-1.73/python3/build/lib.linux-x86_64-3.8/Bio/Affy/CelFile.py", line 303, in read_v3
    for line in handle:
  File "/usr/lib64/python3.8/codecs.py", line 322, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf0 in position 0: invalid continuation byte

======================================================================
ERROR: testAffyWrongModeReadV4 (test_Affy.AffyTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/python-biopython-1.73/python3/Tests/test_Affy.py", line 105, in testAffyWrongModeReadV4
    record = CelFile.read_v4(f)
  File "/builddir/build/BUILD/python-biopython-1.73/python3/build/lib.linux-x86_64-3.8/Bio/Affy/CelFile.py", line 173, in read_v4
    preHeadersMap[name] = struct.unpack("<i", f.read(4))[0]
TypeError: a bytes-like object is required, not 'str'

----------------------------------------------------------------------
Ran 1 test in 0.020 seconds

FAILED (failures = 1)
~/build/BUILD/python-biopython-1.73/python3/Tests ~/build/BUILD/python-biopython-1.73
C
Skipping any tests requiring internet access
Python version: 3.8.0b1 (default, Jun  5 2019, 08:48:48) 
[GCC 9.1.1 20190503 (Red Hat 9.1.1-1)]
Operating system: posix linux
C
Skipping any tests requiring internet access
Python version: 3.8.0b1 (default, Jun  5 2019, 08:48:48) 
[GCC 9.1.1 20190503 (Red Hat 9.1.1-1)]
Operating system: posix linux


RPM build errors:
error: Bad exit status from /var/tmp/rpm-tmp.twlsXs (%check)


Full logs from our last attempt:

https://copr-be.cloud.fedoraproject.org/results/@python/python3.8/fedora-rawhide-x86_64/00936556-python-biopython/

All attempts:

https://copr.fedorainfracloud.org/coprs/g/python/python3.8/package/python-biopython/

Comment 1 Karthikeyan Singaravelan 2019-06-29 16:37:45 UTC
I am not sure if it's related but there was codec related regression fixed in 3.8 and 3.7 in https://bugs.python.org/issue24214. Does this help in solving the test case failure?

Comment 2 Miro Hrončok 2019-07-15 09:38:46 UTC
Luis?

Comment 3 Antonio T. (sagitter) 2019-07-15 20:38:36 UTC
I have disabled all failed tests with Python-3.8 on Rawhide.
I cannot do more now.

Comment 4 Ben Cotton 2019-08-13 16:49:28 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle.
Changing version to '31'.

Comment 5 Miro Hrončok 2019-08-14 22:24:41 UTC
The coordinated rebuild of Python 3.8 has started in the `f32-python` side tag.

If you figure out how to rebuild this package, please don't rebuild it in regular rawhide, but use the side tag instead:

    on branch master:
    $ fedpkg build --target=f32-python

To wait for a build to show up in the side tag, do:

    $ koji wait-repo f32-python --build=<nvr>

Where <nvr> is name-version-release of the source package, e.g. python-foo-1.1-2.fc32.

An updated mock config is posted at:
http://copr.fedorainfracloud.org/coprs/g/python/python3.8/

Note that it will take a while before the essential packages are rebuilt, so don't expect all your dependencies to be available right away.

Thanks. Let us know if you need up to date info, or if you have any questions.



PS this message is mass posted to all the bugs that block the PYTHON38 bug. If this is also a Fedora 31 FTBFS bug and you manage to fix it, you can do a f31 build as usual:

    on branch f31:
    $ fedpkg build

Comment 6 Miro Hrončok 2019-08-21 16:35:25 UTC
The f32-python side tag has been merged. In order to rebuild the package, do it in regular rawhide, but please wait until python3-3.8 is tagged:

  $ koji wait-repo f32-build --build python3-3.8.0~b3-3.fc32


If your built already started in f32-python, after it is finished, please tag it to rawhide with:

  $ koji tag-build f32-pending <nvr>

For example:

  $ koji tag-build f32-pending libreoffice-6.3.0.4-3.fc32

Thanks!

(This comment is mass posted to all bugzillas blocking the PYTHON38 tracking bug.)

Comment 7 Miro Hrončok 2019-08-21 17:29:26 UTC
(Python 3.8 has landed in the rawhide buildroot.)