-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Files produced by ipptool --ippserver
cannot be processed by ippserver
#67
Comments
Will investigate, but the configuration directive support expects a system.conf file in the root directory and per-printer configuration files in the "print" subdirectory (for regular printers) or "print3d" subdirectory (for 3D printers). |
OK, it looks like the old attribute parser and the new token parser are mismatched. Going to investigate putting together a common parser interface/mini-library for ipptool and ippserver so that this issue is resolved and future incompatibilities are avoided. |
Working on a common base parser: [master fd96ad89f] Add (ASCII) IPP data file parser to libcups, to be used by ippserver and ipptool. |
Finished the changes to ipptool: [master 8e2e09c1e] Finish re-tooling of ipptool to use new parser. Will merge those over here and then work on adopting for ippserver... |
Attribute/collection parsing now uses common code so that "ipptool --ippserver" files can be read, with certain attributes being silently ignored.
Maybe I'm mistaken with this... but here I go.
What should happen
I'm writing up this issue under the assumption that the
--ippserver
parameter should work in the folllowing scenario (maybe I'm wrong -- please tell):"ipptool --ippserver attr.txt ipp://someserver-or-printer/ipp/print get-printer-attributes.test"
"ippserver -v -C ."
(where the previously generated attr.txt is located in the current, otherwise empty, directory)The ippserver would use the attr.txt file to determine which properties for the "MyTest" printer it should emulate.
What really happens
Observations:
A process started with
ippserver -v -p 22222 "FirstTest"
starts without a problem, and produces ~264 lines of output. (I used this one to connectipptool --ippserver attr.conf
to.)The process started with
ippserver -v -p 22222 -C .
seems to hang on startup:NOTE: I made sure that attr.conf contained a valid
DeviceURI
line (had to edit it in, the generated one didn't contain one...)Then I start ipptool again to connect to the running ippserver process with get-printer-attributes.test.
a) I see this in ipptool output:
b) The following happens then immediately for ippserver:
In general, the behaviour is not necessarily predictable. A few times, when "valid" printer .conf files are in the config directory alongside with one that
--ippserver
generated, I also see ippserver startup messages like these:Investigating these .conf files showed:
line 16 of foo2.conf:
ATTR keyword media-ready "na_letter_8.5x11in","iso_a4_210x297mm"
line 3 of bar2.conf:
ATTR charset charset-supported "us-ascii","utf-8"
When I edit these lines to remove the quotes (not the commas), the same "Unknown directive" appears in ippserver's output, but for lines 4+17 now, which also have quoted values separated by commas...
The text was updated successfully, but these errors were encountered: