From fe0184b4121dd68b827575fc2116a65703c5be08 Mon Sep 17 00:00:00 2001 From: Mariusz Felisiak Date: Sun, 3 Sep 2017 15:20:51 +0200 Subject: [PATCH] Updated EmpytResultSet import not to use the alias. --- django/db/models/sql/query.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/django/db/models/sql/query.py b/django/db/models/sql/query.py index 0473654fe1..509d97e65d 100644 --- a/django/db/models/sql/query.py +++ b/django/db/models/sql/query.py @@ -11,7 +11,9 @@ from contextlib import suppress from itertools import chain, count, product from string import ascii_uppercase -from django.core.exceptions import FieldDoesNotExist, FieldError +from django.core.exceptions import ( + EmptyResultSet, FieldDoesNotExist, FieldError, +) from django.db import DEFAULT_DB_ALIAS, connections from django.db.models.aggregates import Count from django.db.models.constants import LOOKUP_SEP @@ -25,7 +27,7 @@ from django.db.models.sql.constants import ( INNER, LOUTER, ORDER_DIR, ORDER_PATTERN, SINGLE, ) from django.db.models.sql.datastructures import ( - BaseTable, Empty, EmptyResultSet, Join, MultiJoin, + BaseTable, Empty, Join, MultiJoin, ) from django.db.models.sql.where import ( AND, OR, ExtraWhere, NothingNode, WhereNode,