I use version 3.15.2-0ubuntu4.2 of hplib.
The attached document causes the UnicodeEncodeError in the /usr/lib/cups/filter/hpps filter.
It look like the document contains some surrogate escapes. I solved the problem by altering the file "/usr/share/hplip/base/sixext.py".
I changed "return s.encode("utf-8")" on line 109 with "return s.encode("utf-8", errors="surrogateescape")".
I use version 3.15.2-0ubuntu4.2 of hplib.
The attached document causes the UnicodeEncodeError in the /usr/lib/ cups/filter/ hpps filter.
It look like the document contains some surrogate escapes. I solved the problem by altering the file "/usr/share/ hplip/base/ sixext. py".
I changed "return s.encode("utf-8")" on line 109 with "return s.encode("utf-8", errors= "surrogateescap e")".