Unable to install hplip-3.24.4.run on Ubuntu 24.04 LTS

Asked by dave wagner

During the installation I get the following message:

"error: Ubuntu-24.04 version is not supported, so all dependencies may not be installed. However trying to install using Ubuntu-23.10 version packages."

My current hplip version is 3.22.10-7.

Is there going to be an updated version of HPLIP for Ubuntu 24.04?

Question information

Language:
English Edit question
Status:
Solved
For:
HPLIP Edit question
Assignee:
No assignee Edit question
Solved by:
dave wagner
Solved:
Last query:
Last reply:

This question was reopened

Revision history for this message
Manfred Hampl (m-hampl) said :
#1

There is already a modified package with version 3.23.12 in the Ubuntu repositories, which can be installed with the command
sudo apt install hplip hplip-gui

And for your question:
I assume that the next version of the *.run package will include additional code that it knows Ubuntu 24.04 (but I do not know when it will be published).

Revision history for this message
dave wagner (dave-wagner08) said :
#2

Thanks Manfred Hampl, that solved my question.

Revision history for this message
dave wagner (dave-wagner08) said :
#3

Hi Manfred,

I just now download the 3.23.12 and now I get the following errors during the installation:
How do I fix this error? BTW, thanks for your help.
ERROR:

~/Downloads$ sh hplip-3.23.12.run
Creating directory hplip-3.23.12
Verifying archive integrity... 100% All good.
Uncompressing HPLIP 3.23.12 Self Extracting Archive 100%
/home/dave/Downloads/hplip-3.23.12/base/g.py:305: SyntaxWarning: invalid escape sequence '\|'
  spinner = "\|/-\|/-"
/home/dave/Downloads/hplip-3.23.12/base/g.py:355: SyntaxWarning: invalid escape sequence '\d'
  m = re.search('python(\d(\.\d){0,2})', ext_path) #get the python version where the .so file is found
/home/dave/Downloads/hplip-3.23.12/base/logger.py:438: SyntaxWarning: invalid escape sequence '\<'
  elem_start = re.findall("(\<\W{0,1}\w+) ?", line)[0]
/home/dave/Downloads/hplip-3.23.12/base/logger.py:439: SyntaxWarning: invalid escape sequence '\]'
  elem_finished = re.findall("([?|\]\]]*\>)", line)[0]
/home/dave/Downloads/hplip-3.23.12/base/logger.py:441: SyntaxWarning: invalid escape sequence '\S'
  attrs = re.findall("(\S*?\=\".*?\")", line)
Traceback (most recent call last):
  File "/home/dave/Downloads/hplip-3.23.12/./install.py", line 38, in <module>
    from base.g import *
  File "/home/dave/Downloads/hplip-3.23.12/base/g.py", line 240, in <module>
    sys_conf = SysConfig()
               ^^^^^^^^^^^
  File "/home/dave/Downloads/hplip-3.23.12/base/g.py", line 185, in __init__
    ConfigBase.__init__(self, '/etc/hp/hplip.conf')
  File "/home/dave/Downloads/hplip-3.23.12/base/g.py", line 90, in __init__
    self.read()
  File "/home/dave/Downloads/hplip-3.23.12/base/g.py", line 131, in read
    self.conf.readfp(fp)
    ^^^^^^^^^^^^^^^^
AttributeError: 'ConfigParser' object has no attribute 'readfp'. Did you mean: 'read'?

Revision history for this message
Manfred Hampl (m-hampl) said :
#4

You should not try installing the hplip-3.23.12.run file from the HP web pages, because that gives errors like those that you see.
Just install the adapted package from the Ubuntu repositories with the apt command that I gave in my previous comment.

Revision history for this message
dave wagner (dave-wagner08) said :
#5

Finally, thanks.

Revision history for this message
Husni Sawalha (husnisawalha) said :
#6

Hi
I tried the file.run method also tried the hplip hplip-gui method but this is what I get in the terminal after running hp-setup:

error: Failed to connect to HPLIP site. Error code = 8
error: Failed to download http://hplip.sourceforge.net/hplip_web.conf.
error: Unable to load Qt4/Qt5 support. Is it installed?
Traceback (most recent call last):
  File "/usr/share/hplip/ui5/setupdialog.py", line 1385, in NextButton_clicked
    self.showDevicesPage()
  File "/usr/share/hplip/ui5/setupdialog.py", line 555, in showDevicesPage
    smart_install.disable(GUI_MODE, 'qt4')
  File "/usr/share/hplip/base/smart_install.py", line 238, in disable
    dialog.exec_()
    ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'exec_'

I tried many times and I don't know how to fix it.
Can you help?

Revision history for this message
dave wagner (dave-wagner08) said :
#7

Husni,

This is really your error "Ubuntu-24.04 version is not supported".

Download an older version 3.23.12 and it will install, works for me.

Revision history for this message
dave wagner (dave-wagner08) said :
#8

I forgot to say, remove old drivers first.

Revision history for this message
dave wagner (dave-wagner08) said :
#9

Also, the first reply above from Manfred worked for me.

Revision history for this message
Husni Sawalha (husnisawalha) said :
#10

Downloaded the file and when I tried to run it this happened:

Creating directory hplip-3.23.12
Verifying archive integrity... 100% All good.
Uncompressing HPLIP 3.23.12 Self Extracting Archive 100%
/home/husnisawalha/Desktop/hplip-3.23.12/base/g.py:305: SyntaxWarning: invalid escape sequence '\|'
  spinner = "\|/-\|/-"
/home/husnisawalha/Desktop/hplip-3.23.12/base/g.py:355: SyntaxWarning: invalid escape sequence '\d'
  m = re.search('python(\d(\.\d){0,2})', ext_path) #get the python version where the .so file is found
/home/husnisawalha/Desktop/hplip-3.23.12/base/logger.py:438: SyntaxWarning: invalid escape sequence '\<'
  elem_start = re.findall("(\<\W{0,1}\w+) ?", line)[0]
/home/husnisawalha/Desktop/hplip-3.23.12/base/logger.py:439: SyntaxWarning: invalid escape sequence '\]'
  elem_finished = re.findall("([?|\]\]]*\>)", line)[0]
/home/husnisawalha/Desktop/hplip-3.23.12/base/logger.py:441: SyntaxWarning: invalid escape sequence '\S'
  attrs = re.findall("(\S*?\=\".*?\")", line)
Traceback (most recent call last):
  File "/home/husnisawalha/Desktop/hplip-3.23.12/./install.py", line 38, in <module>
    from base.g import *
  File "/home/husnisawalha/Desktop/hplip-3.23.12/base/g.py", line 240, in <module>
    sys_conf = SysConfig()
               ^^^^^^^^^^^
  File "/home/husnisawalha/Desktop/hplip-3.23.12/base/g.py", line 185, in __init__
    ConfigBase.__init__(self, '/etc/hp/hplip.conf')
  File "/home/husnisawalha/Desktop/hplip-3.23.12/base/g.py", line 90, in __init__
    self.read()
  File "/home/husnisawalha/Desktop/hplip-3.23.12/base/g.py", line 131, in read
    self.conf.readfp(fp)
    ^^^^^^^^^^^^^^^^
AttributeError: 'ConfigParser' object has no attribute 'readfp'. Did you mean: 'read'?

Revision history for this message
Adalbert Hanßen (melolontha) said :
#11

Albeit the hplip packaged with the iso installation media of Xubuntu 24.04 LTS (2024-04-25) might not be complete, I could still install a HP Color Laserjet CM1312nfi MFP with both, the printer and the scanner part.

The printer has to be powered up during installation and in my case it was connected with the USB cable.

The problem is that you are not told clearly enough that you have to call the tool `hp-setup` (e.g. from a command line). It is a GUI program and it asks, whether the printer is connected by USB, Network or wireless 802.11 connection, then it lets you identify the device to be installed (if more than one is available), then it offers a Diriver-Plugin installation (with variants, I took the first one offered).

After the Diriver-Plugin installation it continues with a Setup Device dialog. This one was already filled out completely, probably becaus the device had been used before with another computer and the setup (Printer Setup and Fax Setup) had been filled out there before. I clicked on Add Printer there.

Apparently `hp-setup` analyzes inconsistencies in the installed programs and downloads and installs the missing parts. Only after step I was able to use the scanner part of the device. The printer part worked strait ahead. Before the crucial hp-install step, I also always got dependency problems.