Try this:
Open a terminal shell.
Update your apt repositories, enter this command:
sudo apt-get update
Install the required dependency packages:
sudo apt-get install --assume-yes libcups2 cups libcups2-dev cups-bsd cups-client libcupsimage2-dev libdbus-1-dev build-essential ghostscript openssl libjpeg62-dev libsnmp-dev libtool libusb-1.0-0-dev wget python-imaging policykit-1 policykit-1-gnome python-qt4 python-qt4-dbus python-dbus python-gobject python-dev python-notify python python-reportlab libsane libsane-dev sane-utils xsane
Download the HPLIP tarball to your /home/user/Downloads directory:
https://sourceforge.net/projects/hplip/files/hplip/3.20.9/hplip-3.20.9.tar.gz/download
Go to the directory where you downloaded the HPLIP tarball:
cd ~/home/user/Downloads
Uncompress the tarball, enter this command:
tar xvfz hplip-3.20.9.tar.gz
This will create a directory with the same name as the tarball file.
Change your working directory to the hplip-3.20.9 directory.
cd hplip-3.20.9
Configure the development environment and checks that your system is ready to install HPLIP:
./configure --with-hpppddir=/usr/share/ppd/HP --libdir=/usr/lib64 --prefix=/usr --enable-udev-acl-rules --enable-qt4 --disable-libusb01_build --enable-doc-build --disable-cups-ppd-install --disable-foomatic-drv-install --disable-foomatic-ppd-install --disable-hpijs-install --disable-udev_sysfs_rules --disable-policykit --enable-cups-drv-install --enable-hpcups-install --enable-network-build --enable-dbus-build --enable-scan-build --enable-fax-build
Compile the HPLIP source, enter this command:
make
Run make install, enter this command:
sudo make install
Add user name to "lp" group:
sudo usermod -a -G lp $USER
Restart your PC (or) Logout and Login.
f you are going to be setting up a printer with USB and the printer is already plugged in, you will need to do one of the following:
Unlpug and re-plug in the USB printer, or Restart your PC.
Failure to do this will cause your USB printer to not be detected by HPLIP.
Continue using hp-setup:
sudo hp-setup
The first step is to select the printer connection type.
Next the setup tool will display printers detected (depending on the connection type selected)
The PPD files (drivers) which are most similar to your printer are displayed. Select the appropriate PPD file for your printer.
Enter your printer information.
Click FINISH to complete the printer setup process.
sudo apt-get install --assume-yes python-pyqt5
yourself?