1
0
mirror of https://github.com/django/django.git synced 2025-11-07 07:15:35 +00:00

Removed some outdated backwards compatibility imports and misleading comments.

EmptyResultSet moved in 46509cf13d.
FieldDoesNotExist moved in 8958170755.
BoundField and pretty_name moved in 8550161e53.
EMPTY_VALUES moved in 471596fc1a.
BaseRunserverCommand moved in 5c53e30607.
This commit is contained in:
Mads Jensen
2019-07-18 08:13:01 +02:00
committed by Mariusz Felisiak
parent aad46ee274
commit 129583a0d3
14 changed files with 32 additions and 38 deletions

View File

@@ -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 (

View File

@@ -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

View File

@@ -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 _