I have two python programs running in the same virtual environment using PyQt6.5 on MacOS Sonoma 14.5 and python 3.11. Both execute just fine. One uses the updated enums for PyQt6 for QMessageBox as such: msgBox = QMessageBox(parent=self) msgBox.setText('WHOOPS - Must have at least one (1) joystick attached') msgBox.setStandardButtons(QMessageBox.StandardButton.Ok) msgBox.setIcon(QMessageBox.Icon.Warning) msgBox.exec() while the other uses the PyQt5 format: msgBox = QMessageBox(parent=self) msgBox.setText('Whoops - Upload destination not set.\n' + 'Save animation file to implicitly set or\n' + 'Edit metadata to explicitly set.') msgBox.setStandardButtons(QMessageBox.Ok) msgBox.setIcon(QMessageBox.Information) ret = msgBox.exec_() Both work and I don't understand why. I do not have pyqt5 installed: > pip freeze | grep -i pyqt PyQt6==6.5.1 PyQt6-Qt6==6.5.1 PyQt6-sip==13.5.1 > python >>> from PyQt5.QtCore import * Traceback (most recent call last): File "<stdin>", line 1, in <module> ModuleNotFoundError: No module named 'PyQt5' >>> I do know that if I am missing the StandardButton and Icon enum specifiers in the first program it fails. The only plausible thing I can think of is that there is a fallback in PyQt6 that says if everything is PyQt5-compatible it works but that doesn't make much sense. I expect to have to change the 40 QMessageBox instantiations to update to the PyQt6 form but haven't made the changes as the code seems to work fine. I have this code at the top of both programs to work for either PyQt5 or PyQt6: # Import local version of PyQt, either 5 or 6 usedPyQt = None try: # PyQt5 import block for all widgets from PyQt5.QtCore import * from PyQt5.QtGui import * from PyQt5.QtWidgets import * from PyQt5 import QtMultimedia as qm usedPyQt = 5 except: try: # PyQt6 import block for all widgets from PyQt6.QtCore import * from PyQt6.QtGui import * from PyQt6.QtWidgets import * from PyQt6 import QtMultimedia as qm usedPyQt = 6 except: sys.stderr.write('WHOOPS - Unable to find PyQt5 or PyQt6 - Quitting\n') exit(10) Any ideas? Continue reading...