[cups.development] Troubles with CUPS > 1.3.9 and Qt 4.x applications

Ozan Çağlayan ozan at pardus.org.tr
Thu Jun 25 14:34:37 PDT 2009


Hi,

We're having some troubles with CUPS > 1.3.9 and Qt 4.x applications in Pardus Linux[0]. Printing from Gnome applications, lpr, pycups, cups web interface are all working well except from Qt4 applications.

I tried with:

- A patched CUPS 1.3.10 which contains fixes for:
  STR 3167:
    * http://cvs.fedoraproject.org/viewvc/F-10/cups/cups-str3167.patch?view=co
  Accept "Host: ::1":
    * http://cvs.fedoraproject.org/viewvc/F-10/cups/cups-localhost-ipv6.patch?view=co

- A vanilla 1.3.10,
- A vanilla branch-1.3.x,
- A vanilla 1.4rc1

with:

- completely removing the ServerName localhost line from /etc/cups/client.conf,
- leaving it, 
- replacing it with ServerName /var/run/cups/cups.sock

None of them works. I'll try to describe the problem:

I open kwrite or okular or konqueror, or a very simple 5-line Qt4 application which prints "Hello world!". Here's the cups error_log:

D [25/Jun/2009:20:09:43 -0400] cupsdAcceptClient: 9 from localhost (Domain)
D [25/Jun/2009:20:09:43 -0400] Report: clients=1
D [25/Jun/2009:20:09:43 -0400] Report: jobs=3
D [25/Jun/2009:20:09:43 -0400] Report: jobs-active=0
D [25/Jun/2009:20:09:43 -0400] Report: printers=1
D [25/Jun/2009:20:09:43 -0400] Report: printers-implicit=0
D [25/Jun/2009:20:09:43 -0400] Report: stringpool-string-count=1087
D [25/Jun/2009:20:09:43 -0400] Report: stringpool-alloc-bytes=7952
D [25/Jun/2009:20:09:43 -0400] Report: stringpool-total-bytes=22312
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] CUPS-Get-Printers
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] CUPS-Get-Classes
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] CUPS-Get-Default
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdCloseClient: 9
D [25/Jun/2009:20:09:43 -0400] cupsdAcceptClient: 9 from localhost (Domain)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] CUPS-Get-Printers
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] CUPS-Get-Classes
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] CUPS-Get-Default
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdCloseClient: 9
D [25/Jun/2009:20:09:43 -0400] cupsdAcceptClient: 9 from localhost (Domain)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 POST / HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] Get-Printer-Attributes ipp://localhost/printers/ML-1610
D [25/Jun/2009:20:09:43 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:43 -0400] cupsdReadClient: 9 GET /printers/ML-1610.ppd HTTP/1.1
D [25/Jun/2009:20:09:43 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:43 -0400] cupsdAcceptClient: 13 from localhost (Domain)
...
...
A bunch of lines which are very similar to the above block
...
...
D [25/Jun/2009:20:09:45 -0400] Get-Printer-Attributes ipp://localhost/printers/ML-1610
D [25/Jun/2009:20:09:45 -0400] cupsdProcessIPPRequest: 9 status_code=0 (successful-ok)
D [25/Jun/2009:20:09:45 -0400] cupsdReadClient: 9 GET /printers/ML-1610.ppd HTTP/1.1
D [25/Jun/2009:20:09:45 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:45 -0400] cupsdCloseClient: 9
D [25/Jun/2009:20:09:45 -0400] cupsdAcceptClient: 9 from localhost (Domain)
D [25/Jun/2009:20:09:45 -0400] cupsdReadClient: 9 POST /printers/ML-1610 HTTP/1.1
D [25/Jun/2009:20:09:45 -0400] cupsdAuthorize: No authentication data provided.
D [25/Jun/2009:20:09:45 -0400] Print-Job ipp://localhost/printers/ML-1610
D [25/Jun/2009:20:09:45 -0400] [Job ???] Auto-typing file...
I [25/Jun/2009:20:09:45 -0400] [Job ???] Request file type is application/pdf.
D [25/Jun/2009:20:09:45 -0400] Print-Job client-error-document-format-not-supported: Unsupported format 'application/pdf'!
D [25/Jun/2009:20:09:45 -0400] cupsdProcessIPPRequest: 9 status_code=40a (client-error-document-format-not-supported)
D [25/Jun/2009:20:10:08 -0400] cupsdCloseClient: 9
I [26/Jun/2009:00:21:30 -0400] Listening to ::1:631 (IPv6)
I [26/Jun/2009:00:21:30 -0400] Listening to 127.0.0.1:631 (IPv4)
I [26/Jun/2009:00:21:30 -0400] Listening to /var/run/cups/cups.sock (Domain)
...

Whether you try to print a plain/text, or a pdf or an image/png, it doesn't matter, it borks about application/pdf. Detach the printer, and it says the same things. So what's the difference between other apps?

When other apps send a job to the queue, nearly same lines are printed *but* with a difference:

D [25/Jun/2009:20:09:45 -0400] cupsdAcceptClient: 9 from localhost (Domain) (From KDE/Qt 4.x applications)

becomes

D [25/Jun/2009:20:09:45 -0400] cupsdAcceptClient: 9 from localhost:631 (IPv6) (Rest of the world)

and then no unsupported format/client-error-document-format-not-supported error, everything prints well.

-----------------

Should I blame Qt applications, CUPS or my setup? How can I further debug the issue? Is there anyone who can reproduce the issue?

I wrote a very simple Qt4 application which triggers the problem:

http://svn.pardus.org.tr/pardus/playground/ozan/qt-cups/



Thanks a lot
Ozan Caglayan

[0]: http://www.pardus.org.tr/eng





More information about the cups mailing list