[cups.bugs] [MOD] STR #2177: IPP: 'job-sheets' option kills 'number-up'

Albrecht Dreß albrecht.dress at arcor.de
Sun Dec 31 05:06:44 PST 2006


DO NOT REPLY TO THIS MESSAGE.  INSTEAD, POST ANY RESPONSES TO THE LINK BELOW.

[STR New]

OS: Linux 2.6.19.1, on PowerMac G4 "Silver" (PPC 7450)
Built w/: gcc 3.4.4, glibc 2.3.4

I noticed that, depending upon the value of the 'job-sheets' IPP option,
the 'number-up' option will be ignored.

In the following job (created from the control file in /var/spool/cups
using testipp), the number-up option will simply be ignored, i.e. the
printout is still one logical page on one sheet:

<snip>
operation-attributes-tag:

    attributes-charset (charset): "utf-8"
    attributes-natural-language (naturalLanguage): "de-de"

job-attributes-tag:

    job-originating-user-name (nameWithoutLanguage): "albrecht"
    printer-uri (uri): "ipp://localhost:631/printers/lp"
    job-name (nameWithoutLanguage): "balsa job #1"
    PageSize (nameWithoutLanguage): "A4"
    job-priority (integer): 50
    Resolution (nameWithoutLanguage): "300dpi"
    job-sheets (nameWithoutLanguage): "none,none"
    MediaType (nameWithoutLanguage): "Plain"
    InputSlot (nameWithoutLanguage): "Tray"
    number-up (integer): 2
    ColorModel (nameWithoutLanguage): "CMYK"
    document-format (mimeMediaType): "application/postscript"
    job-uuid (uri): "urn:uuid:045ada08-90d2-3091-762f-abb9e0645ba7"
    job-originating-host-name (nameWithoutLanguage): "localhost"
    time-at-creation (integer): 1167502326
    time-at-processing (integer): 1167502326
    time-at-completed (integer): 1167502358
    job-id (integer): 309
    job-state (enum): 7
    job-media-sheets-completed (integer): 1
    job-printer-uri (uri): "ipp://antares.localdomain:631/printers/lp"
    job-name (nameWithoutLanguage): "balsa job #1"
    job-k-octets (integer): 193
    job-hold-until (keyword): "no-hold"
</snip>

The call to the filter creates the following command line arg (from the
error_log file in debug mode, using the "HP DeskJet Series CUPS v1.2"
filter):

argv[5]="PageSize=A4 Resolution=300dpi MediaType=Plain InputSlot=Tray
ColorModel=CMYK job-uuid=urn:uuid:045ada08-90d2-3091-762f-abb9e0645ba7"

I hacked the application creating the IPP job (which is actually the
gtk+-2.10.6 cups print driver) to replace the "none,none" in 'job-sheets'
by simply "none".  The diff between the jobs (with "+" marking the working
version) is

<snip>
@@ -10,25 +10,25 @@
 
     job-originating-user-name (nameWithoutLanguage): "albrecht"
     printer-uri (uri): "ipp://localhost:631/printers/lp"
-    job-name (nameWithoutLanguage): "balsa job #1"
+    job-name (nameWithoutLanguage): "balsa job #2"
     PageSize (nameWithoutLanguage): "A4"
     job-priority (integer): 50
     Resolution (nameWithoutLanguage): "300dpi"
-    job-sheets (nameWithoutLanguage): "none,none"
+    job-sheets (nameWithoutLanguage): "none"
     MediaType (nameWithoutLanguage): "Plain"
     InputSlot (nameWithoutLanguage): "Tray"
     number-up (integer): 2
     ColorModel (nameWithoutLanguage): "CMYK"
     document-format (mimeMediaType): "application/postscript"
-    job-uuid (uri): "urn:uuid:045ada08-90d2-3091-762f-abb9e0645ba7"
+    job-uuid (uri): "urn:uuid:f790972c-cf4c-3499-7bb9-c38629a1f614"
     job-originating-host-name (nameWithoutLanguage): "localhost"
-    time-at-creation (integer): 1167502326
-    time-at-processing (integer): 1167502326
-    time-at-completed (integer): 1167502358
-    job-id (integer): 309
+    time-at-creation (integer): 1167501967
+    time-at-processing (integer): 1167502029
+    time-at-completed (integer): 1167502146
+    job-id (integer): 308
     job-state (enum): 7
     job-media-sheets-completed (integer): 1
     job-printer-uri (uri): "ipp://antares.localdomain:631/printers/lp"
-    job-name (nameWithoutLanguage): "balsa job #1"
+    job-name (nameWithoutLanguage): "balsa job #2"
     job-k-octets (integer): 193
     job-hold-until (keyword): "no-hold"
</snip>

and now the number-up option /is/ used as expected (i.e. two pages on one
sheet).  In the working case, the filter argv is

argv[5]="PageSize=A4 Resolution=300dpi MediaType=Plain InputSlot=Tray
number-up=2 ColorModel=CMYK
job-uuid=urn:uuid:f790972c-cf4c-3499-7bb9-c38629a1f614"

The behavior seems to be independent of the ppd used; I first saw this
using the HP Deskjet 5150 PPD from foomatic.  IMO, even /if/ the
job-sheets option with two parameters would be wrong (is it?), it should
not influence other legal options.

Link: http://www.cups.org/str.php?L2177
Version: 1.2.7





More information about the cups-devel mailing list