Bug#905986: cups-tea4cups: TEABILLING reports error
tags 905986 moreinfo
thanks
On Mon 13 Aug 2018 at 14:31:07 +0100, Brian Potkin wrote:
> tags 905986 unreproducible
> thanks
>
>
> Thank you for your report, Rainer.
>
>
> On Sun 12 Aug 2018 at 20:15:36 +0200, Rainer Dorsch wrote:
>
> > Package: cups-tea4cups
> > Version: 3.13~alpha0+svn3565-4
> > Severity: important
> > Tags: patch
> >
> > Dear Maintainer,
> >
> > [this bug report corresponds to this discussion thread on debian-user
> >
> > https://lists.debian.org/debian-user/2018/05/msg01024.html
> >
> > (cont'd at next month)
> > https://lists.debian.org/debian-user/2018/06/msg00453.html ]
> >
> >
> > I have tea4cups configured to power on my printer before printing. In
> > order to do this, I prepended tea4cups:/ to the DeviceURI in
> > printers.conf (if I remove this and power on the printer manually
> > before printing, everything works as expected):
> >
> > /etc/cups/printers.conf:
> > DeviceURI tea4cups:/http://hpljwlan:631/ipp/
> > I configured the printer power on script:
> >
> > /etc/cups/tea4cups.conf:
> > prehook_sispmctl : /usr/local/bin/printeron
> >
> > but I get unfortunately an error in /var/log/cups/error_log
> > with every print job and the job is stopped.
> >
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : Traceback (most recent call last):
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : File \"/usr/lib/cups/backend/tea4cups\", line 1502, in <module>
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : wrapper.exportAttributes()
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : File \"/usr/lib/cups/backend/tea4cups\", line 1214, in exportAttributes
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : os.environ[\"TEABILLING\"] = self.JobBilling or \"\"
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : File \"/usr/lib/python2.7/os.py\", line 473, in __setitem__
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : putenv(key, item)
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : TypeError: putenv() argument 2 must be string, not int
> >
> > Is seems something goes wrong while setting the TEABILLING environement variable.
> >
> > There are more details listed in the mailing list thread linked above, but I think there are not very relevant.
> >
> >
> > In the meantime Daniel reported that he sees the same problem also in
> > Arch and KDE Neon:
> >
> > https://lists.debian.org/debian-user/2018/08/msg00505.html
> >
> > Via private mail he pointed out that this patch fixes the problem for
> > him in Arch linux:
> >
> > https://gitlab.com/dadosch/tea4cups/commit/1aac1f51ed35300891b3f0f01b34b37b523f1736
> >
> > I applied it on my Debian buster system and it fixes my issue as well.
> >
> > All credits for the fix go to Daniel.
>
> You have previously set up virtq and shown that the hooks are executed
> correctly from the tea4cups configuration file. In other words, Tea4CUPS
> does what it is designed to do; there is no bug there.
>
> I have an HP LaserJet 2200 which has a resource path for an IPP URI that
> is the same as yours. I have set up a print queue for it and have edited
> printers.conf as you did. This is about as close as I can get to mimicing
> your setup.
>
> All prehooks/posthooks in my tea4cups.conf are commented out. A job sent
> to the printer completes successfully, showing that tea4cups has wrapped
> the backend correctly on unstable. Please try this.
>
> For your non-printing situation, please send a complete error_log (the
> wiki has advice on how to get one) compressed with xz or gzip.
Something to read would pass the time. :)
Regards,
Brian.
Reply to: