Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test failures with test_transform on NixOS #20

Closed
doronbehar opened this issue Sep 9, 2024 · 8 comments
Closed

Test failures with test_transform on NixOS #20

doronbehar opened this issue Sep 9, 2024 · 8 comments

Comments

@doronbehar
Copy link

As part of my packaging effort, here are 2 small failures we experience in NixOS in NixOS/nixpkgs#327446 :

=================================== FAILURES ===================================
__________________________ test_transform[False-500] ___________________________

N = 500, assemble_images = False

    @pytest.mark.parametrize("N", [500])
    @pytest.mark.parametrize("assemble_images", [False, True])
    def test_transform(N: int, assemble_images: bool) -> None:
        """Test image transforms
    
        Args:
            N: Image size (N x N)
            assemble_images: If True, assemble images (default: False)
        """
        with qt_app_context(exec_loop=True):
>           items = make_items(N)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:205: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:122: in make_items
    write_text_on_array(img, 0, 0, int(N / 15.0), str(dtype))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

data = array([[148, 157, 160, ...,  91, 114, 134],
       [150, 157, 157, ...,  98, 120, 138],
       [149, 154, 152, ..., 10...,  53,  80, 105],
       [136, 150, 159, ...,  67,  94, 117],
       [144, 155, 161, ...,  80, 105, 127]], dtype=uint8)
x = 0, y = 0, sz = 33, txt = "<class 'numpy.uint8'>", range = None

    def write_text_on_array(
        data: np.ndarray,
        x: int,
        y: int,
        sz: int,
        txt: str,
        range: tuple[int, int] | None = None,
    ) -> None:
        """Write text in image (in-place)
    
        Args:
            data: Image data
            x: X-coordinate of top-left corner
            y: Y-coordinate of top-left corner
            sz: Font size
            txt: Text to write
            range: Range of values to map to 0-255 (default: None)
        """
        arr = get_font_array(sz, txt)
        if arr is None:
            return
        if range is None:
            m, M = data.min(), data.max()
        else:
            m, M = range
        z = (float(M) - float(m)) * np.array(arr, float) / 255.0 + m
        arr = np.array(z, data.dtype)
        dy, dx = arr.shape
>       data[y : y + dy, x : x + dx] = arr
E       ValueError: could not broadcast input array from shape (33,693) into shape (33,500)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:101: ValueError
----------------------------- Captured stdout call -----------------------------
(40, 40)
___________________________ test_transform[True-500] ___________________________

N = 500, assemble_images = True

    @pytest.mark.parametrize("N", [500])
    @pytest.mark.parametrize("assemble_images", [False, True])
    def test_transform(N: int, assemble_images: bool) -> None:
        """Test image transforms
    
        Args:
            N: Image size (N x N)
            assemble_images: If True, assemble images (default: False)
        """
        with qt_app_context(exec_loop=True):
>           items = make_items(N)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:205: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:122: in make_items
    write_text_on_array(img, 0, 0, int(N / 15.0), str(dtype))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

data = array([[ 1, 13, 26, ..., 21, 15,  8],
       [ 6, 16, 29, ..., 13,  9,  4],
       [12, 21, 32, ...,  7,  6,  7],
    ...15, 11, 18, ..., 40, 32, 23],
       [10, 10, 20, ..., 34, 27, 19],
       [ 4, 10, 23, ..., 28, 22, 13]], dtype=uint8)
x = 0, y = 0, sz = 33, txt = "<class 'numpy.uint8'>", range = None

    def write_text_on_array(
        data: np.ndarray,
        x: int,
        y: int,
        sz: int,
        txt: str,
        range: tuple[int, int] | None = None,
    ) -> None:
        """Write text in image (in-place)
    
        Args:
            data: Image data
            x: X-coordinate of top-left corner
            y: Y-coordinate of top-left corner
            sz: Font size
            txt: Text to write
            range: Range of values to map to 0-255 (default: None)
        """
        arr = get_font_array(sz, txt)
        if arr is None:
            return
        if range is None:
            m, M = data.min(), data.max()
        else:
            m, M = range
        z = (float(M) - float(m)) * np.array(arr, float) / 255.0 + m
        arr = np.array(z, data.dtype)
        dy, dx = arr.shape
>       data[y : y + dy, x : x + dx] = arr
E       ValueError: could not broadcast input array from shape (33,693) into shape (33,500)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:101: ValueError
----------------------------- Captured stdout call -----------------------------
(40, 40)
=============================== warnings summary ===============================
lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py:26
  /nix/store/lyx1hxrv16ll7p8n3x045sdq6jxli33d-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py:26: PytestCollectionWarning: cannot collect test class 'TestWidget' because it has a __init__ constructor (from: lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py)
    class TestWidget(GuidataTestWidget):

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
FAILED lib/python3.12/site-packages/plotpy/tests/items/test_transform.py::test_transform[False-500] - ValueError: could not broadcast input array from shape (33,693) into shape ...
FAILED lib/python3.12/site-packages/plotpy/tests/items/test_transform.py::test_transform[True-500] - ValueError: could not broadcast input array from shape (33,693) into shape ...
@PierreRaybaut
Copy link
Contributor

Thanks for the feedback.
Unfortunately, I can't reproduce this one.
Could you provide more information on your configuration?

@PierreRaybaut
Copy link
Contributor

In the meantime, I have fixed a couple of bugs with latest PyQt6 and PySide6 versions and Python 3.12 on Linux.
But, before releasing the new version, I'm waiting for your feedback, hoping that I can do something about it.

@doronbehar
Copy link
Author

I'm using PyQt5, and Numpy 1.26 . With PyQt6, PySide6 and even PySide2 I experience #11 - very similar to PlotPyStack/guidata#77 - which was indeed fixed (thanks). I hoped that including the patch that fixed PlotPyStack/guidata#77 would fix #11 for me, but it doesn't. Here are more logs of the Fatal Python error I experience:

With PySide2
============================= test session starts ==============================
platform linux -- Python 3.12.5, pytest-8.3.2, pluggy-1.5.0
rootdir: /nix/store/3f0drfyhn2sd37fmidjbhfjkqi8pbh3h-python3.12-plotpy-2.6.2
collected 293 items / 1 skipped                                                

lib/python3.12/site-packages/plotpy/tests/benchmarks/test_benchmarks.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_bigimages.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_loadtest.py s  [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_auto_curve_image.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_autoscale_shapes.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_builder.py .     [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_editor.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_manager.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_computations.py . [  3%]
                                                                         [  3%]
lib/python3.12/site-packages/plotpy/tests/features/test_contrast.py ..   [  3%]
lib/python3.12/site-packages/plotpy/tests/features/test_cursors.py .     [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_dicom_image.py s [  4%]
                                                                         [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_fit.py .         [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_image_coords.py . [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_image_data_update.py s [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_imagefilter.py . [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_imagesuperp.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_hdf5.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_json.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_pickle.py . [  7%]
                                                                         [  7%]
lib/python3.12/site-packages/plotpy/tests/features/test_manager.py ..    [  7%]
lib/python3.12/site-packages/plotpy/tests/features/test_no_auto_tools.py . [  8%]
                                                                         [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_log.py .    [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_types.py .  [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_yreverse.py . [  9%]
                                                                         [  9%]
lib/python3.12/site-packages/plotpy/tests/features/test_pyplot.py s      [  9%]
lib/python3.12/site-packages/plotpy/tests/features/test_resize.py .      [  9%]
lib/python3.12/site-packages/plotpy/tests/items/test_annotations.py .    [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_curves.py .         [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_curves_highdpi.py s [ 10%]
                                                                         [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_hist2d.py ..        [ 11%]
lib/python3.12/site-packages/plotpy/tests/items/test_histogram.py .      [ 11%]
lib/python3.12/site-packages/plotpy/tests/items/test_image.py .          [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_contour.py .  [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_masked.py .   [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_masked_xy.py . [ 13%]
                                                                         [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_rgb.py .      [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_xy.py .       [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_mandelbrot.py .     [ 14%]
lib/python3.12/site-packages/plotpy/tests/items/test_pcolor.py ..        [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_polygons.py .       [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_svgshapes.py .      [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py FF     [ 16%]
lib/python3.12/site-packages/plotpy/tests/tools/test_actiontool.py .     [ 16%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section.py .  [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section_line.py . [ 17%]
                                                                         [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section_oblique.py . [ 17%]
                                                                         [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_customize_shape_tool.py . [ 18%]
                                                                         [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cyclic_import.py .  [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_downsample_curve.py . [ 18%]
                                                                         [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_edit_point.py .     [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_point.py .      [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_points.py .     [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_rectangle.py .  [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_rectangle_with_svg.py . [ 20%]
                                                                         [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_segment.py .    [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_image_plot_tools.py Fatal Python error: Segmentation fault

Current thread 0x00007ffff7f90740 (most recent call first):
  File "/nix/store/1df3l4qvsz3lbszdg8cwapyddzx6dl1k-python3.12-pythonqwt-0.12.7/lib/python3.12/site-packages/qwt/plot_canvas.py", line 583 in event
  File "/nix/store/fwljh26px1wafcfa5q572czjk9rhrkll-python3.12-qtpy-2.4.1/lib/python3.12/site-packages/qtpy/_utils.py", line 67 in possibly_static_exec_
  File "/nix/store/fwljh26px1wafcfa5q572czjk9rhrkll-python3.12-qtpy-2.4.1/lib/python3.12/site-packages/qtpy/QtCore.py", line 114 in <lambda>
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/qthelpers.py", line 689 in qt_app_context
  File "/nix/store/pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/lib/python3.12/contextlib.py", line 144 in __exit__
  File "/nix/store/3f0drfyhn2sd37fmidjbhfjkqi8pbh3h-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/tools/test_image_plot_tools.py", line 73 in test_image_plot_tools
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 159 in pytest_pyfunc_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 1627 in runtest
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 174 in pytest_runtest_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 242 in <lambda>
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 341 in from_call
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 241 in call_and_report
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 132 in runtestprotocol
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 113 in pytest_runtest_protocol
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 362 in pytest_runtestloop
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 337 in _main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 283 in wrap_session
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 330 in pytest_cmdline_main
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 175 in main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 201 in console_main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/pytest/__main__.py", line 9 in <module>
  File "<frozen runpy>", line 88 in _run_code
  File "<frozen runpy>", line 198 in _run_module_as_main

Extension modules: h5py._errors, h5py.defs, h5py._objects, h5py.h5, numpy.core._multiarray_umath, numpy.core._multiarray_tests, numpy.linalg._umath_linalg, numpy.fft._pocketfft_internal, numpy.random._common, numpy.random.bit_generator, numpy.random._bounded_integers, numpy.random._mt19937, numpy.random.mtrand, numpy.random._philox, numpy.random._pcg64, numpy.random._sfc64, numpy.random._generator, h5py.utils, h5py.h5t, h5py.h5s, h5py.h5ac, h5py.h5p, h5py.h5r, h5py._proxy, h5py._conv, h5py.h5z, h5py.h5a, h5py.h5d, h5py.h5ds, h5py.h5g, h5py.h5i, h5py.h5f, h5py.h5fd, h5py.h5pl, h5py.h5o, h5py.h5l, h5py._selector, shiboken2.shiboken2, PySide2.QtCore, PySide2.QtGui, PySide2.QtWidgets, PySide2.QtSvg, PySide2.QtPrintSupport, scipy._lib._ccallback_c, plotpy._scaler, skimage._shared.geometry, PIL._imaging, histogram2d, plotpy.histogram2d, scipy.special._ufuncs_cxx, scipy.special._ufuncs, scipy.special._specfun, scipy.special._comb, scipy.linalg._fblas, scipy.linalg._flapack, scipy.linalg.cython_lapack, scipy.linalg._cythonized_array_utils, scipy.linalg._solve_toeplitz, scipy.linalg._decomp_lu_cython, scipy.linalg._matfuncs_sqrtm_triu, scipy.linalg.cython_blas, scipy.linalg._matfuncs_expm, scipy.linalg._decomp_update, scipy.sparse._sparsetools, _csparsetools, scipy.sparse._csparsetools, scipy.sparse.linalg._dsolve._superlu, scipy.sparse.linalg._eigen.arpack._arpack, scipy.sparse.linalg._propack._spropack, scipy.sparse.linalg._propack._dpropack, scipy.sparse.linalg._propack._cpropack, scipy.sparse.linalg._propack._zpropack, scipy.sparse.csgraph._tools, scipy.sparse.csgraph._shortest_path, scipy.sparse.csgraph._traversal, scipy.sparse.csgraph._min_spanning_tree, scipy.sparse.csgraph._flow, scipy.sparse.csgraph._matching, scipy.sparse.csgraph._reordering, scipy.special._ellip_harm_2, scipy.integrate._odepack, scipy.integrate._quadpack, scipy.integrate._vode, scipy.integrate._dop, scipy.integrate._lsoda, scipy.optimize._group_columns, scipy._lib.messagestream, scipy.optimize._trlib._trlib, scipy.optimize._lbfgsb, _moduleTNC, scipy.optimize._moduleTNC, scipy.optimize._cobyla, scipy.optimize._slsqp, scipy.optimize._minpack, scipy.optimize._lsq.givens_elimination, scipy.optimize._zeros, scipy.optimize._highs.cython.src._highs_wrapper, scipy.optimize._highs._highs_wrapper, scipy.optimize._highs.cython.src._highs_constants, scipy.optimize._highs._highs_constants, scipy.linalg._interpolative, scipy.optimize._bglu_dense, scipy.optimize._lsap, scipy.spatial._ckdtree, scipy.spatial._qhull, scipy.spatial._voronoi, scipy.spatial._distance_wrap, scipy.spatial._hausdorff, scipy.spatial.transform._rotation, scipy.optimize._direct, scipy.ndimage._nd_image, _ni_label, scipy.ndimage._ni_label, mandelbrot, plotpy.mandelbrot, scipy.signal._sigtools, scipy._lib._uarray._uarray, scipy.signal._max_len_seq_inner, scipy.signal._upfirdn_apply, scipy.signal._spline, scipy.interpolate._fitpack, scipy.interpolate._dfitpack, scipy.interpolate._bspl, scipy.interpolate._ppoly, scipy.interpolate.interpnd, scipy.interpolate._rbfinterp_pythran, scipy.interpolate._rgi_cython, scipy.signal._sosfilt, scipy.signal._spectral, scipy.special.cython_special, scipy.stats._stats, scipy.stats._biasedurn, scipy.stats._levy_stable.levyst, scipy.stats._stats_pythran, scipy.stats._ansari_swilk_statistics, scipy.stats._sobol, scipy.stats._qmc_cy, scipy.stats._mvn, scipy.stats._rcont.rcont, scipy.stats._unuran.unuran_wrapper, scipy.signal._peak_finding_utils, PySide2.QtXml, PySide2.QtUiTools, PIL._imagingmath, skimage.measure._find_contours_cy (total: 145)
/nix/store/j9q99fln05lr27zf08p2hd73410mfr2i-pytest-check-hook/nix-support/setup-hook: line 53:  1139 Segmentation fault      (core dumped) /nix/store/pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/bin/python3.12 -m pytest
With PyQt6
============================= test session starts ==============================
platform linux -- Python 3.12.5, pytest-8.3.2, pluggy-1.5.0
rootdir: /nix/store/klq37qsfbzzyybwhn2gn2i0mzk9nx2x9-python3.12-plotpy-2.6.2
collected 293 items / 1 skipped                                                

lib/python3.12/site-packages/plotpy/tests/benchmarks/test_benchmarks.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_bigimages.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_loadtest.py s  [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_auto_curve_image.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_autoscale_shapes.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_builder.py .     [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_editor.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_manager.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_computations.py . [  3%]
                                                                         [  3%]
lib/python3.12/site-packages/plotpy/tests/features/test_contrast.py ..   [  3%]
lib/python3.12/site-packages/plotpy/tests/features/test_cursors.py .     [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_dicom_image.py s [  4%]
                                                                         [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_fit.py .         [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_image_coords.py . [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_image_data_update.py s [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_imagefilter.py . [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_imagesuperp.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_hdf5.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_json.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_pickle.py . [  7%]
                                                                         [  7%]
lib/python3.12/site-packages/plotpy/tests/features/test_manager.py ..    [  7%]
lib/python3.12/site-packages/plotpy/tests/features/test_no_auto_tools.py . [  8%]
                                                                         [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_log.py .    [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_types.py .  [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_yreverse.py . [  9%]
                                                                         [  9%]
lib/python3.12/site-packages/plotpy/tests/features/test_pyplot.py s      [  9%]
lib/python3.12/site-packages/plotpy/tests/features/test_resize.py .      [  9%]
lib/python3.12/site-packages/plotpy/tests/items/test_annotations.py .    [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_curves.py .         [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_curves_highdpi.py s [ 10%]
                                                                         [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_hist2d.py ..        [ 11%]
lib/python3.12/site-packages/plotpy/tests/items/test_histogram.py .      [ 11%]
lib/python3.12/site-packages/plotpy/tests/items/test_image.py .          [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_contour.py .  [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_masked.py .   [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_masked_xy.py . [ 13%]
                                                                         [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_rgb.py .      [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_xy.py .       [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_mandelbrot.py .     [ 14%]
lib/python3.12/site-packages/plotpy/tests/items/test_pcolor.py ..        [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_polygons.py .       [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_svgshapes.py .      [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py ..     [ 16%]
lib/python3.12/site-packages/plotpy/tests/tools/test_actiontool.py .     [ 16%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section.py .  [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section_line.py . [ 17%]
                                                                         [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section_oblique.py . [ 17%]
                                                                         [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_customize_shape_tool.py . [ 18%]
                                                                         [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cyclic_import.py .  [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_downsample_curve.py . [ 18%]
                                                                         [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_edit_point.py .     [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_point.py .      [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_points.py .     [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_rectangle.py .  [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_rectangle_with_svg.py . [ 20%]
                                                                         [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_segment.py .    [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_image_plot_tools.py . [ 21%]
                                                                         [ 21%]
lib/python3.12/site-packages/plotpy/tests/tools/test_stats_tools.py .Fatal Python error: Aborted

Current thread 0x00007ffff7f90740 (most recent call first):
  File "/nix/store/klq37qsfbzzyybwhn2gn2i0mzk9nx2x9-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/unit/utils.py", line 169 in mouse_event_at_relative_plot_pos
  File "/nix/store/klq37qsfbzzyybwhn2gn2i0mzk9nx2x9-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/unit/utils.py", line 201 in drag_mouse
  File "/nix/store/klq37qsfbzzyybwhn2gn2i0mzk9nx2x9-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/tools/test_stats_tools.py", line 62 in simulate_stats_tool
  File "/nix/store/klq37qsfbzzyybwhn2gn2i0mzk9nx2x9-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/tools/test_stats_tools.py", line 42 in __init__
  File "/nix/store/klq37qsfbzzyybwhn2gn2i0mzk9nx2x9-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/tools/test_stats_tools.py", line 149 in test_image_stats_tools
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 159 in pytest_pyfunc_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 1627 in runtest
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 174 in pytest_runtest_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 242 in <lambda>
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 341 in from_call
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 241 in call_and_report
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 132 in runtestprotocol
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 113 in pytest_runtest_protocol
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 362 in pytest_runtestloop
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 337 in _main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 283 in wrap_session
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 330 in pytest_cmdline_main
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 175 in main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 201 in console_main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/pytest/__main__.py", line 9 in <module>
  File "<frozen runpy>", line 88 in _run_code
  File "<frozen runpy>", line 198 in _run_module_as_main

Extension modules: h5py._errors, h5py.defs, h5py._objects, h5py.h5, numpy.core._multiarray_umath, numpy.core._multiarray_tests, numpy.linalg._umath_linalg, numpy.fft._pocketfft_internal, numpy.random._common, numpy.random.bit_generator, numpy.random._bounded_integers, numpy.random._mt19937, numpy.random.mtrand, numpy.random._philox, numpy.random._pcg64, numpy.random._sfc64, numpy.random._generator, h5py.utils, h5py.h5t, h5py.h5s, h5py.h5ac, h5py.h5p, h5py.h5r, h5py._proxy, h5py._conv, h5py.h5z, h5py.h5a, h5py.h5d, h5py.h5ds, h5py.h5g, h5py.h5i, h5py.h5f, h5py.h5fd, h5py.h5pl, h5py.h5o, h5py.h5l, h5py._selector, PyQt6.QtCore, PyQt6.QtGui, PyQt6.QtOpenGL, PyQt6.QtWidgets, PyQt6.QtOpenGLWidgets, PyQt6.QtSvg, PyQt6.QtPrintSupport, scipy._lib._ccallback_c, plotpy._scaler, skimage._shared.geometry, PIL._imaging, histogram2d, plotpy.histogram2d, scipy.special._ufuncs_cxx, scipy.special._ufuncs, scipy.special._specfun, scipy.special._comb, scipy.linalg._fblas, scipy.linalg._flapack, scipy.linalg.cython_lapack, scipy.linalg._cythonized_array_utils, scipy.linalg._solve_toeplitz, scipy.linalg._decomp_lu_cython, scipy.linalg._matfuncs_sqrtm_triu, scipy.linalg.cython_blas, scipy.linalg._matfuncs_expm, scipy.linalg._decomp_update, scipy.sparse._sparsetools, _csparsetools, scipy.sparse._csparsetools, scipy.sparse.linalg._dsolve._superlu, scipy.sparse.linalg._eigen.arpack._arpack, scipy.sparse.linalg._propack._spropack, scipy.sparse.linalg._propack._dpropack, scipy.sparse.linalg._propack._cpropack, scipy.sparse.linalg._propack._zpropack, scipy.sparse.csgraph._tools, scipy.sparse.csgraph._shortest_path, scipy.sparse.csgraph._traversal, scipy.sparse.csgraph._min_spanning_tree, scipy.sparse.csgraph._flow, scipy.sparse.csgraph._matching, scipy.sparse.csgraph._reordering, scipy.special._ellip_harm_2, scipy.integrate._odepack, scipy.integrate._quadpack, scipy.integrate._vode, scipy.integrate._dop, scipy.integrate._lsoda, scipy.optimize._group_columns, scipy._lib.messagestream, scipy.optimize._trlib._trlib, scipy.optimize._lbfgsb, _moduleTNC, scipy.optimize._moduleTNC, scipy.optimize._cobyla, scipy.optimize._slsqp, scipy.optimize._minpack, scipy.optimize._lsq.givens_elimination, scipy.optimize._zeros, scipy.optimize._highs.cython.src._highs_wrapper, scipy.optimize._highs._highs_wrapper, scipy.optimize._highs.cython.src._highs_constants, scipy.optimize._highs._highs_constants, scipy.linalg._interpolative, scipy.optimize._bglu_dense, scipy.optimize._lsap, scipy.spatial._ckdtree, scipy.spatial._qhull, scipy.spatial._voronoi, scipy.spatial._distance_wrap, scipy.spatial._hausdorff, scipy.spatial.transform._rotation, scipy.optimize._direct, scipy.ndimage._nd_image, _ni_label, scipy.ndimage._ni_label, mandelbrot, plotpy.mandelbrot, scipy.signal._sigtools, scipy._lib._uarray._uarray, scipy.signal._max_len_seq_inner, scipy.signal._upfirdn_apply, scipy.signal._spline, scipy.interpolate._fitpack, scipy.interpolate._dfitpack, scipy.interpolate._bspl, scipy.interpolate._ppoly, scipy.interpolate.interpnd, scipy.interpolate._rbfinterp_pythran, scipy.interpolate._rgi_cython, scipy.signal._sosfilt, scipy.signal._spectral, scipy.special.cython_special, scipy.stats._stats, scipy.stats._biasedurn, scipy.stats._levy_stable.levyst, scipy.stats._stats_pythran, scipy.stats._ansari_swilk_statistics, scipy.stats._sobol, scipy.stats._qmc_cy, scipy.stats._mvn, scipy.stats._rcont.rcont, scipy.stats._unuran.unuran_wrapper, scipy.signal._peak_finding_utils, PIL._imagingmath, skimage.measure._find_contours_cy (total: 144)
/nix/store/j9q99fln05lr27zf08p2hd73410mfr2i-pytest-check-hook/nix-support/setup-hook: line 53:  1139 Aborted                 (core dumped) /nix/store/pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/bin/python3.12 -m pytest
With PySide6
============================= test session starts ==============================
platform linux -- Python 3.12.5, pytest-8.3.2, pluggy-1.5.0
rootdir: /nix/store/f21yh63jldjy9qzffw9km58z4k84mkx5-python3.12-plotpy-2.6.2
collected 293 items / 1 skipped                                                

lib/python3.12/site-packages/plotpy/tests/benchmarks/test_benchmarks.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_bigimages.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_loadtest.py s  [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_auto_curve_image.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_autoscale_shapes.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_builder.py .     [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_editor.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_manager.py Fatal Python error: Segmentation fault

Current thread 0x00007ffff7f90740 (most recent call first):
  Garbage-collecting
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtitemwidgets.py", line 115 in place_label
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtitemwidgets.py", line 739 in place_on_grid
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtwidgets.py", line 469 in add_row
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtwidgets.py", line 440 in setup_layout
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtwidgets.py", line 335 in __init__
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtwidgets.py", line 856 in get_edit_layout
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtwidgets.py", line 780 in __init__
  File "/nix/store/whw4jvh64820y4vnrjir671x7cx7j5g8-python3.12-guidata-3.6.2/lib/python3.12/site-packages/guidata/dataset/qtwidgets.py", line 830 in __init__
  File "/nix/store/f21yh63jldjy9qzffw9km58z4k84mkx5-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/widgets/colormap/editor.py", line 222 in new_tab
  File "/nix/store/f21yh63jldjy9qzffw9km58z4k84mkx5-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/widgets/colormap/editor.py", line 251 in setup_tabs
  File "/nix/store/f21yh63jldjy9qzffw9km58z4k84mkx5-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/widgets/colormap/editor.py", line 144 in __init__
  File "/nix/store/f21yh63jldjy9qzffw9km58z4k84mkx5-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/widgets/colormap/manager.py", line 193 in __init__
  File "/nix/store/f21yh63jldjy9qzffw9km58z4k84mkx5-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/features/test_colormap_manager.py", line 40 in test_colormap_manager
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 159 in pytest_pyfunc_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 1627 in runtest
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 174 in pytest_runtest_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 242 in <lambda>
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 341 in from_call
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 241 in call_and_report
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 132 in runtestprotocol
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 113 in pytest_runtest_protocol
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 362 in pytest_runtestloop
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 337 in _main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 283 in wrap_session
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 330 in pytest_cmdline_main
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 175 in main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 201 in console_main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/pytest/__main__.py", line 9 in <module>
  File "<frozen runpy>", line 88 in _run_code
  File "<frozen runpy>", line 198 in _run_module_as_main

Extension modules: h5py._errors, h5py.defs, h5py._objects, h5py.h5, numpy.core._multiarray_umath, numpy.core._multiarray_tests, numpy.linalg._umath_linalg, numpy.fft._pocketfft_internal, numpy.random._common, numpy.random.bit_generator, numpy.random._bounded_integers, numpy.random._mt19937, numpy.random.mtrand, numpy.random._philox, numpy.random._pcg64, numpy.random._sfc64, numpy.random._generator, h5py.utils, h5py.h5t, h5py.h5s, h5py.h5ac, h5py.h5p, h5py.h5r, h5py._proxy, h5py._conv, h5py.h5z, h5py.h5a, h5py.h5d, h5py.h5ds, h5py.h5g, h5py.h5i, h5py.h5f, h5py.h5fd, h5py.h5pl, h5py.h5o, h5py.h5l, h5py._selector, shiboken6.Shiboken, PySide6.QtCore, PySide6.QtGui, PySide6.QtDataVisualization, PySide6.QtOpenGL, PySide6.QtWidgets, PySide6.QtOpenGLWidgets, PySide6.QtSvg, PySide6.QtPrintSupport, scipy._lib._ccallback_c, plotpy._scaler, skimage._shared.geometry, PIL._imaging, histogram2d, plotpy.histogram2d, scipy.special._ufuncs_cxx, scipy.special._ufuncs, scipy.special._specfun, scipy.special._comb, scipy.linalg._fblas, scipy.linalg._flapack, scipy.linalg.cython_lapack, scipy.linalg._cythonized_array_utils, scipy.linalg._solve_toeplitz, scipy.linalg._decomp_lu_cython, scipy.linalg._matfuncs_sqrtm_triu, scipy.linalg.cython_blas, scipy.linalg._matfuncs_expm, scipy.linalg._decomp_update, scipy.sparse._sparsetools, _csparsetools, scipy.sparse._csparsetools, scipy.sparse.linalg._dsolve._superlu, scipy.sparse.linalg._eigen.arpack._arpack, scipy.sparse.linalg._propack._spropack, scipy.sparse.linalg._propack._dpropack, scipy.sparse.linalg._propack._cpropack, scipy.sparse.linalg._propack._zpropack, scipy.sparse.csgraph._tools, scipy.sparse.csgraph._shortest_path, scipy.sparse.csgraph._traversal, scipy.sparse.csgraph._min_spanning_tree, scipy.sparse.csgraph._flow, scipy.sparse.csgraph._matching, scipy.sparse.csgraph._reordering, scipy.special._ellip_harm_2, scipy.integrate._odepack, scipy.integrate._quadpack, scipy.integrate._vode, scipy.integrate._dop, scipy.integrate._lsoda, scipy.optimize._group_columns, scipy._lib.messagestream, scipy.optimize._trlib._trlib, scipy.optimize._lbfgsb, _moduleTNC, scipy.optimize._moduleTNC, scipy.optimize._cobyla, scipy.optimize._slsqp, scipy.optimize._minpack, scipy.optimize._lsq.givens_elimination, scipy.optimize._zeros, scipy.optimize._highs.cython.src._highs_wrapper, scipy.optimize._highs._highs_wrapper, scipy.optimize._highs.cython.src._highs_constants, scipy.optimize._highs._highs_constants, scipy.linalg._interpolative, scipy.optimize._bglu_dense, scipy.optimize._lsap, scipy.spatial._ckdtree, scipy.spatial._qhull, scipy.spatial._voronoi, scipy.spatial._distance_wrap, scipy.spatial._hausdorff, scipy.spatial.transform._rotation, scipy.optimize._direct, scipy.ndimage._nd_image, _ni_label, scipy.ndimage._ni_label, mandelbrot, plotpy.mandelbrot, scipy.signal._sigtools, scipy._lib._uarray._uarray, scipy.signal._max_len_seq_inner, scipy.signal._upfirdn_apply, scipy.signal._spline, scipy.interpolate._fitpack, scipy.interpolate._dfitpack, scipy.interpolate._bspl, scipy.interpolate._ppoly, scipy.interpolate.interpnd, scipy.interpolate._rbfinterp_pythran, scipy.interpolate._rgi_cython, scipy.signal._sosfilt, scipy.signal._spectral, scipy.special.cython_special, scipy.stats._stats, scipy.stats._biasedurn, scipy.stats._levy_stable.levyst, scipy.stats._stats_pythran, scipy.stats._ansari_swilk_statistics, scipy.stats._sobol, scipy.stats._qmc_cy, scipy.stats._mvn, scipy.stats._rcont.rcont, scipy.stats._unuran.unuran_wrapper, scipy.signal._peak_finding_utils, PySide6.QtUiTools, PySide6.QtDesigner (total: 146)
/nix/store/j9q99fln05lr27zf08p2hd73410mfr2i-pytest-check-hook/nix-support/setup-hook: line 53:  1139 Segmentation fault      (core dumped) /nix/store/pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/bin/python3.12 -m pytest

With PyQt5, I don't experience #11 , but I do experience the error from the first comment. Here's how pytest starts:

============================= test session starts ==============================
platform linux -- Python 3.12.5, pytest-8.3.2, pluggy-1.5.0
rootdir: /nix/store/23r9899cd8vwj8qj4lvb30hbai0x2vr8-python3.12-plotpy-2.6.2
collected 293 items / 1 skipped                                                

@doronbehar
Copy link
Author

Oh and With guidata 3.6.3, I get a totally different error:

============================= test session starts ==============================
platform linux -- Python 3.12.5, pytest-8.3.2, pluggy-1.5.0
rootdir: /nix/store/qdkzm7vsinlqqw0x6fa7vhyif1iw4ccs-python3.12-plotpy-2.6.2
collected 292 items / 1 error / 3 deselected / 1 skipped / 289 selected        

==================================== ERRORS ====================================
_ ERROR collecting lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py _
ImportError while importing test module '/nix/store/qdkzm7vsinlqqw0x6fa7vhyif1iw4ccs-python3.12-plotpy-2.6.2/lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
../pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/lib/python3.12/importlib/__init__.py:90: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py:17: in <module>
    from guidata.tests.widgets.test_theme import TestWidget as GuidataTestWidget
E   ImportError: cannot import name 'TestWidget' from 'guidata.tests.widgets.test_theme' (/nix/store/d3s9gscr0wyna4d0yj7vngarb396ymd8-python3.12-guidata-3.6.3/lib/python3.12/site-packages/guidata/tests/widgets/test_theme.py)
=========================== short test summary info ============================
ERROR lib/python3.12/site-packages/plotpy/tests/widgets/test_theme.py
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
================== 1 skipped, 3 deselected, 1 error in 2.64s ===================

Which made me try out the latest master (241416a) of plotpy - as I should have done before :), and with it, here are the failures:

with PySide2
============================= test session starts ==============================
platform linux -- Python 3.12.5, pytest-8.3.2, pluggy-1.5.0
rootdir: /nix/store/mfyla5jw0g8lk3bcyyg4vqn93bm0w0ga-python3.12-plotpy-2.6.2-unstable-2024-09-10
collected 293 items / 1 skipped                                                

lib/python3.12/site-packages/plotpy/tests/benchmarks/test_benchmarks.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_bigimages.py s [  0%]
                                                                         [  0%]
lib/python3.12/site-packages/plotpy/tests/benchmarks/test_loadtest.py s  [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_auto_curve_image.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_autoscale_shapes.py . [  1%]
                                                                         [  1%]
lib/python3.12/site-packages/plotpy/tests/features/test_builder.py .     [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_editor.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_colormap_manager.py . [  2%]
                                                                         [  2%]
lib/python3.12/site-packages/plotpy/tests/features/test_computations.py . [  3%]
                                                                         [  3%]
lib/python3.12/site-packages/plotpy/tests/features/test_contrast.py ..   [  3%]
lib/python3.12/site-packages/plotpy/tests/features/test_cursors.py .     [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_dicom_image.py s [  4%]
                                                                         [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_fit.py .         [  4%]
lib/python3.12/site-packages/plotpy/tests/features/test_image_coords.py . [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_image_data_update.py s [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_imagefilter.py . [  5%]
                                                                         [  5%]
lib/python3.12/site-packages/plotpy/tests/features/test_imagesuperp.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_hdf5.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_json.py . [  6%]
                                                                         [  6%]
lib/python3.12/site-packages/plotpy/tests/features/test_loadsaveitems_pickle.py . [  7%]
                                                                         [  7%]
lib/python3.12/site-packages/plotpy/tests/features/test_manager.py ..    [  7%]
lib/python3.12/site-packages/plotpy/tests/features/test_no_auto_tools.py . [  8%]
                                                                         [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_log.py .    [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_types.py .  [  8%]
lib/python3.12/site-packages/plotpy/tests/features/test_plot_yreverse.py . [  9%]
                                                                         [  9%]
lib/python3.12/site-packages/plotpy/tests/features/test_pyplot.py s      [  9%]
lib/python3.12/site-packages/plotpy/tests/features/test_resize.py .      [  9%]
lib/python3.12/site-packages/plotpy/tests/items/test_annotations.py .    [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_curves.py .         [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_curves_highdpi.py s [ 10%]
                                                                         [ 10%]
lib/python3.12/site-packages/plotpy/tests/items/test_hist2d.py ..        [ 11%]
lib/python3.12/site-packages/plotpy/tests/items/test_histogram.py .      [ 11%]
lib/python3.12/site-packages/plotpy/tests/items/test_image.py .          [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_contour.py .  [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_masked.py .   [ 12%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_masked_xy.py . [ 13%]
                                                                         [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_rgb.py .      [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_image_xy.py .       [ 13%]
lib/python3.12/site-packages/plotpy/tests/items/test_mandelbrot.py .     [ 14%]
lib/python3.12/site-packages/plotpy/tests/items/test_pcolor.py ..        [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_polygons.py .       [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_svgshapes.py .      [ 15%]
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py FF     [ 16%]
lib/python3.12/site-packages/plotpy/tests/tools/test_actiontool.py .     [ 16%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section.py .  [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section_line.py . [ 17%]
                                                                         [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cross_section_oblique.py . [ 17%]
                                                                         [ 17%]
lib/python3.12/site-packages/plotpy/tests/tools/test_customize_shape_tool.py . [ 18%]
                                                                         [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_cyclic_import.py .  [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_downsample_curve.py . [ 18%]
                                                                         [ 18%]
lib/python3.12/site-packages/plotpy/tests/tools/test_edit_point.py .     [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_point.py .      [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_points.py .     [ 19%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_rectangle.py .  [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_rectangle_with_svg.py . [ 20%]
                                                                         [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_get_segment.py .    [ 20%]
lib/python3.12/site-packages/plotpy/tests/tools/test_image_plot_tools.py Fatal Python error: Segmentation fault

Current thread 0x00007ffff7f90740 (most recent call first):
  File "/nix/store/1df3l4qvsz3lbszdg8cwapyddzx6dl1k-python3.12-pythonqwt-0.12.7/lib/python3.12/site-packages/qwt/plot_canvas.py", line 583 in event
  File "/nix/store/fwljh26px1wafcfa5q572czjk9rhrkll-python3.12-qtpy-2.4.1/lib/python3.12/site-packages/qtpy/_utils.py", line 67 in possibly_static_exec_
  File "/nix/store/fwljh26px1wafcfa5q572czjk9rhrkll-python3.12-qtpy-2.4.1/lib/python3.12/site-packages/qtpy/QtCore.py", line 114 in <lambda>
  File "/nix/store/d3s9gscr0wyna4d0yj7vngarb396ymd8-python3.12-guidata-3.6.3/lib/python3.12/site-packages/guidata/qthelpers.py", line 689 in qt_app_context
  File "/nix/store/pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/lib/python3.12/contextlib.py", line 144 in __exit__
  File "/nix/store/mfyla5jw0g8lk3bcyyg4vqn93bm0w0ga-python3.12-plotpy-2.6.2-unstable-2024-09-10/lib/python3.12/site-packages/plotpy/tests/tools/test_image_plot_tools.py", line 73 in test_image_plot_tools
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 159 in pytest_pyfunc_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/python.py", line 1627 in runtest
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 174 in pytest_runtest_call
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 242 in <lambda>
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 341 in from_call
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 241 in call_and_report
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 132 in runtestprotocol
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/runner.py", line 113 in pytest_runtest_protocol
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 362 in pytest_runtestloop
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 337 in _main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 283 in wrap_session
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/main.py", line 330 in pytest_cmdline_main
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_callers.py", line 103 in _multicall
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_manager.py", line 120 in _hookexec
  File "/nix/store/xrlajzmcwarm0rhim9kdjbf50sw2pfas-python3.12-pluggy-1.5.0/lib/python3.12/site-packages/pluggy/_hooks.py", line 513 in __call__
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 175 in main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/_pytest/config/__init__.py", line 201 in console_main
  File "/nix/store/7p6gx66zzh7gk0094rxis9k5sli95yzf-python3.12-pytest-8.3.2/lib/python3.12/site-packages/pytest/__main__.py", line 9 in <module>
  File "<frozen runpy>", line 88 in _run_code
  File "<frozen runpy>", line 198 in _run_module_as_main

Extension modules: h5py._errors, h5py.defs, h5py._objects, h5py.h5, numpy.core._multiarray_umath, numpy.core._multiarray_tests, numpy.linalg._umath_linalg, numpy.fft._pocketfft_internal, numpy.random._common, numpy.random.bit_generator, numpy.random._bounded_integers, numpy.random._mt19937, numpy.random.mtrand, numpy.random._philox, numpy.random._pcg64, numpy.random._sfc64, numpy.random._generator, h5py.utils, h5py.h5t, h5py.h5s, h5py.h5ac, h5py.h5p, h5py.h5r, h5py._proxy, h5py._conv, h5py.h5z, h5py.h5a, h5py.h5d, h5py.h5ds, h5py.h5g, h5py.h5i, h5py.h5f, h5py.h5fd, h5py.h5pl, h5py.h5o, h5py.h5l, h5py._selector, shiboken2.shiboken2, PySide2.QtCore, PySide2.QtGui, PySide2.QtWidgets, PySide2.QtSvg, PySide2.QtPrintSupport, scipy._lib._ccallback_c, plotpy._scaler, skimage._shared.geometry, PIL._imaging, histogram2d, plotpy.histogram2d, scipy.special._ufuncs_cxx, scipy.special._ufuncs, scipy.special._specfun, scipy.special._comb, scipy.linalg._fblas, scipy.linalg._flapack, scipy.linalg.cython_lapack, scipy.linalg._cythonized_array_utils, scipy.linalg._solve_toeplitz, scipy.linalg._decomp_lu_cython, scipy.linalg._matfuncs_sqrtm_triu, scipy.linalg.cython_blas, scipy.linalg._matfuncs_expm, scipy.linalg._decomp_update, scipy.sparse._sparsetools, _csparsetools, scipy.sparse._csparsetools, scipy.sparse.linalg._dsolve._superlu, scipy.sparse.linalg._eigen.arpack._arpack, scipy.sparse.linalg._propack._spropack, scipy.sparse.linalg._propack._dpropack, scipy.sparse.linalg._propack._cpropack, scipy.sparse.linalg._propack._zpropack, scipy.sparse.csgraph._tools, scipy.sparse.csgraph._shortest_path, scipy.sparse.csgraph._traversal, scipy.sparse.csgraph._min_spanning_tree, scipy.sparse.csgraph._flow, scipy.sparse.csgraph._matching, scipy.sparse.csgraph._reordering, scipy.special._ellip_harm_2, scipy.integrate._odepack, scipy.integrate._quadpack, scipy.integrate._vode, scipy.integrate._dop, scipy.integrate._lsoda, scipy.optimize._group_columns, scipy._lib.messagestream, scipy.optimize._trlib._trlib, scipy.optimize._lbfgsb, _moduleTNC, scipy.optimize._moduleTNC, scipy.optimize._cobyla, scipy.optimize._slsqp, scipy.optimize._minpack, scipy.optimize._lsq.givens_elimination, scipy.optimize._zeros, scipy.optimize._highs.cython.src._highs_wrapper, scipy.optimize._highs._highs_wrapper, scipy.optimize._highs.cython.src._highs_constants, scipy.optimize._highs._highs_constants, scipy.linalg._interpolative, scipy.optimize._bglu_dense, scipy.optimize._lsap, scipy.spatial._ckdtree, scipy.spatial._qhull, scipy.spatial._voronoi, scipy.spatial._distance_wrap, scipy.spatial._hausdorff, scipy.spatial.transform._rotation, scipy.optimize._direct, scipy.ndimage._nd_image, _ni_label, scipy.ndimage._ni_label, mandelbrot, plotpy.mandelbrot, scipy.signal._sigtools, scipy._lib._uarray._uarray, scipy.signal._max_len_seq_inner, scipy.signal._upfirdn_apply, scipy.signal._spline, scipy.interpolate._fitpack, scipy.interpolate._dfitpack, scipy.interpolate._bspl, scipy.interpolate._ppoly, scipy.interpolate.interpnd, scipy.interpolate._rbfinterp_pythran, scipy.interpolate._rgi_cython, scipy.signal._sosfilt, scipy.signal._spectral, scipy.special.cython_special, scipy.stats._stats, scipy.stats._biasedurn, scipy.stats._levy_stable.levyst, scipy.stats._stats_pythran, scipy.stats._ansari_swilk_statistics, scipy.stats._sobol, scipy.stats._qmc_cy, scipy.stats._mvn, scipy.stats._rcont.rcont, scipy.stats._unuran.unuran_wrapper, scipy.signal._peak_finding_utils, PySide2.QtXml, PySide2.QtUiTools, PIL._imagingmath, skimage.measure._find_contours_cy (total: 145)
/nix/store/j9q99fln05lr27zf08p2hd73410mfr2i-pytest-check-hook/nix-support/setup-hook: line 53:  1139 Segmentation fault      (core dumped) /nix/store/pgb120fb7srbh418v4i2a70aq1w9dawd-python3-3.12.5/bin/python3.12 -m pytest
with PyQt5
=================================== FAILURES ===================================
__________________________ test_transform[False-500] ___________________________

N = 500, assemble_images = False

    @pytest.mark.parametrize("N", [500])
    @pytest.mark.parametrize("assemble_images", [False, True])
    def test_transform(N: int, assemble_images: bool) -> None:
        """Test image transforms
    
        Args:
            N: Image size (N x N)
            assemble_images: If True, assemble images (default: False)
        """
        with qt_app_context(exec_loop=True):
>           items = make_items(N)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:205: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:122: in make_items
    write_text_on_array(img, 0, 0, int(N / 15.0), str(dtype))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

data = array([[ 4,  4, 16, ..., 21, 18, 12],
       [ 3,  8, 18, ..., 20, 16, 10],
       [ 6, 12, 21, ..., 21, 15,  9],
    ...18,  9, 11, ..., 30, 30, 26],
       [14,  6, 12, ..., 26, 25, 21],
       [ 9,  4, 14, ..., 23, 21, 16]], dtype=uint8)
x = 0, y = 0, sz = 33, txt = "<class 'numpy.uint8'>", range = None

    def write_text_on_array(
        data: np.ndarray,
        x: int,
        y: int,
        sz: int,
        txt: str,
        range: tuple[int, int] | None = None,
    ) -> None:
        """Write text in image (in-place)
    
        Args:
            data: Image data
            x: X-coordinate of top-left corner
            y: Y-coordinate of top-left corner
            sz: Font size
            txt: Text to write
            range: Range of values to map to 0-255 (default: None)
        """
        arr = get_font_array(sz, txt)
        if arr is None:
            return
        if range is None:
            m, M = data.min(), data.max()
        else:
            m, M = range
        z = (float(M) - float(m)) * np.array(arr, float) / 255.0 + m
        arr = np.array(z, data.dtype)
        dy, dx = arr.shape
>       data[y : y + dy, x : x + dx] = arr
E       ValueError: could not broadcast input array from shape (33,693) into shape (33,500)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:101: ValueError
----------------------------- Captured stdout call -----------------------------
(40, 40)
___________________________ test_transform[True-500] ___________________________

N = 500, assemble_images = True

    @pytest.mark.parametrize("N", [500])
    @pytest.mark.parametrize("assemble_images", [False, True])
    def test_transform(N: int, assemble_images: bool) -> None:
        """Test image transforms
    
        Args:
            N: Image size (N x N)
            assemble_images: If True, assemble images (default: False)
        """
        with qt_app_context(exec_loop=True):
>           items = make_items(N)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:205: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:122: in make_items
    write_text_on_array(img, 0, 0, int(N / 15.0), str(dtype))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

data = array([[16, 18, 19, ...,  5, 10, 13],
       [19, 22, 24, ...,  6, 11, 16],
       [23, 27, 30, ...,  7, 13, 19],
    ...11, 12, 11, ...,  5,  7, 10],
       [12, 13, 13, ...,  5,  8, 10],
       [14, 15, 15, ...,  5,  8, 12]], dtype=uint8)
x = 0, y = 0, sz = 33, txt = "<class 'numpy.uint8'>", range = None

    def write_text_on_array(
        data: np.ndarray,
        x: int,
        y: int,
        sz: int,
        txt: str,
        range: tuple[int, int] | None = None,
    ) -> None:
        """Write text in image (in-place)
    
        Args:
            data: Image data
            x: X-coordinate of top-left corner
            y: Y-coordinate of top-left corner
            sz: Font size
            txt: Text to write
            range: Range of values to map to 0-255 (default: None)
        """
        arr = get_font_array(sz, txt)
        if arr is None:
            return
        if range is None:
            m, M = data.min(), data.max()
        else:
            m, M = range
        z = (float(M) - float(m)) * np.array(arr, float) / 255.0 + m
        arr = np.array(z, data.dtype)
        dy, dx = arr.shape
>       data[y : y + dy, x : x + dx] = arr
E       ValueError: could not broadcast input array from shape (33,693) into shape (33,500)

lib/python3.12/site-packages/plotpy/tests/items/test_transform.py:101: ValueError
----------------------------- Captured stdout call -----------------------------
(40, 40)
=========================== short test summary info ============================
FAILED lib/python3.12/site-packages/plotpy/tests/items/test_transform.py::test_transform[False-500] - ValueError: could not broadcast input array from shape (33,693) into shape ...
FAILED lib/python3.12/site-packages/plotpy/tests/items/test_transform.py::test_transform[True-500] - ValueError: could not broadcast input array from shape (33,693) into shape ...

I strongly suspect the test_transform issue is related to us still sticking to Numpy 1.26.

PierreRaybaut added a commit that referenced this issue Oct 1, 2024
Attempt to fix Test failures with test_transform on NixOS #20
@PierreRaybaut
Copy link
Contributor

Sorry for not getting back to you sooner - I was quite busy these days.

PyQt5
I have an idea for a workaround because I think that the test is failing because for an unknown reason (to me) the string representation of the NumPy data type is longer than expected and so it exceeds the width of the image array.
If that's the case, the change mentioned in the comment above should do the trick.

PySide2
We only support PyQt5, PyQt6 and PySide6... although it's not documented. Actually, the only officially supported bindings are PyQt5 but we try to follow the Qt6 bindings to ensure compatibility and anticipate future versions (after all, Qt5 will reach end-of-life on May 2025).

PierreRaybaut added a commit that referenced this issue Oct 1, 2024
May contribute fixing Test failures with test_transform on NixOS #20
@doronbehar
Copy link
Author

PyQt5
I have an idea for a workaround because I think that the test is failing because for an unknown reason (to me) the string representation of the NumPy data type is longer than expected and so it exceeds the width of the image array.
If that's the case, the change mentioned in the comment above should do the trick.

Thanks for that fix. It is confirmed. I didn't fully delve into the details there, but I suspect it is because we use Numpy 1.26, and not Numpy 2.x, with which you probably are used to run the tests. Don't ask why we are tied to using Numpy 1.x 😅.

PySide2
We only support PyQt5, PyQt6 and PySide6... although it's not documented. Actually, the only officially supported bindings are PyQt5 but we try to follow the Qt6 bindings to ensure compatibility and anticipate future versions (after all, Qt5 will reach end-of-life on May 2025).

With NixOS it is easy to test all of them :). I will only layout here which ones worked:

  • PyQt5
  • PyQt6
  • PySide6
  • PySide2: Same segmentation fault described above.

I guess it is very much OK. PySide2 and PyQt5 shouldn't be used for new, modern applications. It'd be nice to document that PySide2 is not supported, and hence it'd be "officially" not supported.

PierreRaybaut added a commit that referenced this issue Oct 2, 2024
@PierreRaybaut
Copy link
Contributor

PyQt5
I have an idea for a workaround because I think that the test is failing because for an unknown reason (to me) the string representation of the NumPy data type is longer than expected and so it exceeds the width of the image array.
If that's the case, the change mentioned in the comment above should do the trick.

Thanks for that fix. It is confirmed. I didn't fully delve into the details there, but I suspect it is because we use Numpy 1.26, and not Numpy 2.x, with which you probably are used to run the tests.

Great! 🥲

Don't ask why we are tied to using Numpy 1.x 😅.

I won't, the thread on discourse in pretty dissuasive 🙂.

With NixOS it is easy to test all of them :). I will only layout here which ones worked:

  • PyQt5
  • PyQt6
  • PySide6
  • PySide2: Same segmentation fault described above.

OK, so we are on the same wavelength. 👍

I guess it is very much OK. PySide2 and PyQt5 shouldn't be used for new, modern applications. It'd be nice to document that PySide2 is not supported, and hence it'd be "officially" not supported.

That is now documented in the README.md file of all PlotPyStack projects (PythonQwt, guidata and plotpy - see comment above).

Thanks for your work!

@doronbehar
Copy link
Author

That is now documented in the README.md file of all PlotPyStack projects (PythonQwt, guidata and plotpy - see comment above).

That looks great, thanks for that :).

Thanks for your work!

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants