← Back to team overview

desktop-packages team mailing list archive

[Bug 1400232] Re: system-config-printer crash UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 1441: invalid continuation byte (only UTF-8-encoded PPD files can be used)

 

** Branch linked: lp:ubuntu/trusty-proposed/system-config-printer

-- 
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to system-config-printer in Ubuntu.
https://bugs.launchpad.net/bugs/1400232

Title:
  system-config-printer crash UnicodeDecodeError: 'utf-8' codec can't
  decode byte 0xe9 in position 1441: invalid continuation byte (only
  UTF-8-encoded PPD files can be used)

Status in system-config-printer package in Ubuntu:
  Fix Released
Status in system-config-printer source package in Trusty:
  Fix Committed
Status in system-config-printer source package in Utopic:
  Fix Committed

Bug description:
  system-config-printer crash with the following traceback :

  sramage@japc09:~$ system-config-printer
  Traceback (most recent call last):
    File "/usr/share/system-config-printer/asyncipp.py", line 191, in send_reply
      handler (self._conn, result)
    File "/usr/share/system-config-printer/asyncpk1.py", line 164, in _ipp_reply_handler
      self._client_reply_handler (self._conn, *args)
    File "/usr/share/system-config-printer/asyncconn.py", line 91, in reply_handler
      self._reply_handler (self, self._reply_data, *args)
    File "/usr/share/system-config-printer/asyncconn.py", line 209, in _subst_reply_handler
      reply_handler (self, *args)
    File "/usr/share/system-config-printer/ppdcache.py", line 79, in <lambda>
      self._got_ppd3 (c, name, r, callback),
    File "/usr/share/system-config-printer/ppdcache.py", line 153, in _got_ppd3
      self.fetch_ppd (name, callback, check_uptodate=False)
    File "/usr/share/system-config-printer/ppdcache.py", line 90, in fetch_ppd
      tmpf.writelines (f.readlines ())
    File "/usr/lib/python3.4/codecs.py", line 313, in decode
      (result, consumed) = self._buffer_decode(data, self.errors, final)
  UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 1441: invalid continuation byte

  [Impact]

  It is impossible to set up or manipulate a printer with a PPD file
  which is not UTF-8-encoded and no plain ASCII. Even worse, if such a
  PPD is installed into the system's PPD repository, the corresponding
  printer(s) will not auto-setup.

  [Test Case]

  Take a PPD file which is not UTF-8-encoded, for example a PPD file for
  Windows with Windows-1252 encoding. Try to set up a que with it or to
  change an existing queue to use it by means of system-config-printer.
  system-config-printer will crash.

  With the proposed package the PPD can be used without problems.

  [Regression Potential]

  The changes are very simple and therefore the regression potential is
  low.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/system-config-printer/+bug/1400232/+subscriptions


References