Reputation: 11
I`m desperating since days, since I tried anything I found on the web since nearly 1 week now. I want to use the QtCreator 6.2.3 for making GUI designs in Python language, so I use the python-project options. Everytime I try to run any .py-file (especially for converting the .ui-data in the project to a .py-file for my RaspberryPi later on) I get this error:
qt.qpa.plugin: Could not load the Qt platform plugin "windows" in "" even though it was found. This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem. Available platform plugins are: direct2d, minimal, offscreen, windows.
What I already tried:
The problem is: There are several directories with those .dll's and I don't know how/where I should use the deployment-tool, or where should I take the .dll's from and put them in.
Here is what I got from listDLLs.exe after the problem.
Command line: E:\Programme\Qt\Tools\QtCreator\bin\\qtcreator_processlauncher \\.\pipe\C:/Users/LucaGraebenteich/AppData/Local/Temp/QtCreator-OQkBfq/launcher-6256
Base Size Path
0x0000000058120000 0x34000 E:\Programme\Qt\Tools\QtCreator\bin\qtcreator_processlauncher.exe
0x0000000097f50000 0x1f5000 C:\Windows\SYSTEM32\ntdll.dll
0x0000000097e50000 0xbe000 C:\Windows\System32\KERNEL32.DLL
0x0000000095bf0000 0x2c9000 C:\Windows\System32\KERNELBASE.dll
0x0000000097390000 0x1a1000 C:\Windows\System32\USER32.dll
0x0000000095670000 0x22000 C:\Windows\System32\win32u.dll
0x0000000097260000 0x2b000 C:\Windows\System32\GDI32.dll
0x0000000061550000 0x15d000 E:\Programme\Qt\Tools\QtCreator\bin\Qt6Network.dll
0x000000005ee50000 0x53f000 E:\Programme\Qt\Tools\QtCreator\bin\Qt6Core.dll
0x0000000095940000 0x10b000 C:\Windows\System32\gdi32full.dll
0x0000000095b50000 0x9d000 C:\Windows\System32\msvcp_win.dll
0x0000000095a50000 0x100000 C:\Windows\System32\ucrtbase.dll
0x0000000096180000 0xac000 C:\Windows\System32\ADVAPI32.dll
0x0000000095fa0000 0x9e000 C:\Windows\System32\msvcrt.dll
0x00000000971d0000 0x6b000 C:\Windows\System32\WS2_32.dll
0x0000000096800000 0x9b000 C:\Windows\System32\sechost.dll
0x000000003ed40000 0x8e000 C:\Windows\SYSTEM32\MSVCP140.dll
0x0000000072f30000 0xc000 C:\Windows\SYSTEM32\VCRUNTIME140_1.dll
0x00000000966d0000 0x12a000 C:\Windows\System32\RPCRT4.dll
0x0000000097780000 0x12a000 C:\Windows\System32\ole32.dll
0x000000003ed20000 0x1b000 C:\Windows\SYSTEM32\VCRUNTIME140.dll
0x00000000845a0000 0x1d000 C:\Windows\SYSTEM32\MPR.dll
0x0000000096a90000 0x73f000 C:\Windows\System32\SHELL32.dll
0x0000000096290000 0x355000 C:\Windows\System32\combase.dll
0x0000000095570000 0x2e000 C:\Windows\SYSTEM32\USERENV.dll
0x0000000096040000 0xcd000 C:\Windows\System32\OLEAUT32.dll
0x0000000094b00000 0xcc000 C:\Windows\SYSTEM32\DNSAPI.dll
0x0000000094ac0000 0x3b000 C:\Windows\SYSTEM32\IPHLPAPI.DLL
0x000000007cb30000 0xc000 C:\Windows\SYSTEM32\Secur32.dll
0x000000008cd90000 0x108000 C:\Windows\SYSTEM32\WINHTTP.dll
0x000000007f270000 0x18000 C:\Windows\SYSTEM32\NETAPI32.dll
0x00000000902e0000 0xa000 C:\Windows\SYSTEM32\VERSION.dll
0x000000008aaf0000 0x27000 C:\Windows\SYSTEM32\WINMM.dll
0x0000000072f00000 0x9000 C:\Windows\SYSTEM32\MSVCP140_1.dll
0x0000000095030000 0xc000 C:\Windows\SYSTEM32\CRYPTBASE.DLL
0x0000000095530000 0x31000 C:\Windows\SYSTEM32\SSPICLI.DLL
0x0000000094bd0000 0xc000 C:\Windows\SYSTEM32\NETUTILS.DLL
0x0000000087510000 0x28000 C:\Windows\SYSTEM32\SRVCLI.DLL
0x0000000097750000 0x30000 C:\Windows\System32\IMM32.DLL
0x0000000097290000 0x8000 C:\Windows\System32\NSI.dll
0x00000000930b0000 0x9e000 C:\Windows\system32\uxtheme.dll
0x0000000096950000 0xad000 C:\Windows\System32\shcore.dll
0x0000000095f10000 0x83000 C:\Windows\System32\bcryptPrimitives.dll
Is anyone familiar with the problem? Please let me know if I can give you any further information for a solution.
Kind regards, Luca
Upvotes: 0
Views: 8117
Reputation: 40
I had the same problem using virtual environment and pyqt5 in windows 10/11. I solved it by creating plugins path
set "QT_PLUGIN_PATH=%VIRTUAL_ENV%\Lib\site-packages\PyQt5\Qt5\plugins"
and I added this to the end of virtualenv activation script (i.e. %VIRTUAL_ENV%\Scripts\activate.bat)
@set "QT_PLUGIN_PATH=%VIRTUAL_ENV%\Lib\site-packages\PyQt5\Qt5\plugins"
I hope this will help someone not to waste time on the problem.
Upvotes: 0
Reputation: 381
if you are using anaconda/miniconda with matplotlib installed. you'll have to install uninstall anaconda/miniconda and use miniconda without matplotlib.
it has be a know issue here enter link description here
Upvotes: 2
Reputation: 11
Update for all that have the same problem:
What worked for me after all was changing the environment of the QtCreator-project to system environment. The standard selected environment is the build environment.And I spared QtCreator version 6+, with QtCreator5 it's working with that for now. (The picture is in German version, but I hope you can compare the correct menus)
So I start my Python-projects in QtCreator 5.15.2 with PySide2. I'm working in a virtual environment of anaconda3 with Python 3.9.7, there I went sure to have installed all PySide and pyqt-related packages (PySide2, PySide6, PyQt5, pyqt5-tools, pyqt, qtpy). All of them with pip3 and --user in addition as there were permissions needed.
Probably that doesn't make sense in every way and some steps here may be trivial, but I myself am still pretty new to the programming world, so maybe someone else can get some value from this info.
But if someone can explain to me the other problems (build environment not working(only system environment)enter image description here, Qt6 not working) I'd be very glad!
Upvotes: 1