Forum Archive

Problem with FTP accented characters in Pyhonista 3

cvp

I use standard ftplib to access a NAS in FTP and my directories or files names could contain accents characters. In previous version of Pythonista I didn't have any problem, but since Pythonista 3, the names , for instance created by mkd see their accented characters transformed into %xx, ex Μu%E1oz for Muñoz.
Just before FTP.mkd(name), a print(name) still shows accents characters.
Thanks for your help.

cvp

This line alter ftp object creation has been sufficient!

ftp.encoding = "utf-8"

cvp

Not found by myself but on a french forum by searching on Google for
"python 3 ftplib accents"