From efe28d3f566a00e76ae589a3f93be8079a638ca8 Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Mon, 4 Feb 2019 19:50:30 -0500 Subject: [PATCH] Refs #27753 -- Removed django.utils._os.abspathu(), upath(), and npath(). --- django/utils/_os.py | 16 ---------------- docs/releases/3.0.txt | 5 +++++ 2 files changed, 5 insertions(+), 16 deletions(-) diff --git a/django/utils/_os.py b/django/utils/_os.py index 81ab8e6e76..c901d584c1 100644 --- a/django/utils/_os.py +++ b/django/utils/_os.py @@ -4,22 +4,6 @@ from os.path import abspath, dirname, join, normcase, sep from django.core.exceptions import SuspiciousFileOperation -# For backwards-compatibility in Django 2.0 -abspathu = abspath - - -def upath(path): - """Always return a unicode path (did something for Python 2).""" - return path - - -def npath(path): - """ - Always return a native path, that is unicode on Python 3 and bytestring on - Python 2. Noop for Python 3. - """ - return path - def safe_join(base, *paths): """ diff --git a/docs/releases/3.0.txt b/docs/releases/3.0.txt index 7801db12f2..763c3ec5c0 100644 --- a/docs/releases/3.0.txt +++ b/docs/releases/3.0.txt @@ -257,6 +257,11 @@ Django 3.0, we're removing these APIs at this time. * ``django.utils.decorators.available_attrs()`` - This function returns ``functools.WRAPPER_ASSIGNMENTS``. +* ``django.utils._os.abspathu()`` - Alias of :func:`os.path.abspath`. + +* ``django.utils._os.upath()`` and ``npath()`` - These functions do nothing on + Python 3. + Miscellaneous -------------