diff options
| author | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2021-01-13 12:52:13 +0100 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2021-01-14 17:50:04 +0100 |
| commit | 06eec3197009b88e3a633128bbcbd76eea0b46ff (patch) | |
| tree | 885be60c1f8fcde8d7cc8cd3b079648262ea762e /django/db/models/sql/query.py | |
| parent | bf770cc825f1af294b3b2853b39b5b161b6a056f (diff) | |
Refs #7098 -- Removed support for passing raw column aliases to order_by().
Per deprecation timeline.
Diffstat (limited to 'django/db/models/sql/query.py')
| -rw-r--r-- | django/db/models/sql/query.py | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/django/db/models/sql/query.py b/django/db/models/sql/query.py index b524e8859f..3b2211b3b3 100644 --- a/django/db/models/sql/query.py +++ b/django/db/models/sql/query.py @@ -10,7 +10,6 @@ import copy import difflib import functools import sys -import warnings from collections import Counter, namedtuple from collections.abc import Iterator, Mapping from itertools import chain, count, product @@ -36,7 +35,6 @@ from django.db.models.sql.datastructures import ( from django.db.models.sql.where import ( AND, OR, ExtraWhere, NothingNode, WhereNode, ) -from django.utils.deprecation import RemovedInDjango40Warning from django.utils.functional import cached_property from django.utils.hashable import make_hashable from django.utils.tree import Node @@ -1968,15 +1966,6 @@ class Query(BaseExpression): errors = [] for item in ordering: if isinstance(item, str): - if '.' in item: - warnings.warn( - 'Passing column raw column aliases to order_by() is ' - 'deprecated. Wrap %r in a RawSQL expression before ' - 'passing it to order_by().' % item, - category=RemovedInDjango40Warning, - stacklevel=3, - ) - continue if item == '?': continue if item.startswith('-'): |
