Ask Your Question
1

qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""

asked 2020-06-11 23:45:03 -0600

Sofia.Mabrey gravatar image

updated 2020-06-12 02:32:03 -0600

gvdhoorn gravatar image

ROS 2 tutorial, Introducing turtlesim and rqt, instructs us to execute the following commands in two cmd windows (I am exercising on Windows 10 platform), ros2 run turtlesim turtlesim_node and ros2 run turtlesim turtle_teleop_key. Both commands fails with the error message:

qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Does this mean that I need to install Qt? If yes, why isn't Qt included in Foxy release, or, as part of install instruction? Could you provide the pointer where I can download free version of Qt? Once I install Qt, what else do I need to do so that the turtlesim will work successfully? Thanks a lot for the help.

My foxy installation was successful. At the end of the installation, both ros2 run demo_nodes_cpp talker and ros2 run demo_nodes_py listener worked. I am just started with the ros2 tutorial. The command set | findstr ROS produced the following:

ROS_DISTRO=foxy
ROS_LOCALHOST_ONLY=0
ROS_PYTHON_VERSION=3
ROS_VERSION=2
edit retag flag offensive close merge delete

Comments

I have the same issue I would like help getting this going. I also cant run rqt without getting plugin.xml non found errors

Dawson gravatar image Dawson  ( 2020-06-13 13:49:39 -0600 )edit

I have the exact same issue.

lzsyvj gravatar image lzsyvj  ( 2020-06-18 06:46:35 -0600 )edit
4

Found a fix: In Windows 10 set environment variable QT_QPA_PLATFORM_PLUGIN_PATH and point it to where PyQT5 DLL's were installed to, in my case C:\Python38\Lib\site-packages\PyQt5\Qt\plugins\platforms

lzsyvj gravatar image lzsyvj  ( 2020-06-18 19:37:45 -0600 )edit

I will try this tomorrow and see if it works for me too, thank you so much for sharing your fix!!

Dawson gravatar image Dawson  ( 2020-06-18 19:51:54 -0600 )edit

I mentioned your fix to the Microsoft team and it fixed the same issue on eloquent as well! thank you Izsyvj

Dawson gravatar image Dawson  ( 2020-06-19 17:22:27 -0600 )edit

It works for me too. Many thanks!

Sofia.Mabrey gravatar image Sofia.Mabrey  ( 2020-06-21 20:40:07 -0600 )edit

Same here! Thank you so much!!

Tortelenny gravatar image Tortelenny  ( 2020-06-30 04:47:09 -0600 )edit

This hasn't helped me, Can someone please help? Also I noticed that is says turtlesim is only available for Dashing onward? I'm using Foxy, is this going to hinder my ability to use turtlesim?

staticoli gravatar image staticoli  ( 2020-12-21 06:13:56 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2020-12-28 10:01:24 -0600

flargo gravatar image

I run into the same problem. In my case (Foxy on Windows 10), the solution was to set the variable QT_QPA_PLATFORM_PLUGIN_PATH to C:\dev\ros2_foxy\bin\platforms, the path to qwindows.dll delivered by ROS2. It was confusing since there is another qwindows.dll file under C:\Python38\Lib\site-packages\PyQt5\Qt\plugins\platforms as described by @Izsyvj.

edit flag offensive delete link more

Comments

This worked like a charm. Thank You :) I also set that up in the Power Shell profile settings such that I don't have to do it every time I open a new shell.

prabin_rath gravatar image prabin_rath  ( 2021-01-01 02:54:11 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

4 followers

Stats

Asked: 2020-06-11 23:45:03 -0600

Seen: 3,108 times

Last updated: Jun 12 '20