Bug 2359520 - python-numexpr fails to build with Python 3.14: 8 errors: ValueError: operands could not be broadcast together with shapes (1000000,) (0,) 2 failures: AssertionError: sys.getrefcount(a) == 2
Summary: python-numexpr fails to build with Python 3.14: 8 errors: ValueError: operand...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: python-numexpr
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jonathan Wright
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3.14
TreeView+ depends on / blocked
 
Reported: 2025-04-14 14:31 UTC by Karolina Surma
Modified: 2025-04-14 14:31 UTC (History)
7 users (show)

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


Attachments (Terms of Use)

Description Karolina Surma 2025-04-14 14:31:52 UTC
python-numexpr fails to build with Python 3.14.0a7.

ERROR: test_rational_expr (numexpr.tests.test_numexpr.test_numexpr.test_rational_expr)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python3.14/site-packages/numpy/testing/_private/utils.py", line 851, in assert_array_compare
    val = comparison(x, y)
  File "/usr/lib64/python3.14/site-packages/numpy/testing/_private/utils.py", line 1165, in compare
    z = abs(x - y)
            ~~^~~
ValueError: operands could not be broadcast together with shapes (1000000,) (0,) 

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/builddir/build/BUILD/python-numexpr-2.10.2-build/numexpr-2.10.2/build/lib.linux-x86_64-cpython-314/numexpr/tests/test_numexpr.py", line 79, in test_rational_expr
    assert_array_almost_equal(x, y)
    ~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
  File "/usr/lib64/python3.14/site-packages/numpy/_utils/__init__.py", line 86, in wrapper
    return fun(*args, **kwargs)
  File "/usr/lib64/python3.14/site-packages/numpy/testing/_private/utils.py", line 1172, in assert_array_almost_equal
    assert_array_compare(compare, actual, desired, err_msg=err_msg,
    ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                         verbose=verbose,
                         ^^^^^^^^^^^^^^^^
             header=('Arrays are not almost equal to %d decimals' % decimal),
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
             precision=decimal)
             ^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.14/site-packages/numpy/testing/_private/utils.py", line 929, in assert_array_compare
    raise ValueError(msg)
ValueError: 
error during assertion:

Traceback (most recent call last):
  File "/usr/lib64/python3.14/site-packages/numpy/testing/_private/utils.py", line 851, in assert_array_compare
    val = comparison(x, y)
  File "/usr/lib64/python3.14/site-packages/numpy/testing/_private/utils.py", line 1165, in compare
    z = abs(x - y)
            ~~^~~
ValueError: operands could not be broadcast together with shapes (1000000,) (0,) 

Arrays are not almost equal to 6 decimals
 ACTUAL: array([0.000000e+00, 4.225352e-01, 4.026846e-01, ..., 1.875002e-06,
       1.875000e-06, 1.874998e-06], shape=(1000000,))
 DESIRED: array([], dtype=float64)

======================================================================
FAIL: test_refcount (numexpr.tests.test_numexpr.test_numexpr2.test_refcount)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/python-numexpr-2.10.2-build/numexpr-2.10.2/build/lib.linux-x86_64-cpython-314/numexpr/tests/test_numexpr.py", line 317, in test_refcount
    assert sys.getrefcount(a) == 2
           ^^^^^^^^^^^^^^^^^^^^^^^
AssertionError

----------------------------------------------------------------------

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

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.14/fedora-rawhide-x86_64/08899418-python-numexpr/

For all our attempts to build python-numexpr with Python 3.14, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.14/package/python-numexpr/

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

Let us know here if you have any questions.

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