summaryrefslogtreecommitdiff
path: root/django/forms
diff options
context:
space:
mode:
authorMads Jensen <mje@inducks.org>2019-07-18 08:13:01 +0200
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2019-09-24 15:18:53 +0200
commit129583a0d3cf69b08d058cd751d777588801b7ad (patch)
tree942c8e699445b6c13dc7b43869d1fee999eb8134 /django/forms
parentaad46ee274b0e294ac055cc199e6595de4ef4164 (diff)
Removed some outdated backwards compatibility imports and misleading comments.
EmptyResultSet moved in 46509cf13dbf049f75077981c29ef2c60b5a96ab. FieldDoesNotExist moved in 8958170755b37ce346ae5257c1000bd936faa3b0. BoundField and pretty_name moved in 8550161e531a603d57723850fb09c4c9b7ca60b9. EMPTY_VALUES moved in 471596fc1afcb9c6258d317c619eaf5fd394e797. BaseRunserverCommand moved in 5c53e30607014163872e89c221b206992a9acfef.
Diffstat (limited to 'django/forms')
-rw-r--r--django/forms/fields.py2
-rw-r--r--django/forms/forms.py5
-rw-r--r--django/forms/utils.py2
3 files changed, 2 insertions, 7 deletions
diff --git a/django/forms/fields.py b/django/forms/fields.py
index a977256525..03cd8af8d7 100644
--- a/django/forms/fields.py
+++ b/django/forms/fields.py
@@ -15,8 +15,6 @@ from urllib.parse import urlsplit, urlunsplit
from django.core import validators
from django.core.exceptions import ValidationError
-# Provide this import for backwards compatibility.
-from django.core.validators import EMPTY_VALUES # NOQA
from django.forms.boundfield import BoundField
from django.forms.utils import from_current_timezone, to_current_timezone
from django.forms.widgets import (
diff --git a/django/forms/forms.py b/django/forms/forms.py
index 0ab25643da..48b237611f 100644
--- a/django/forms/forms.py
+++ b/django/forms/forms.py
@@ -5,11 +5,8 @@ Form classes
import copy
from django.core.exceptions import NON_FIELD_ERRORS, ValidationError
-# BoundField is imported for backwards compatibility in Django 1.9
-from django.forms.boundfield import BoundField # NOQA
from django.forms.fields import Field, FileField
-# pretty_name is imported for backwards compatibility in Django 1.9
-from django.forms.utils import ErrorDict, ErrorList, pretty_name # NOQA
+from django.forms.utils import ErrorDict, ErrorList
from django.forms.widgets import Media, MediaDefiningClass
from django.utils.datastructures import MultiValueDict
from django.utils.functional import cached_property
diff --git a/django/forms/utils.py b/django/forms/utils.py
index 8bfdd0a799..5ae137943a 100644
--- a/django/forms/utils.py
+++ b/django/forms/utils.py
@@ -2,7 +2,7 @@ import json
from collections import UserList
from django.conf import settings
-from django.core.exceptions import ValidationError # backwards compatibility
+from django.core.exceptions import ValidationError
from django.utils import timezone
from django.utils.html import escape, format_html, format_html_join, html_safe
from django.utils.translation import gettext_lazy as _