Bug 2432345 - python-beartype fails to build with Python 3.15: ImportError: cannot import name 'no_type_check_decorator' from 'typing'
Summary: python-beartype fails to build with Python 3.15: ImportError: cannot import n...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: python-beartype
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Paul Wouters
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3.15
TreeView+ depends on / blocked
 
Reported: 2026-01-23 12:28 UTC by Karolina Surma
Modified: 2026-01-23 12:28 UTC (History)
6 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Karolina Surma 2026-01-23 12:28:53 UTC
python-beartype fails to build with Python 3.15.0a5.

Traceback
=========

      File "/usr/lib/python3.15/site-packages/sphinx/config.py", line 616, in eval_config_file
        raise ConfigError(msg % traceback.format_exc()) from exc
    sphinx.errors.ConfigError: There is a programmable error in your configuration file:
    
    Traceback (most recent call last):
      File "/usr/lib/python3.15/site-packages/sphinx/config.py", line 601, in eval_config_file
        exec(code, namespace)  # NoQA: S102
        ~~~~^^^^^^^^^^^^^^^^^
      File "/builddir/build/BUILD/python-beartype-0.21.0_20240712gita3a0fff-build/beartype-a3a0fff60e4549bf5bbd1d8209458efdf9035747/doc/src/conf.py", line 84, in <module>
        from beartype.meta import (
        ...<12 lines>...
        )
      File "/builddir/build/BUILD/python-beartype-0.21.0_20240712gita3a0fff-build/beartype-a3a0fff60e4549bf5bbd1d8209458efdf9035747/beartype/__init__.py", line 150, in <module>
        _init()
        ~~~~~^^
      File "/builddir/build/BUILD/python-beartype-0.21.0_20240712gita3a0fff-build/beartype-a3a0fff60e4549bf5bbd1d8209458efdf9035747/beartype/__init__.py", line 71, in _init
        from beartype.meta import (
        ...<4 lines>...
        )
      File "/builddir/build/BUILD/python-beartype-0.21.0_20240712gita3a0fff-build/beartype-a3a0fff60e4549bf5bbd1d8209458efdf9035747/beartype/meta.py", line 33, in <module>
        from beartype._util.text.utiltextversion import (
            convert_str_version_to_tuple as _convert_str_version_to_tuple)
      File "/builddir/build/BUILD/python-beartype-0.21.0_20240712gita3a0fff-build/beartype-a3a0fff60e4549bf5bbd1d8209458efdf9035747/beartype/_util/text/utiltextversion.py", line 15, in <module>
        from beartype.typing import Tuple
      File "/builddir/build/BUILD/python-beartype-0.21.0_20240712gita3a0fff-build/beartype-a3a0fff60e4549bf5bbd1d8209458efdf9035747/beartype/typing/__init__.py", line 161, in <module>
        from typing import (
        ...<28 lines>...
        )
    ImportError: cannot import name 'no_type_check_decorator' from 'typing' (/usr/lib64/python3.15/typing.py)

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

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.15/fedora-rawhide-x86_64/10038492-python-beartype/

For all our attempts to build python-beartype with Python 3.15, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.15/package/python-beartype/

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

Let us know here if you have any questions.

Python 3.15 is planned to be included in Fedora 45.
To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.15.
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.


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