Bug 2290563 - python-opentelemetry fails to build with Python 3.13: AssertionError: 'File "/builddir/build/BUILD/python-opente[135 chars]rror' != 'raise ZeroDivisionError()'
Summary: python-opentelemetry fails to build with Python 3.13: AssertionError: 'File "...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: python-opentelemetry
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Ben Beasley
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3.13
TreeView+ depends on / blocked
 
Reported: 2024-06-05 14:51 UTC by Karolina Surma
Modified: 2024-06-05 18:11 UTC (History)
6 users (show)

Fixed In Version: python-opentelemetry-1.25.0-2.fc41
Clone Of:
Environment:
Last Closed: 2024-06-05 18:11:22 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github open-telemetry opentelemetry-python issues 3953 0 None open Python 3.13: Test regression in opentelemetry-test-utils 2024-06-05 17:35:29 UTC

Description Karolina Surma 2024-06-05 14:51:38 UTC
python-opentelemetry fails to build with Python 3.13.0b1.
=================================== FAILURES ===================================
__________________ TestAssertNotRaises.test_missing_exception __________________

self = <tests.test_utils.TestAssertNotRaises testMethod=test_missing_exception>

    def test_missing_exception(self):
    
        with self.assertRaises(AssertionError) as error:
    
            with self.assertNotRaises(ZeroDivisionError):
    
                def raise_zero_division_error():
                    raise ZeroDivisionError()
    
                raise_zero_division_error()
    
        error_lines = error.exception.args[0].split("\n")
    
        self.assertEqual(
            error_lines[0].strip(), "Unexpected exception was raised:"
        )
        self.assertEqual(error_lines[2].strip(), "raise_zero_division_error()")
>       self.assertEqual(error_lines[5].strip(), "raise ZeroDivisionError()")
E       AssertionError: 'File "/builddir/build/BUILD/python-opente[135 chars]rror' != 'raise ZeroDivisionError()'
E       - File "/builddir/build/BUILD/python-opentelemetry-1.25.0-build/opentelemetry-python-1.25.0/tests/opentelemetry-test-utils/tests/test_utils.py", line 72, in raise_zero_division_error
E       + raise ZeroDivisionError()

tests/opentelemetry-test-utils/tests/test_utils.py:82: AssertionError
========================= 1 failed, 4 passed in 0.11s ==========================

https://docs.python.org/3.13/whatsnew/3.13.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.13-b1/fedora-rawhide-x86_64/07532309-python-opentelemetry/

For all our attempts to build python-opentelemetry with Python 3.13, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.13-b1/package/python-opentelemetry/

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.13:
https://copr.fedorainfracloud.org/coprs/g/python/python3.13-b1/

Let us know here if you have any questions.

Python 3.13 is planned to be included in Fedora 41.
To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.13.
A build failure prevents us from testing all dependent packages (transitive [Build]Requires),
so if this package is required a lot, it's important for us to get it fixed soon.

We'd appreciate help from the people who know this package best,
but if you don't want to work on this now, let us know so we can try to work around it on our side.

Comment 1 Ben Beasley 2024-06-05 17:00:01 UTC
> E       AssertionError: 'File "/builddir/build/BUILD/python-opente[135 chars]rror' != 'raise ZeroDivisionError()'

That is very weird. It looks as if output from multiple threads or processes was interleaved. I’ll investigate.

Comment 2 Ben Beasley 2024-06-05 17:35:29 UTC
I’ve reported this upstream in https://github.com/open-telemetry/opentelemetry-python/issues/3953, and I’m just going to consider this a testing issue and skip the one affected test.

Comment 3 Fedora Update System 2024-06-05 18:07:54 UTC
FEDORA-2024-4c7382551b (python-opentelemetry-1.25.0-2.fc41) has been submitted as an update to Fedora 41.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-4c7382551b

Comment 4 Fedora Update System 2024-06-05 18:11:22 UTC
FEDORA-2024-4c7382551b (python-opentelemetry-1.25.0-2.fc41) has been pushed to the Fedora 41 stable repository.
If problem still persists, please make note of it in this bug report.


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