void-linux / void-packages

The Void source packages collection
https://voidlinux.org
Other
2.59k stars 2.16k forks source link

hplip 3.22.10 broke my printer setup #41695

Closed MechDR closed 1 year ago

MechDR commented 1 year ago

Is this a new report?

Yes

System Info

Void 6.1.4_1 i686

Package(s) Affected

hplip-3.22.10_1, hplip-gui-3.22.10_1

Does a report exist for this bug with the project's home (upstream) and/or another distro?

No response

Expected behaviour

The printer is supposed to print.

Actual behaviour

It doesn't.

Reverted back to using 3.22.6, everything works fine. Reverted back using snapshots, not from xbps cache, I regularly clean the cache, I don't have a lot of HDD space available on that rig.

Steps to reproduce

You have to have a HP LaserJet 1000, since I have no idea if it breaks anything else regarding other printers, I just have the one.

paper42 commented 1 year ago

This could possibly be fixed by https://github.com/void-linux/void-packages/pull/41193

MechDR commented 1 year ago

@paper42 CUPS got updated. I held back hplip and hplip-gui, but not CUPS. Everything works fine with the new version of CUPS and hplip 3.22.6.

This printer is shared. I print to it from other rigs (basically, this rig is a print server, among other things) using IPP and PS through CUPS. So, you can see CPU usage going up (it's an older P4 rig) when commands to print are issued from other PCs in the network, meaning the print server receives print jobs and it processes them (the printer is host based, ZJS, meaning the CPU has to do the hard work), but the communication with the printer, from the driver/filter onward is broken. Tried removing it and installing it again, no dice, doesn't work. Tried adding the printer through hplip and manually defining the PPD file, again, no luck... it just doesn't work. Jobs just get errored out and that's it.

paper42 commented 1 year ago

@dataCobra, you did the update, do you know something about this?

dataCobra commented 1 year ago

Sadly I've no clue why this is happening.

In the changelog is also no information about changes to printers.

dataCobra commented 1 year ago

I can't reproduce the issue.

On my end everything works fine and @biopsin had also no issues with his setup.

Could you check if the printer does show up in cups and hplip setup when you update the packages?

If so, could you please try to print a testpage directly from cups and one directly from hplip?

dataCobra commented 1 year ago

It would also be helpful to see the error messages that you get while trying things out that did work before

biopsin commented 1 year ago

Mind I dont use the -gui pkg. @MechDR can you test print from terminal?

dataCobra commented 1 year ago

Hello @MechDR,

we would like to help you.

I don't have a LaserJet 1000 so I'm not able to reproduce your issue. This is why I need your help to figure out what is wrong with the update.

Because my setup with a Officejet 9010 does work without any issues with hplip and hplip-gui.

MechDR commented 1 year ago

@dataCobra

Could you check if the printer does show up in cups and hplip setup when you update the packages?

It does show up as a printer in the printer manager, thus in CUPS and HPLIP as well. The printer is not removed, just errors out when you try and print to it.

If so, could you please try to print a testpage directly from cups and one directly from hplip?

That doesn't work as well, nothing works. The printer is there, it's listed as present and connected, but doesn't print anything sent to it.

It would also be helpful to see the error messages that you get while trying things out that did work before.

Will try that later on in the day, I'm kinda busy now. Will have to unhold the hplip package, but will make a snapshot before that, so that I can restore the working version after that.

@biopsin

can you test print from terminal?

I haven't tried that, don't even know the commands, will look them up, will try when I do the other tests after I unhold the package.

MechDR commented 1 year ago

@dataCobra @biopsin @paper42 OK, I managed to get it working after the update.

But, I couldn't get it to work through the system-config-printer UI or CUPS. I had to remove the printer, then add it again through hplip-setup. Then, it downloaded a new version the proprietary HP plugin, added the printer and everything just worked again (shrug).

The weird thing is, here's what it lists that it uses as the driver.

SCREENSHOT_24-01-2023_17-52-20

Note the version, says 3.22.6. Before I removed the printer and added it again through hplip-setup, it didn't work even if I changed the driver to 3.22.10. Now, if I change it to 3.22.10, it works (shrug).

SCREENSHOT_24-01-2023_17-57-14

SCREENSHOT_24-01-2023_17-58-01

SCREENSHOT_24-01-2023_17-59-21

So, it works regardless if I choose 3.22.6 or 3.22.10 (shrug).

My guess is hplip downloaded a new version of the proprietary plugin that's needed for this printer and it doesn't do that automatically when just upgrading the hplip install locally.

Thoughts?

biopsin commented 1 year ago

Your screenshot shows both 3.22.10. and 3.22.6. had hoped a update would have purged the latter. I'll point at /lib/hp/hplip.state file show previous version, HP driver borks when propietary plugins are detected and offsync. Probably when doing a manual install. If you dont mind starting fresh; you could try hplip-plugin package to be in sync for you instead of doing it manual.

MechDR commented 1 year ago

@biopsin No, I don't mind starting from scratch... at least not now, I was a bit busy previously.

So, the hplip-plugin package is just a repack of the proprietary plugin from HP's site I presume (no source is available). Not that it makes any difference (at least not to me) if it's open source or not, just asking. So, basically, if I install hplip and the hplip-plugin, everything should be in sync when doing updates, no need to remove the printer and run hplip-setup so that it can pull the new version of the plugin from their site, correct?

I'll remove the printer and hplip/hplip-gui and see if it removes hplip.state, if not, I'll remove it manually. Then install hplip and hplip-plugin and add the printer via hplip-setup, see if that works OK.

biopsin commented 1 year ago

That is correct. Just check /lib/hp folder is completetly removed after uninstalling. The hplip.state should be overwritten upon each update after, (it did so even when doing it manualy before hplip-plugin pkg was available. Cups still remembers your printer so you should not need to set it up again, however if printer driver has changed somehow, it too need a lookover. I hope this time it will resolve your issue unless there is something I have overlooked in the main or plugin pkg or as paper42 mentioned in his reply Edit: If you rely on the gui install that too

MechDR commented 1 year ago

@biopsin So, I uninstalled everything, deleted /lib/hp (it wasn't empty when I uninstalled hplip and hplip-gui) and then installed hplip again. Then I tried to install hplip-plugin, but apparently it's not in the repo... which kinda defeats the purpose of having it installed instead of having hplip pull the plugin from HP's site... if I have to repack the thing from xbps-src, what's the point, I have to manually do stuff instead of having the hplip-plugin updated automatically when hplip gets updated as well. The only scenario in which this "setup" (having hplip and hplip-gui in the default repos, but not hplip-plugin) makes sense is if I actually don't use the hplip-plugin package from xbps-src and just run hp-setup and let it download the plugin... it's easier than downloading the whole repo just to use the template to repackage the same plugin that hplip will download if it's ran again and the printer set up again.

I understand that there are legal reasons why Void can't hold the plugin in the repo, but having the plugin template... I mean... there might be a point in having the template, as a backup scenario, in case for whatever reason, hp-setup can't/won't download the plugin, but in any other case, I really don't see a point in having the hplip-plugin template/package in xbps-src.

Regardless, I cloned the repo, repackaged the hplip-plugin, installed it alongside hplip, removed and added the printer again (this time, yes, the 3.22.6 versions of the hplip drivers/filters were gone from the driver/filter list, the 3.22.10 versions were the only ones that were present), but... the printer won't print... the same thing again, it just errors out, except this time, it says that it's stopped, not idle after it errors out, and the print job just gets deleted automatically. Have no idea why it behaves a bit differently than the previous scenario. In any case, I decided to try and remove hplip-plugin, remove the printer again and add it through hp-setup, so that hplip can download the plugin directly from the site (of course, it warns you that Void is not on the list of supported distros). And this combo, worked. Ran hp-setup -i, it downloaded the plugin, made the adequate settings for the printer (printer name, location and whatnot) and it just worked, out of the box.

So, basically, the printer doesn't work with the repacked version of the plugin, but does work if hp-setup downloads and installs it from HPs site.

biopsin commented 1 year ago

Thank you for trying it out and unfortunatly restricted packages are a bit hasle but it is what it is. wait a minute the plugin is nonfree, so just add the nonfree repo to get it without using xbps-src Since there is not much to go on without error logs, Im out of ideas. The only thing would be to diff the /lib/hp folder between both methods and see what might be missing. For me the printer works fine with hplip main package, but I need the proprietary pkg to scan.

MechDR commented 1 year ago

@biopsin I have the nonfree repo installed, it's not there (shrug).

How do I provide error logs? lpr's verbose features were removed in earlier versions and debug features are not present in the version I have. Does it generate error logs? Or maybe error logs from the print queue... where do they reside?

On a side note, not related, I think the plugin is just a bunch of binaries spliced up in single plugin that provides support for various proprietary printing/scanning technologies. Correct me if I'm wrong.

EDIT: My guess why it isn't in the nonfree repo is that it can't be distributed from any other place except HPs site (haven't read the license, but my main guess would be this). In that case, the hplip-plugin package can be made to not actually hold the plugin binary in the package, but rather download it and install it on the fly from HPs site... like a meta package... sort of :P :D.

MechDR commented 1 year ago

I think we can mark this as solved, since it's not Void's fault this is happening, it's a combination of things, in which I believe that the biggest problem is that HPLIP is just not that well designed and that Void is not officially supported on HPs list of distros.