No module named PyQt5

When I try to open hp-toolbox or hp-uiscan .
It doesn’t open .I can see no module named PyQt5 in logs .how do I fix this issue?

Did you try installing PyQt5 · PyPI?

yes but log shows same error

Can you provide the relevant log?

im not using cl .i will see if i can install it

Okay. But maybe stay with the distribution you are already satisfied with.
Anyway, with “log” I meant the output python gave you describing the error when trying to run the application you were trying to run.

i think installing it fixed it but hp-uiscan has no icon

Maybe it doesn’t includes an icon?

Same issue here when typing in terminal hp-toolbox :

$ hp-toolbox
/usr/share/hplip/base/utils.py:2061: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if weburl is "" or weburl is None:

HP Linux Imaging and Printing System (ver. 3.19.8)
HP Device Manager ver. 15.0

Copyright (c) 2001-18 HP Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

error: No module named 'PyQt5.sip'

@erik pip3 install PyQt5.sip

I tried :

$ pip3 install PyQt5-sip
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: PyQt5-sip in ./.local/lib/python3.10/site-packages (12.9.1)

I still get the same error message with hp-toolbox :

error: No module named 'PyQt5.sip'

try sudo pip3 install PyQt5.sip (this should install it in /usr )

If pip fails, try installing with conda.

I was able to install PyQt5.sip but I still can’t launch HP Device Manager from terminal or from GNOME Shell.

Now I get this error message when typing hp-toolbox :

$ hp-toolbox
/usr/share/hplip/base/utils.py:2061: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if weburl is "" or weburl is None:

HP Linux Imaging and Printing System (ver. 3.19.8)
HP Device Manager ver. 15.0

Copyright (c) 2001-18 HP Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

/usr/share/hplip/installer/core_install.py:2060: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if home_dir is "":
/usr/share/hplip/ui5/devmgr_ext.py:15: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if self.latest_available_version is not "":
/usr/share/hplip/ui5/devmgr_ext.py:37: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if self.latest_available_version is not "":
Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
Traceback (most recent call last):
  File "/usr/bin/hp-toolbox", line 280, in <module>
    toolbox = ui.DevMgr5(__version__, device_uri,  None)
  File "/usr/share/hplip/ui5/devmgr5.py", line 235, in __init__
    core =  CoreInstall(MODE_CHECK)
  File "/usr/share/hplip/installer/core_install.py", line 240, in __init__
    self.passwordObj = password.Password(ui_mode)
  File "/usr/share/hplip/base/password.py", line 113, in __init__
    self.__readAuthType()  # self.__authType
  File "/usr/share/hplip/base/password.py", line 135, in __readAuthType
    distro_name = get_distro_name().lower()
  File "/usr/share/hplip/base/password.py", line 81, in get_distro_name
    os_name = platform.dist()[0]
AttributeError: module 'platform' has no attribute 'dist'

I was able to install my HP printer in terminal with hp-setup anyways, but it would be convenient to have the GUI HP Device Manager working :unamused:

platform.dist is historic. it is now replaced by distro. you may also use platform.freedesktop_os_release.

HP Linux Imaging and Printing System is at version 3.19.8 on clear linux. latest version is 3.21.12 and can be found → HP Linux Imaging and Printing - Browse /hplip/3.21.12 at SourceForge.net