On Thursday, 11 May 2017 14.26.37 WEST Jürgen Spitzmüller wrote:
> 2017-05-11 12:51 GMT+02:00 José Abílio Matos <jama...@lyx.org>:
> > I will look into this problem if we have a bug report for it and a simple
> > example file.
> 
> http://www.lyx.org/trac/ticket/10660
> 
> Jürgen
> 
> > --
> > José Abílio

Thank you.

First I will blame Stephan (at least according to git). ;-)

The problem is:

 LookupError: unknown error handler name 'surrogateescape'

according to PEP383:
https://www.python.org/dev/peps/pep-0383/

this error handler was only introduced in python 3 and so it makes sense the 
error seen by Andrew.


OTHO both Stephan and I (and probably others) do not see this problem with 
python 2, so probably the error handler was backported to python 2.


So I suggest to remove for the moment the error argument from the io.open 
call.

Also according to Nick Coghlan (python core member):
http://python-notes.curiousefficiency.org/en/latest/python3/
text_file_processing.html

"surrogate escape ... is the error handler that Python uses for most OS facing 
APIs to gracefully cope with encoding problems in the data supplied by the 
OS."

so I think that we should be safe here.

-- 
José Abílio

Reply via email to