From 842c08055bba426d1bbd129fac786760b2d71b86 Mon Sep 17 00:00:00 2001 From: Mark Harfouche Date: Fri, 11 Oct 2024 18:36:20 -0400 Subject: [PATCH 1/3] Help users understand why 6.8.0 just destroys things xref: https://github.com/spyder-ide/qtpy/issues/494 --- qtpy/__init__.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/qtpy/__init__.py b/qtpy/__init__.py index 5467fda5..4375f9ff 100644 --- a/qtpy/__init__.py +++ b/qtpy/__init__.py @@ -278,6 +278,11 @@ def __init__(self, *, missing_package=None, **superclass_kwargs): if API in PYSIDE6_API: try: from PySide6 import __version__ as PYSIDE_VERSION # analysis:ignore + if PYSIDE_VERSION == "6.8.0": + print( + "A known critical bug in PySide6 6.8.0 will cause your application to crash " + "see https://github.com/spyder-ide/qtpy/issues/494" + ) from PySide6.QtCore import __version__ as QT_VERSION # analysis:ignore QT5 = PYQT5 = False From b3c43a0da28f1383b1cf8c1beb607474aac7521b Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 11 Oct 2024 22:36:59 +0000 Subject: [PATCH 2/3] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- qtpy/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/qtpy/__init__.py b/qtpy/__init__.py index 4375f9ff..8633c35d 100644 --- a/qtpy/__init__.py +++ b/qtpy/__init__.py @@ -278,10 +278,11 @@ def __init__(self, *, missing_package=None, **superclass_kwargs): if API in PYSIDE6_API: try: from PySide6 import __version__ as PYSIDE_VERSION # analysis:ignore + if PYSIDE_VERSION == "6.8.0": print( "A known critical bug in PySide6 6.8.0 will cause your application to crash " - "see https://github.com/spyder-ide/qtpy/issues/494" + "see https://github.com/spyder-ide/qtpy/issues/494", ) from PySide6.QtCore import __version__ as QT_VERSION # analysis:ignore From 234b46cd910ed934bdbb61ad6d62fbe631b8876e Mon Sep 17 00:00:00 2001 From: Mark Harfouche Date: Fri, 11 Oct 2024 22:37:44 -0400 Subject: [PATCH 3/3] Update qtpy/__init__.py Co-authored-by: Carlos Cordoba --- qtpy/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qtpy/__init__.py b/qtpy/__init__.py index 8633c35d..697f23ae 100644 --- a/qtpy/__init__.py +++ b/qtpy/__init__.py @@ -281,8 +281,8 @@ def __init__(self, *, missing_package=None, **superclass_kwargs): if PYSIDE_VERSION == "6.8.0": print( - "A known critical bug in PySide6 6.8.0 will cause your application to crash " - "see https://github.com/spyder-ide/qtpy/issues/494", + "A known critical bug in PySide6 6.8.0 will cause your application to crash. " + "See https://github.com/spyder-ide/qtpy/issues/494", ) from PySide6.QtCore import __version__ as QT_VERSION # analysis:ignore