On Saturday, 13 May 2017 10.50.10 WEST Stephan Witt wrote:
> Yes, I put in in. (And you luckily hit a Friday to place your smiley  )

That has never stopped me before. :-D

My daughter and son follow the same footsteps, some of the other parents said 
that never saw them not smiling in the morning. That is obviously an 
exaggeration but the point remains. :-)
 
> I’m not so easy with your proposal to remove the error handler.
> I think we have a real problem here: the encoding of the path names
> in preferences is undefined if I’m not mistaken.

I understand and share your concern. But we were placing those safeguards at 
the wrong place.

The encoding of the path names is related with the name of the file and not 
with its content. The error handler was placed when reading the file and thus 
is related with its content.

> Of course we have to fix it in some way - but I don’t know enough
> of python (obviously) to make the right proposal.

FWIW note the we could restore the previous behaviour by doing:

if PY2:
    source = io.open(args[0], 'r', encoding='utf_8')
else:
    source = io.open(args[0], 'r', encoding='utf_8', errors='surrogateescape')

with PY2 being defined as usual in the other python files.

> Stephan

-- 
José Abílio

Reply via email to