Bug 50535 - cups-filters: error "Can't detect file type" with some HP drivers & solution
cups-filters: error "Can't detect file type" with some HP drivers & solution
Status: NEW
Product: UCS
Classification: Unclassified
Component: Printserver
UCS 4.4
Other Linux
: P5 normal (vote)
: ---
Assigned To: UCS maintainers
UCS maintainers
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2019-11-22 12:38 CET by Moritz Bunkus
Modified: 2019-11-22 14:08 CET (History)
2 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 5: Major Usability: Impairs usability in key scenarios
Who will be affected by this bug?: 3: Will affect average number of installed domains
How will those affected feel about the bug?: 3: A User would likely not purchase the product
User Pain: 0.257
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional): Regression
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Moritz Bunkus 2019-11-22 12:38:38 CET
## Problem

This is a regression from UCS 4.2.

I recently updated several UCS systems from 4.2 to 4.4. The customer uses several HP printers. After the update printing with them wasn't possible anymore as CUPS could not determine the file type in question. /var/log/cups/error_log shows errors such as:

D [21/Nov/2019:07:40:16 +0100] [Job 216588] Cannot process \"<STDIN>\": Unknown filetype.
D [21/Nov/2019:07:40:16 +0100] [Job 216588] Process is dying with \"Could not print file <STDIN>
D [21/Nov/2019:07:40:16 +0100] [Job 216588] \", exit stat 2

The file in question is a PDF wrapped in PCL markup (as determined by "file /var/spool/cups/…").

This is a known bug in certain versions of cups-filters. Here's the corresponding bug report for Debian[1].

As mentioned in the report, newer versions of cups-filters don't show the behavior anymore. Unfortunately it isn't possible to compile e.g. the Debian packages of cups-filters 1.21.6 on UCS 4.4 as cups-filters 1.21 requires newer versions of certain packages (e.g. libpdf; verified via the package's configure script, not just via package dependencies).

## Solution/Workaround

So what I did is to retrieve the commit from the cups-filters git repository[2] that fixes the issue in gstoraster: revision 0c5bde0f8e4d38b46ee72aaa8ab06c7d00c689f1[3]. Then I re-built cups-filters 1.11.6 from the UCS sources with the additional patch based on the aforementioned commit (I've left out the hunk modifying NEWS).

That package builds fine, and the resulting gstoraster binary accepts the files again. Printing works as expected.

## My request

Giving this is a rather serious regression for anyone using certain HP printer drivers, I'd like to ask you to provide patched cups-filters packages that include the aforementioned patch. Carrying my own patched version of certain packages wreaks havoc with updatability.

Thanks for considering.

[1]  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=886335
[2]  https://github.com/OpenPrinting/cups-filters/commits/master
[3]  https://github.com/OpenPrinting/cups-filters/commit/0c5bde0f8e4d38b46ee72aaa8ab06c7d00c689f1