Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 95a8dfb

Browse filesBrowse files
committed
#20976: remove unneeded quopri import in email.utils.
1 parent f8cbbbb commit 95a8dfb
Copy full SHA for 95a8dfb

2 files changed

+2-4Lines changed: 2 additions & 4 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎Lib/email/message.py‎

Copy file name to clipboardExpand all lines: Lib/email/message.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
import re
1010
import uu
11+
import quopri
1112
from io import BytesIO, StringIO
1213

1314
# Intrapackage imports
@@ -278,7 +279,7 @@ def get_payload(self, i=None, decode=False):
278279
if not decode:
279280
return payload
280281
if cte == 'quoted-printable':
281-
return utils._qdecode(bpayload)
282+
return quopri.decodestring(bpayload)
282283
elif cte == 'base64':
283284
# XXX: this is a bit of a hack; decode_b should probably be factored
284285
# out somewhere, but I haven't figured out where yet.
Collapse file

‎Lib/email/utils.py‎

Copy file name to clipboardExpand all lines: Lib/email/utils.py
-3Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,7 @@
3636

3737
from email._parseaddr import parsedate, parsedate_tz, _parsedate_tz
3838

39-
from quopri import decodestring as _qdecode
40-
4139
# Intrapackage imports
42-
from email.encoders import _bencode, _qencode
4340
from email.charset import Charset
4441

4542
COMMASPACE = ', '

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.