Cleanups when no supported version of Django supports Python 2 anymore
— at Version 15
Compatibility with Python 2 is currently being removed in master as part of the Django 2.0 development cycle: see #23919.
However third-party apps may want to remain compatible with all supported version of Django and the corresponding versions of Python, which includes Python 2.
To allow this, compatibility functions or modules aren't removed. They're still importable. They're usually just aliases or no-ops. Here's a list of things to deprecate and remove eventually:
- django.utils.six
- django.utils.lru_cache
- django.utils._os.abspathu, upath, npath
- django.utils.decorators.available_attrs
- django.utils.encoding.python_2_unicode_compatible
- django.utils.encoding.smart/force_text
- django.utils.http.urlquote/urlquote_plus/urlunquote/urlunquote_plus (unmerged commit)
- django.utils.safestring.SafeBytes
- One of either django.utils.safestring.SafeString or django.utils.safestring.SafeText
- django.test.utils.str_prefix()
- django.utils.encoding.DjangoUnicodeDecodeError
django.utils.functional.curry() (in favor of functools.partial()/partialmethod(); see 5b1c389603a353625ae1603ba345147356336afb)
Change History
(15)
| Triage Stage: |
Unreviewed → Someday/Maybe
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
| Owner: |
changed from nobody to Luong Dang Hai
|
| Status: |
new → assigned
|
| Owner: |
Luong Dang Hai removed
|
| Status: |
assigned → new
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
| Description: |
modified (diff)
|
Should we revert the removal of eb0b921c29ace8643a5a4cd136c433727c53dead in this case?