Bug 2293084 - python-hypothesis fails to build with Python 3.13 in Fedora Rawhide (41)
Summary: python-hypothesis fails to build with Python 3.13 in Fedora Rawhide (41)
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: python-hypothesis
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miro Hrončok
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 2265632
Blocks: F41FTBFS PYTHON3.13
TreeView+ depends on / blocked
 
Reported: 2024-06-19 14:35 UTC by Karolina Surma
Modified: 2024-07-02 14:08 UTC (History)
6 users (show)

Fixed In Version: python-hypothesis-6.104.2-2.fc41
Clone Of:
Environment:
Last Closed: 2024-07-02 14:08:36 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Fedora Package Sources python-hypothesis pull-request 25 0 None None None 2024-07-02 11:14:53 UTC

Description Karolina Surma 2024-06-19 14:35:00 UTC
python-hypothesis fails to build with Python 3.13 in Fedora Rawhide (41).

Build failure:

= 10 failed, 5689 passed, 11 skipped, 3 xfailed, 16 errors in 1120.94s (0:18:40) =

All errors are similar:

___ ERROR collecting hypothesis-python/tests/cover/test_filter_rewriting.py ____
Traceback (most recent call last):
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 341, in from_call
    result: Optional[TResult] = func()
                                ~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 372, in <lambda>
    call = CallInfo.from_call(lambda: list(collector.collect()), "collect")
                                           ~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 531, in collect
    self._inject_setup_module_fixture()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 545, in _inject_setup_module_fixture
    self.obj, ("setUpModule", "setup_module")
    ^^^^^^^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 310, in obj
    self._obj = obj = self._getobj()
                      ~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 528, in _getobj
    return self._importtestmodule()
           ~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 617, in _importtestmodule
    mod = import_path(self.path, mode=importmode, root=self.config.rootpath)
  File "/usr/lib/python3.13/site-packages/_pytest/pathlib.py", line 567, in import_path
    importlib.import_module(module_name)
    ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^
  File "/usr/lib64/python3.13/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "/usr/lib/python3.13/site-packages/_pytest/assertion/rewrite.py", line 186, in exec_module
    exec(co, module.__dict__)
    ~~~~^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/hypothesis-hypothesis-python-6.98.8/hypothesis-python/tests/cover/test_filter_rewriting.py", line 284, in <module>
    assert get_pretty_function_description(lambda_without_source) == "lambda x: <unknown>"
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/internal/reflection.py", line 444, in get_pretty_function_description
    return extract_lambda_source(f)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/internal/reflection.py", line 332, in extract_lambda_source
    assert "lambda" in source
           ^^^^^^^^^^^^^^^^^^
AssertionError


_ ERROR collecting hypothesis-python/tests/ghostwriter/test_expected_output.py _
Traceback (most recent call last):
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 341, in from_call
    result: Optional[TResult] = func()
                                ~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 372, in <lambda>
    call = CallInfo.from_call(lambda: list(collector.collect()), "collect")
                                           ~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 531, in collect
    self._inject_setup_module_fixture()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 545, in _inject_setup_module_fixture
    self.obj, ("setUpModule", "setup_module")
    ^^^^^^^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 310, in obj
    self._obj = obj = self._getobj()
                      ~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 528, in _getobj
    return self._importtestmodule()
           ~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 617, in _importtestmodule
    mod = import_path(self.path, mode=importmode, root=self.config.rootpath)
  File "/usr/lib/python3.13/site-packages/_pytest/pathlib.py", line 567, in import_path
    importlib.import_module(module_name)
    ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^
  File "/usr/lib64/python3.13/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "/usr/lib/python3.13/site-packages/_pytest/assertion/rewrite.py", line 186, in exec_module
    exec(co, module.__dict__)
    ~~~~^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/hypothesis-hypothesis-python-6.98.8/hypothesis-python/tests/ghostwriter/test_expected_output.py", line 132, in <module>
    ("magic_gufunc", ghostwriter.magic(numpy.matmul)),
                     ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/extra/ghostwriter.py", line 1301, in magic
    make_(_make_ufunc_body, func, annotate=annotate)
    ~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/extra/ghostwriter.py", line 1202, in make_
    imp, body = how(*args, **kwargs, except_=except_, style=style)
                ~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/extra/ghostwriter.py", line 1884, in _make_ufunc_body
    call=_write_call(func, *ascii_lowercase[: func.nin], except_=except_),
         ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/extra/ghostwriter.py", line 781, in _write_call
    args = ", ".join(
        (
    ...<4 lines>...
        for v, p in zip_longest(pass_variables, _get_params(func).values())
    )
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/extra/ghostwriter.py", line 784, in <genexpr>
    if p.kind is inspect.Parameter.POSITIONAL_ONLY
       ^^^^^^
AttributeError: 'NoneType' object has no attribute 'kind'

Failures:

________________________ test_bound_correct_forward_ref ________________________
[gw3] linux -- Python 3.13.0 /usr/bin/python3
Traceback (most recent call last):
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 341, in from_call
    result: Optional[TResult] = func()
                                ~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 262, in <lambda>
    lambda: ihook(item=item, **kwds), when=when, reraise=reraise
            ~~~~~^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/pluggy/_hooks.py", line 493, in __call__
    return self._hookexec(self.name, self._hookimpls, kwargs, firstresult)
           ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/pluggy/_manager.py", line 115, in _hookexec
    return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
           ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/pluggy/_callers.py", line 152, in _multicall
    return outcome.get_result()
           ~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/pluggy/_result.py", line 114, in get_result
    raise exc.with_traceback(exc.__traceback__)
  File "/usr/lib/python3.13/site-packages/pluggy/_callers.py", line 77, in _multicall
    res = hook_impl.function(*args)
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 177, in pytest_runtest_call
    raise e
  File "/usr/lib/python3.13/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call
    item.runtest()
    ~~~~~~~~~~~~^^
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 1792, in runtest
    self.ihook.pytest_pyfunc_call(pyfuncitem=self)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/pluggy/_hooks.py", line 493, in __call__
    return self._hookexec(self.name, self._hookimpls, kwargs, firstresult)
           ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/pluggy/_manager.py", line 115, in _hookexec
    return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
           ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/pluggy/_callers.py", line 113, in _multicall
    raise exception.with_traceback(exception.__traceback__)
  File "/usr/lib/python3.13/site-packages/pluggy/_callers.py", line 77, in _multicall
    res = hook_impl.function(*args)
  File "/usr/lib/python3.13/site-packages/_pytest/python.py", line 194, in pytest_pyfunc_call
    result = testfunction(**testargs)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/hypothesis-hypothesis-python-6.98.8/hypothesis-python/tests/cover/test_type_lookup_forward_ref.py", line 53, in test_bound_correct_forward_ref
    def test_bound_correct_forward_ref(built):
                   ^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/core.py", line 1425, in wrapped_test
    arguments, kwargs, stuff = process_arguments_to_given(
                               ~~~~~~~~~~~~~~~~~~~~~~~~~~^
        wrapped_test, arguments, kwargs, given_kwargs, new_signature.parameters
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    )
    ^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/core.py", line 670, in process_arguments_to_given
    s.validate()
    ~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 417, in validate
    self.do_validate()
    ~~~~~~~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/lazy.py", line 138, in do_validate
    w.validate()
    ~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/core.py", line 1084, in validate
    fixed_dictionaries(self.kwargs).validate()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 417, in validate
    self.do_validate()
    ~~~~~~~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/lazy.py", line 138, in do_validate
    w.validate()
    ~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 417, in validate
    self.do_validate()
    ~~~~~~~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 822, in do_validate
    self.mapped_strategy.validate()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 417, in validate
    self.do_validate()
    ~~~~~~~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/collections.py", line 44, in do_validate
    s.validate()
    ~~~~~~~~~~^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 418, in validate
    self.is_empty
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 136, in accept
    recur(self)
    ~~~~~^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 132, in recur
    mapping[strat] = getattr(strat, calculation)(recur)
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/deferred.py", line 68, in calc_is_empty
    return recur(self.wrapped_strategy)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 132, in recur
    mapping[strat] = getattr(strat, calculation)(recur)
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/lazy.py", line 89, in calc_is_empty
    return recur(self.wrapped_strategy)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/strategies.py", line 132, in recur
    mapping[strat] = getattr(strat, calculation)(recur)
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/deferred.py", line 68, in calc_is_empty
    return recur(self.wrapped_strategy)
                 ^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/deferred.py", line 38, in wrapped_strategy
    result = self.__definition()
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/core.py", line 1244, in <lambda>
    lambda thing: deferred(lambda: _from_type(thing)),
                                   ~~~~~~~~~~^^^^^^^
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/core.py", line 1329, in _from_type
    strategy = as_strategy(types._global_type_lookup[type(thing)], thing)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/core.py", line 1264, in as_strategy
    strategy = strat_or_callable(thing)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/types.py", line 1002, in resolve_TypeVar
    bound = _try_import_forward_ref(thing, bound)
  File "/builddir/build/BUILD/python-hypothesis-6.98.8-build/BUILDROOT/usr/lib/python3.13/site-packages/hypothesis/strategies/_internal/types.py", line 369, in _try_import_forward_ref
    return typing._eval_type(bound, vars(sys.modules[thing.__module__]), None)
           ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.13/typing.py", line 471, in _eval_type
    _deprecation_warning_for_no_type_params_passed("typing._eval_type")
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.13/typing.py", line 451, in _deprecation_warning_for_no_type_params_passed
    warnings.warn(depr_message, category=DeprecationWarning, stacklevel=3)
    ~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
DeprecationWarning: Failing to pass a value to the 'type_params' parameter of 'typing._eval_type' is deprecated, as it leads to incorrect behaviour when calling typing._eval_type on a stringified annotation that references a PEP 695 type parameter. It will be disallowed in Python 3.15.




Let us know here if you have any questions.
Python 3.13 is planned to be included in Fedora 41.

Comment 1 Miro Hrončok 2024-07-02 09:55:21 UTC
Taking a look if upgrading helps.

Comment 2 Fedora Update System 2024-07-02 12:58:48 UTC
FEDORA-2024-c5be8972cd (python-hypothesis-6.104.2-2.fc41) has been submitted as an update to Fedora 41.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-c5be8972cd

Comment 3 Fedora Update System 2024-07-02 14:08:36 UTC
FEDORA-2024-c5be8972cd (python-hypothesis-6.104.2-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.