Wrong modifier key (GroupSwitchModifier) after upgrade to 6.1.2
-
I'm using PyQt6 on Linux with Xorg. I have the following example program:
import sys from PyQt6 import QtCore, QtWidgets class MainWindow(QtWidgets.QMainWindow): def __init__(self, app): super().__init__() self.show() def mousePressEvent(self, event): print(event.modifiers()) return super().mousePressEvent(event) app = QtWidgets.QApplication(sys.argv) win = MainWindow(app) app.exec()
With the 6.1.1. installation (PyQt6==6.1.1, PyQt6-Qt6==6.1.1) I get the expected results when clicking, for example:
KeyboardModifier.NoModifier KeyboardModifier.ControlModifier KeyboardModifier.AltModifier KeyboardModifier.ShiftModifier
After upgrade to the latest versions, I get this instead for the same mouse/key presses:
KeyboardModifier.GroupSwitchModifier KeyboardModifier.GroupSwitchModifier|ControlModifier KeyboardModifier.GroupSwitchModifier|AltModifier KeyboardModifier.GroupSwitchModifier|ShiftModifier
Anyone knows what's up with that? Aso, upon inspecting this, I noticed that an upgrade to current yields these version numbers: PyQt6==6.1.1, PyQt6-Qt6==6.1.2, wich are indeed the latest releases on Pypi for these packages.
Trying to pin the PyQt6 version still always pulls the latest PyQt6-Qt6 package, for example:
> pip install PyQt6==6.1.0 ... PyQt6==6.1.0 PyQt6-Qt6==6.1.2
So I have to pin PyQt6-Qt6 as well to get a specific version.. It would have assumed that these two packages have the same release cycle and that installing PyQt6 always pulls the matching version?
-
Hi and welcome to devnet,
That indeed looks strange.
You should check the bug report system to see if there's already something there and if not, please open a ticket.
-
Thanks !
Can you share the ticket link ?
It will make it easier to find. -