XZise added a comment.
That is … technically not correct. While Python 3 does work it's not because the strings are UTF-8 encoded but because the encoding for the streams are known. It uses `sys.stdout.encoding` which is `None` when piping and that then leads to pywikibot using Latin-1 or cp850.
Now I'm not sure what they are encoded internally but for someone writing Python scripts it shouldn't matter. I just wanted to say this here as a string is not immediately a UTF-8 encoded string and you need to encode it in any case (even into UTF-8) when you want to store it.
TASK DETAIL https://phabricator.wikimedia.org/T93474
REPLY HANDLER ACTIONS Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: XZise Cc: elyashiv, gerritbot, valhallasw, XZise, Ciencia_Al_Poder, Aklapper, jayvdb, pywikipedia-bugs