summaryrefslogtreecommitdiffstats
path: root/Doc/whatsnew
diff options
context:
space:
mode:
authorR David Murray <rdmurray@bitdance.com>2016-09-09 22:39:18 (GMT)
committerR David Murray <rdmurray@bitdance.com>2016-09-09 22:39:18 (GMT)
commit06ed218ed0020003ac388572fbcf09b88075b664 (patch)
tree5a44ac4cb9d85a35fe9d8423e6700176f5de8352 /Doc/whatsnew
parent37df068e862c4bbab16da00de72655c4a737ea94 (diff)
downloadcpython-06ed218ed0020003ac388572fbcf09b88075b664.zip
cpython-06ed218ed0020003ac388572fbcf09b88075b664.tar.gz
cpython-06ed218ed0020003ac388572fbcf09b88075b664.tar.bz2
#20476: add a message_factory policy attribute to email.
Diffstat (limited to 'Doc/whatsnew')
-rw-r--r--Doc/whatsnew/3.6.rst7
1 files changed, 7 insertions, 0 deletions
diff --git a/Doc/whatsnew/3.6.rst b/Doc/whatsnew/3.6.rst
index a5b467b..ec2f2e0 100644
--- a/Doc/whatsnew/3.6.rst
+++ b/Doc/whatsnew/3.6.rst
@@ -598,6 +598,13 @@ The :mod:`email.mime` classes now all accept an optional *policy* keyword.
The :class:`~email.generator.DecodedGenerator` now supports the *policy*
keyword.
+There is a new :mod:`~email.policy` attribute,
+:attr:`~email.policy.Policy.message_factory`, that controls what class is used
+by default when the parser creates new message objects. For the
+:attr:`email.policy.compat32` policy this is :class:`~email.message.Message`,
+for the new policies it is :class:`~email.message.EmailMessage`.
+(Contributed by R. David Murray in :issue:`20476`.)
+
encodings
---------