Bug 2250846 - python-photutils fails to build with numpy 1.26: UNEXPECTED EXCEPTION: DeprecationWarning('`product` is deprecated as of NumPy 1.25.0, and will be removed in NumPy 2.0. Please use `prod` instead.')
Summary: python-photutils fails to build with numpy 1.26: UNEXPECTED EXCEPTION: Deprec...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: python-photutils
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Sergio Pascual
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: F40FTBFS PYTHON3.13
TreeView+ depends on / blocked
 
Reported: 2023-11-21 12:43 UTC by Karolina Surma
Modified: 2024-01-16 18:05 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2024-01-16 18:05:04 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Karolina Surma 2023-11-21 12:43:13 UTC
python-photutils fails to build with numpy 1.26:

___________________________ [doctest] centroids.rst ____________________________
041     >>> from photutils.datasets import make_4gaussians_image
042     >>> from photutils.centroids import centroid_com, centroid_quadratic
043     >>> from photutils.centroids import centroid_1dg, centroid_2dg
044     >>> data = make_4gaussians_image()[43:79, 76:104]
045 
046     >>> x1, y1 = centroid_com(data)
047     >>> print((x1, y1))  # doctest: +FLOAT_CMP
048     (13.93157998341213, 17.051234441067088)
049 
050     >>> x2, y2 = centroid_quadratic(data)
UNEXPECTED EXCEPTION: DeprecationWarning('`product` is deprecated as of NumPy 1.25.0, and will be removed in NumPy 2.0. Please use `prod` instead.')
Traceback (most recent call last):
  File "/usr/lib64/python3.13/doctest.py", line 1374, in __run
    exec(compile(example.source, filename, "single",
  File "<doctest centroids.rst[6]>", line 1, in <module>
  File "/builddir/build/BUILDROOT/python-photutils-1.5.0-4.fc40.x86_64/usr/lib64/python3.13/site-packages/photutils/centroids/core.py", line 178, in centroid_quadratic
    if np.product(fit_boxsize) < 6:
       ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.13/site-packages/numpy/core/fromnumeric.py", line 3826, in _product_dispatcher
    warnings.warn("`product` is deprecated as of NumPy 1.25.0, and will be "
DeprecationWarning: `product` is deprecated as of NumPy 1.25.0, and will be removed in NumPy 2.0. Please use `prod` instead.
/builddir/build/BUILD/photutils-1.5.0/docs/centroids.rst:50: UnexpectedException
=========================== short test summary info ============================
FAILED ../../docs/centroids.rst::centroids.rst
================= 1 failed, 1014 passed, 471 skipped in 28.79s =================


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

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


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