Details
Description
Using a hello world example (together with Python 3.9 or 3.12) like below
main.py:
import sys from PySide6.QtGui import QGuiApplication from PySide6.QtQml import QQmlApplicationEngine app = QGuiApplication(sys.argv) engine = QQmlApplicationEngine() engine.quit.connect(app.quit) engine.load('main.qml') sys.exit(app.exec())
main.qml:
import QtQuick 2.15 import QtQuick.Controls 2.15 ApplicationWindow { visible: true width: 600 height: 500 title: "HelloApp" Text { anchors.centerIn: parent text: "Hello World" font.pixelSize: 24 } }
Steps:
- pip install Pyside6==6.6.3
- python main.py
Result:
> python main.py
QQmlApplicationEngine failed to load component
file:///C:/Users/User/hello/main.qml:2:1: module "QtQuick.Controls" version 6.6 cannot be imported because:
module "QtQuick.Controls.Windows" version 6.6 cannot be imported because:
Cannot load library C:\Users\User\hello\hello\lib\site-packages\PySide6\qml\QtQuick\Controls\Basic\qtquickcontrols2basicstyleplugin.dll: The specified module could not be found.
Debugging with loader snaps reveals that it cannot load that dll because it cannot find Qt6QuickControls2Basic.dll. Searching through the PySide6 folder in site-packages seems to confirm that this dll is in fact not there.
Attachments
Issue Links
- is duplicated by
-
PYSIDE-2657 Basic QML QtQuick Controls broken since 6.6.3 release on PyPi
- Closed
-
PYSIDE-2661 [Reg 6.6.2 -> 6.6.3] Qt Quick Controls DLLs are missing from pip packages
- Closed
- relates to
-
QTBUG-121643 qt6-declarative: possible build-time race condition around qmlcachegen
- Closed
For Gerrit Dashboard: PYSIDE-2655 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
551648,7 | create_wheels: Add Qt quick controls style libraries | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
551688,2 | create_wheels: Add Qt quick controls style libraries | 6.7 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
551689,3 | create_wheels: Add Qt quick controls style libraries | 6.6.3.1 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
551690,3 | create_wheels: Add Qt quick controls style libraries | 6.6 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
552074,2 | create_wheels: Add Qt quick controls style libraries | tqtc/6.6.3.1 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
552430,2 | testwheel.py: Test a Qt Quick Controls example | dev | qt/qtqa | Status: MERGED | +2 | 0 |
552491,2 | testwheel.py: Test a Qt Quick Controls example | master | qt/qtqa | Status: MERGED | +2 | 0 |