Merged
Conversation
- Remove from __future__ imports from all files - Simplify emails/compat: remove Python 2 branch, keep only Python 3 code - Delete unused ordereddict.py and orderedset.py - Remove is_py2/is_py3/is_py26/is_py34_plus version checks - Remove Travis CI pypy workaround from test_loaders - All 74 tests pass on Python 3.14
Move to_unicode, to_native, to_bytes, formataddr to emails.utils. Replace all compat aliases with direct stdlib imports: - string_types -> str - text_type -> str - is_callable -> callable() - urlparse -> urllib.parse - NativeStringIO/StringIO/BytesIO -> io - OrderedDict -> collections Delete emails/compat package and remove from setup.py. All 74 tests pass.
The policy test code was accidentally indented inside gen_policy() after the return statement, making it unreachable.
f783fb5 to
13908c9
Compare
lavr
added a commit
that referenced
this pull request
Mar 31, 2026
Python 2 support was removed in #188, so the wheel should no longer be tagged as py2.py3-universal.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
from __future__ importfrom all files (35 files)emails/compat/__init__.py: remove Python 2 branch, keep only Python 3 codeordereddict.pyandorderedset.pyis_py2/is_py3/is_py26/is_py34_plusversion checks from code and tests-566 lines of dead code removed. All 74 tests pass on Python 3.14.