New submission from Licht Takeuchi <lich...@outlook.jp>: policy.utf8 is False, but non-ascii are not well-handled. Repro. code.
``` Python 3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 18:10:19) [GCC 7.2.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> from email.message import EmailMessage >>> from email.policy import default >>> >>> policy = default.clone() >>> policy.utf8 False >>> msg = EmailMessage() >>> msg["Subject"] = "á" >>> policy.fold("Subject", msg["Subject"]) 'Subject: =?utf-8?q?=C3=A1?=\n' >>> policy.fold("Subject", 'á') 'Subject: á\n' ``` ---------- components: Library (Lib) messages: 317025 nosy: licht-t priority: normal severity: normal status: open title: Inconsistent behavior of non-ascii handling in EmailPolicy.fold versions: Python 3.6, Python 3.7, Python 3.8 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue33568> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com