pycups icon indicating copy to clipboard operation
pycups copied to clipboard

addPrinter only accepts 'name'

Open EDKarlsson opened this issue 2 years ago • 1 comments

I'm trying to utilize the addPrinter method in connection. However, it only accepts a name. The documentation says that there are additional parameters that can be used but the method signature does not allow for args or kwargs only name. Am I missing something? I don't see this in the todo file so I'm curious if is yet to be fully implemented. It looks like the cupsconnection.c supports the additional parameters.

EDKarlsson avatar Dec 05 '22 21:12 EDKarlsson

https://github.com/OpenPrinting/pycups/blob/master/cupsconnection.c#L5015 should be changed to "addPrinter(name, filename=None, ppdname=None, info=None, location=None, device=None, ppd=None) -> None\n\n". I have a fix at work, and I will create a pull request when I get home.

EDKarlsson avatar Dec 06 '22 18:12 EDKarlsson