Cfclient installation issue

Post here to get support
Post Reply
yeokiwi
Beginner
Posts: 3
Joined: Sat Sep 28, 2019 1:35 am

Cfclient installation issue

Post by yeokiwi »

Hi,

I encountered the following error when I attempted to run cfclient. I followed the instructions in https://www.bitcraze.io/documentation/r ... stallation

Whichever way, by running pip3 install cfclient or install from source, i will encounter the following runtime issue.

o:~$ cfclient
INFO:cfclient.gui:Disabling STL printouts
INFO:cfclient.utils.input.inputreaders:Input readers: ['linuxjsdev', 'pysdl2']
INFO:cfclient.utils.input.inputreaders:Successfully initialized [linuxjsdev]
INFO:cfclient.utils.input.inputreaders:Could not initialize [pysdl2]: No SDL2 support on Linux
INFO:cfclient.utils.input.inputinterfaces:Found interfaces: ['leapmotion', 'wiimote', 'zmqpull']
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [leapmotion]: Leap Motion library probably not installed (No module named 'leapsdk')
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [wiimote]: Missing cwiid (wiimote) driver No module named 'cwiid'
INFO:cfclient.utils.config:Dist config read from /home/o/.local/lib/python3.8/site-packages/cfclient/configs/config.json
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [zmqpull]: ZMQ input disabled in config file
===== 2021.07.11 13:07:34 =====
Traceback (most recent call last):
File "/home/o/.local/bin/cfclient", line 8, in <module>
sys.exit(main())
File "/home/o/.local/lib/python3.8/site-packages/cfclient/gui.py", line 164, in main
from .ui.main import MainUI
File "/home/o/.local/lib/python3.8/site-packages/cfclient/ui/main.py", line 34, in <module>
import cfclient.ui.tabs
File "/home/o/.local/lib/python3.8/site-packages/cfclient/ui/tabs/__init__.py", line 41, in <module>
from .locopositioning_tab import LocoPositioningTab
File "/home/o/.local/lib/python3.8/site-packages/cfclient/ui/tabs/locopositioning_tab.py", line 40, in <module>
from PyQt5.QtGui import QMessageBox
ImportError: cannot import name 'QMessageBox' from 'PyQt5.QtGui' (/home/o/.local/lib/python3.8/site-packages/PyQt5/QtGui.abi3.so)
o:~$
yeokiwi
Beginner
Posts: 3
Joined: Sat Sep 28, 2019 1:35 am

Re: Cfclient installation issue

Post by yeokiwi »

After some troubleshooting,

I need to edit the following in locopositioning_tab.py
from PyQt5.QtGui import QMessageBox
from PyQt5.QtGui import QLabel

to
from PyQt5.QtWidgets import QMessageBox
from PyQt5.QtWidgets import QLabel

for the cfclient to run.

Apparently, it only happened on my newly installed environment... weird.

Rgds

yeokiwi wrote: Sun Jul 11, 2021 5:47 am Hi,

I encountered the following error when I attempted to run cfclient. I followed the instructions in https://www.bitcraze.io/documentation/r ... stallation

Whichever way, by running pip3 install cfclient or install from source, i will encounter the following runtime issue.

o:~$ cfclient
INFO:cfclient.gui:Disabling STL printouts
INFO:cfclient.utils.input.inputreaders:Input readers: ['linuxjsdev', 'pysdl2']
INFO:cfclient.utils.input.inputreaders:Successfully initialized [linuxjsdev]
INFO:cfclient.utils.input.inputreaders:Could not initialize [pysdl2]: No SDL2 support on Linux
INFO:cfclient.utils.input.inputinterfaces:Found interfaces: ['leapmotion', 'wiimote', 'zmqpull']
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [leapmotion]: Leap Motion library probably not installed (No module named 'leapsdk')
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [wiimote]: Missing cwiid (wiimote) driver No module named 'cwiid'
INFO:cfclient.utils.config:Dist config read from /home/o/.local/lib/python3.8/site-packages/cfclient/configs/config.json
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [zmqpull]: ZMQ input disabled in config file
===== 2021.07.11 13:07:34 =====
Traceback (most recent call last):
File "/home/o/.local/bin/cfclient", line 8, in <module>
sys.exit(main())
File "/home/o/.local/lib/python3.8/site-packages/cfclient/gui.py", line 164, in main
from .ui.main import MainUI
File "/home/o/.local/lib/python3.8/site-packages/cfclient/ui/main.py", line 34, in <module>
import cfclient.ui.tabs
File "/home/o/.local/lib/python3.8/site-packages/cfclient/ui/tabs/__init__.py", line 41, in <module>
from .locopositioning_tab import LocoPositioningTab
File "/home/o/.local/lib/python3.8/site-packages/cfclient/ui/tabs/locopositioning_tab.py", line 40, in <module>
from PyQt5.QtGui import QMessageBox
ImportError: cannot import name 'QMessageBox' from 'PyQt5.QtGui' (/home/o/.local/lib/python3.8/site-packages/PyQt5/QtGui.abi3.so)
o:~$
kimberly
Bitcraze
Posts: 1050
Joined: Fri Jul 06, 2018 11:13 am

Re: Cfclient installation issue

Post by kimberly »

Interesting! Probably good to make an issue out of this.

In which OS did you run this (window/linux/mac)? and which version of python do you have?
absfd
Beginner
Posts: 1
Joined: Wed Jul 14, 2021 3:00 am

Re: Cfclient installation issue

Post by absfd »

I had this issue when installing on windows, I needed to change locopositioning_tab.py as well as lighthouse_tab.py from from PyQt5.QtGui import QMessageBox to from PyQt5.QtWidgets import QMessageBox
kimberly
Bitcraze
Posts: 1050
Joined: Fri Jul 06, 2018 11:13 am

Re: Cfclient installation issue

Post by kimberly »

Windows is not the only problem here... we also saw this on linux as well.

Currently we are working on a new release of the cfclient, so try again reinstalling it at the end of this week!
kimberly
Bitcraze
Posts: 1050
Joined: Fri Jul 06, 2018 11:13 am

Re: Cfclient installation issue

Post by kimberly »

perhaps this was related?
yeokiwi
Beginner
Posts: 3
Joined: Sat Sep 28, 2019 1:35 am

Re: Cfclient installation issue

Post by yeokiwi »

absfd wrote: Wed Jul 14, 2021 3:03 am I had this issue when installing on windows, I needed to change locopositioning_tab.py as well as lighthouse_tab.py from from PyQt5.QtGui import QMessageBox to from PyQt5.QtWidgets import QMessageBox
Oh yes.. lighthouse_tab.py too.

And yes, they are related.
Windows is not the only problem here... we also saw this on linux as well.

Currently we are working on a new release of the cfclient, so try again reinstalling it at the end of this week!
Great!
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: Cfclient installation issue

Post by arnaud »

This is now fixed. It was a bug that only recently started causing problem.

I have pushed the fix yesterday to github and release the client 2021.6.1 today. so both "pip3 install cfclient" and "pip3 install -e ." from source should work now.
Post Reply