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 8.0.0 and pyqt6 #2027

Open
opoplawski opened this issue Jun 11, 2023 · 1 comment
Open

Test failures with 8.0.0 and pyqt6 #2027

opoplawski opened this issue Jun 11, 2023 · 1 comment

Comments

@opoplawski
Copy link
Contributor

Updating the Fedora traitsui package and getting the following error:

test_simple_editor (traitsui.tests.editors.test_instance_editor.TestInstanceEditor.test_simple_editor) ... ok
test_simple_editor_modal (traitsui.tests.editors.test_instance_editor.TestInstanceEditor.test_simple_editor_modal) ... Unexpected error captured in sys excepthook. 
Traceback (most recent call last):
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/instance_editor.py", line 436, in edit_instance
    self._dialog_ui = self.value.edit_traits(
                      ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/site-packages/traits/has_traits.py", line 1812, in edit_traits
    return view.ui(
           ^^^^^^^^
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/view.py", line 457, in ui
    ui.ui(parent, kind)
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/ui.py", line 234, in ui
    self.rebuild(self, parent)
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/toolkit.py", line 176, in ui_modal
    ui_modal.ui_modal(ui, parent)
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/ui_modal.py", line 49, in ui_modal
    _ui_dialog(ui, parent, BaseDialog.MODAL)
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/ui_modal.py", line 67, in _ui_dialog
    BaseDialog.display_ui(ui, parent, style)
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/ui_base.py", line 320, in display_ui
    ui.control.exec_()
    ^^^^^^^^^^^^^^^^
AttributeError: '_StickyDialog' object has no attribute 'exec_'

ERROR

and then

test_expand_all (traitsui.tests.editors.test_tree_editor.TestTreeView.test_expand_all) ... Traceback (most recent call last):
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/tree_editor.py", line 1803, in sizeHint
    expanded, node, instance = self.editor._get_node_data(item)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/tree_editor.py", line 803, in _get_node_data
    if not qobject_is_valid(nid):
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/helper.py", line 282, in qobject_is_valid
    from sip import isdeleted
ModuleNotFoundError: No module named 'sip'
Fatal Python error: Aborted

Current thread 0x00007f7a8a7e0740 (most recent call first):
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/tree_editor.py", line 1588 in resizeEvent
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/ui_base.py", line 317 in display_ui
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/ui_live.py", line 72 in _ui_dialog
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/ui_live.py", line 52 in ui_live
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/qt/toolkit.py", line 168 in ui_live
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/ui.py", line 234 in ui
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/view.py", line 457 in ui
  File "/usr/lib64/python3.11/site-packages/traits/has_traits.py", line 1812 in edit_traits
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/testing/tester/ui_tester.py", line 105 in create_ui
  File "/usr/lib64/python3.11/contextlib.py", line 137 in __enter__
  File "/home/orion/BUILDROOT/python-traitsui-8.0.0-1.fc39.x86_64/usr/lib/python3.11/site-packages/traitsui/tests/editors/test_tree_editor.py", line 318 in test_expand_all
  File "/usr/lib64/python3.11/unittest/case.py", line 579 in _callTestMethod
  File "/usr/lib64/python3.11/unittest/case.py", line 623 in run
  File "/usr/lib64/python3.11/unittest/case.py", line 678 in __call__
  File "/usr/lib64/python3.11/unittest/suite.py", line 122 in run
  File "/usr/lib64/python3.11/unittest/suite.py", line 84 in __call__
  File "/usr/lib64/python3.11/unittest/suite.py", line 122 in run
  File "/usr/lib64/python3.11/unittest/suite.py", line 84 in __call__
  File "/usr/lib64/python3.11/unittest/suite.py", line 122 in run
  File "/usr/lib64/python3.11/unittest/suite.py", line 84 in __call__
  File "/usr/lib64/python3.11/unittest/suite.py", line 122 in run
  File "/usr/lib64/python3.11/unittest/suite.py", line 84 in __call__
  File "/usr/lib64/python3.11/unittest/runner.py", line 217 in run
  File "/usr/lib64/python3.11/unittest/main.py", line 274 in runTests
  File "/usr/lib64/python3.11/unittest/main.py", line 102 in __init__
  File "/usr/lib64/python3.11/unittest/__main__.py", line 18 in <module>
  File "<frozen runpy>", line 88 in _run_code
  File "<frozen runpy>", line 198 in _run_module_as_main

Extension modules: traits.ctraits, 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, PyQt6.QtCore, PyQt6.QtGui, PyQt6.QtWidgets, PyQt6.QtPrintSupport, PyQt6.QtTest, wx._core, numpy.linalg.lapack_lite, pandas._libs.tslibs.np_datetime, pandas._libs.tslibs.dtypes, pandas._libs.tslibs.base, pandas._libs.tslibs.nattype, pandas._libs.tslibs.timezones, pandas._libs.tslibs.tzconversion, pandas._libs.tslibs.ccalendar, pandas._libs.tslibs.fields, pandas._libs.tslibs.timedeltas, pandas._libs.tslibs.timestamps, pandas._libs.properties, pandas._libs.tslibs.offsets, pandas._libs.tslibs.parsing, pandas._libs.tslibs.conversion, pandas._libs.tslibs.period, pandas._libs.tslibs.vectorized, pandas._libs.ops_dispatch, pandas._libs.missing, pandas._libs.hashtable, pandas._libs.algos, pandas._libs.interval, pandas._libs.tslib, pandas._libs.lib, pandas._libs.hashing, pyarrow.lib, pyarrow._hdfsio, pandas._libs.ops, numexpr.interpreter, pyarrow._compute, bottleneck.move, bottleneck.nonreduce, bottleneck.nonreduce_axis, bottleneck.reduce, pandas._libs.arrays, pandas._libs.index, pandas._libs.join, pandas._libs.sparse, pandas._libs.reduction, pandas._libs.indexing, pandas._libs.internals, pandas._libs.writers, pandas._libs.window.aggregations, pandas._libs.window.indexers, pandas._libs.reshape, pandas._libs.tslibs.strptime, pandas._libs.groupby, pandas._libs.testing, pandas._libs.parsers, pandas._libs.json, PyQt6.QtSvg, PyQt6.QtSvgWidgets, PIL._imaging (total: 73)
/usr/bin/xvfb-run: line 181: 118782 Aborted                 (core dumped) DISPLAY=:$SERVERNUM XAUTHORITY=$AUTHFILE "$@" 2>&1

This is with Python 3.11.3 and PyQt6 6.5.1.

Tests run with:

+ export QT_API=pyqt6
+ QT_API=pyqt6
+ case $toolkit in
+ export ETS_TOOLKIT=qt
+ ETS_TOOLKIT=qt
+ export EXCLUDE_TESTS=wx
+ EXCLUDE_TESTS=wx
+ xvfb-run /usr/bin/python3 -s -X faulthandler -W default -m unittest discover -v traitsui
@corranwebster
Copy link
Contributor

corranwebster commented Jun 12, 2023

Thanks for the report - PyQt6 isn't fully supported yet, so this is a known issue.

Edit: see #1987 in particular

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