Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1721930 - python-colcon-bundle fails to build with Python 3.8
Summary: python-colcon-bundle fails to build with Python 3.8
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: python-colcon-bundle
Version: rawhide
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Scott K Logan
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON38
TreeView+ depends on / blocked
 
Reported: 2019-06-19 09:21 UTC by Miro Hrončok
Modified: 2019-07-15 23:23 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-07-15 23:23:45 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github colcon colcon-bundle issues 86 0 None None None 2019-07-15 21:36:29 UTC

Description Miro Hrončok 2019-06-19 09:21:07 UTC
python-colcon-bundle fails to build with Python 3.8.0b1.

+ /usr/bin/python3 -m pytest --ignore=test/test_flake8.py test
============================= test session starts ==============================
platform linux -- Python 3.8.0b1, pytest-4.4.1, py-1.8.0, pluggy-0.11.0
rootdir: /builddir/build/BUILD/colcon-bundle-0.0.13, inifile: setup.cfg
collected 17 items

test/test_bundlefile.py F.                                               [ 11%]
test/test_pip3_installer.py ....                                         [ 35%]
test/test_pip_installer.py ....                                          [ 58%]
test/test_python_bundle.py s.                                            [ 70%]
test/test_setup.py .                                                     [ 76%]
test/test_utilities.py ....                                              [100%]

=================================== FAILURES ===================================
________________________ TestBundlefile.test_bundlefile ________________________

self = <test.test_bundlefile.TestBundlefile object at 0x7fca0a535af0>

    def test_bundlefile(self):
        bundle_path = os.path.join(self.tmpdir, 'test.mba')
        json_file = os.path.join(self.tmpdir, 'file')
        with open(json_file, 'w') as f:
            f.write(json.dumps(json_data))
    
        blocksize_file = os.path.join(self.tmpdir, 'blocksize_file')
        with open(blocksize_file, 'wb') as f:
            f.write(bytearray(tarfile.BLOCKSIZE))
    
        large_file = os.path.join(self.tmpdir, 'large_file')
        with open(large_file, 'wb') as f:
            large_file_size = 12 + tarfile.BLOCKSIZE * 1000
            f.write(bytearray(large_file_size))
    
        dep_archive = os.path.join(self.tmpdir, 'dependencies.tar.gz')
        with tarfile.open(dep_archive, 'w:gz') as a:
            a.add(json_file, arcname='file')
    
        other_archive = os.path.join(self.tmpdir, 'other.tar.gz')
        with tarfile.open(other_archive, 'w:gz') as a:
            a.add(json_file, arcname='file2')
    
        with Bundle(name=bundle_path, mode='w') as bundle:
            bundle.add_overlay_archive(dep_archive)
            bundle.add_overlay_archive(other_archive)
            bundle.add_overlay_archive(blocksize_file)
            bundle.add_overlay_archive(large_file)
    
        metadata_path = os.path.join(self.tmpdir, 'metadata.tar.gz')
        with tarfile.open(bundle_path, 'r:') as bundle:
            members = bundle.getmembers()
            assert 'version' == members[0].name
            assert 'metadata.tar.gz' == members[1].name
            assert 'pad' == members[2].name
            assert 'dependencies.tar.gz' == members[3].name
            # Validate the overlays start at 4MB
>           assert 4 * 1024 * 1024 == members[3].offset
E           AssertionError: assert ((4 * 1024) * 1024) == 4195328
E            +  where 4195328 = <TarInfo 'dependencies.tar.gz' at 0x7fca0a511ac0>.offset

test/test_bundlefile.py:60: AssertionError
=============================== warnings summary ===============================
test/test_python_bundle.py::test_bundle
  /usr/lib/python3.8/site-packages/_pytest/python.py:174: PytestWarning: Coroutine functions are not natively supported and have been skipped.
  You need to install a suitable plugin for your async framework, for example:
    - pytest-asyncio
    - pytest-trio
    - pytest-tornasync
    warnings.warn(PytestWarning(msg.format(pyfuncitem.nodeid)))

-- Docs: https://docs.pytest.org/en/latest/warnings.html
========== 1 failed, 15 passed, 1 skipped, 1 warnings in 0.49 seconds ==========

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.8/fedora-rawhide-x86_64/00940840-python-colcon-bundle/

For all our attempts to build python-colcon-bundle with Python 3.8, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.8/package/python-colcon-bundle/

Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.8:
https://copr.fedorainfracloud.org/coprs/g/python/python3.8/

Let us know here if you have any questions.

Comment 1 Karthikeyan Singaravelan 2019-06-28 19:40:56 UTC
This could be due to https://bugs.python.org/issue36268 . The test passes before this change.

Comment 2 Miro Hrončok 2019-07-15 09:42:12 UTC
Let's report upstream and skip the test?

Comment 3 Scott K Logan 2019-07-15 21:35:58 UTC
A ticket was filed for this issue upstream 17 days ago, but it hasn't moved. I pinged the ticket, and I'll skip the test for now.


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