[cups-devel] [UNKN] STR #4696: ipptool does not like swapped lines in .test file

Pipitas noreply at cups.org
Tue Aug 25 16:46:46 PDT 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

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

[STR New]

I'm using this `query-printer-capabilities.test` file with ipptool:

IGNORE-ERRORS yes
{
   NAME     "Get printer attributes using Get-Printer-Attributes"
   OPERATION Get-Printer-Attributes
   GROUP     operation-attributes-tag
   ATTR      language attributes-natural-language en
   ATTR      charset attributes-charset utf-8
   ATTR      uri printer-uri $uri
   ATTR      keyword requested-attributes
job-template,printer-description,media-col-database
} 

The command is this:

    ipptool -v -t ipp://localhost/printers/shack
query-printer-capabilities.test

The response:

"query-printer-capabilities.test":
    Get-Printer-Attributes:
        attributes-natural-language (naturalLanguage) = en
        attributes-charset (charset) = utf-8
        printer-uri (uri) = ipp://localhost:631/printers/shack
        requested-attributes (1setOf keyword) =
job-template,printer-description,media-col-database
    Get printer attributes using Get-Printer-Attributes                 
[PASS]
        RECEIVED: 122 bytes in response
        status-code = client-error-bad-request (Missing required
attributes.)
        attributes-charset (charset) = utf-8
        attributes-natural-language (naturalLanguage) = en-us
        status-message (textWithoutLanguage) = Missing required attributes.

However, if I swap two lines in the .test file so that the
"attributes-charset" definition is placed before the
"attributes-natural-language" one:

   ATTR      charset attributes-charset utf-8
   ATTR      language attributes-natural-language en

then all seems to work fine, and the response is full:

    Get-Printer-Attributes:
        attributes-charset (charset) = utf-8
        attributes-natural-language (naturalLanguage) = en
        printer-uri (uri) = ipp://localhost:631/printers/shack
        requested-attributes (1setOf keyword) =
job-template,printer-description,media-col-database
    Get printer attributes using Get-Printer-Attributes                 
[PASS]
        RECEIVED: 31092 bytes in response
        status-code = successful-ok (successful-ok)
        attributes-charset (charset) = utf-8
        attributes-natural-language (naturalLanguage) = en
        marker-change-time (integer) = 0
        printer-current-time (dateTime) = 2015-08-25T23:31:49Z
        printer-dns-sd-name (no-value) = no-value
        [....]
        [....100 more lines....]

Version of ipptool:

    ipptool --version
      CUPS v2.0.0

Link: https://www.cups.org/str.php?L4696
Version: 2.0-current
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)
Comment: GPGTools - https://gpgtools.org

iQIcBAEBCgAGBQJV3P5mAAoJENujp6sI12IjWW4QAI4rHXZROmYvX5BA1YiDysXv
KrH7iZSnjMN0GSVdgEIIIsPnH/2agEoheMchzYNkYebfGgrKnjZWL2JDmwkcyQDs
18D6Qj37ZF3w7wWqEYJO+OrwdhLddnDjSehsWWddeJjl69jLQnc1vMLMXkhcnANP
VsGEhpGPFQkL6bCJGBnMpJVlPqouXYYOUm4wPjqN16849ekibILLn4diBmHcvQxu
Lkx55GVd+TsGmbqgQ8UJeYZKEFTACXL1G5HpTSKXT9upqCOYMIV1PGPZe9UUYJUY
CtaOAPsFWBKybX28IFz3My4dfiSWZ3CvZgMue1yv/ExkOxX2TfHF3eEmNA5GpGP3
Pbi+DpuIdVpHCXmi1JtEisheAgl54OD2fjEBNG9NDIy2xfUaK3FV5rRBMYxJsXQ6
ZO/mT2IB9RlOY5PNCd/8gB026u0FsGmGFML8AZ6qycsdjrhyf1IakIOlb0il2sh+
wpskTxYqbh5K9gsDkST0bxRdyfVXmOmoAP29TDdwwgJhX6SR93/Oo35sUAvwbL/L
i5EMrxL/nGVYvld92RmV6c3l5hicICI7UM4kGfvysbR4MzBDdQMGxJ3TTHQJLj+F
1rFXngKEZmY6wtPWKsqea0IPZkNY/QyoPAhav2cQydCpmjzrWGutD/UsctFTCoD6
7NEr6NUp+/pG+Y6/LFkl
=NQg6
-----END PGP SIGNATURE-----




More information about the cups mailing list