Skip to content

Commit e21140a

Browse files
WaVEVtimgraham
authored andcommitted
Remove unused **extra_context from Aggregates
1 parent d4748bf commit e21140a

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

django_mongodb_backend/aggregates.py

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,7 @@
88
MONGO_AGGREGATIONS = {Count: "sum"}
99

1010

11-
def aggregate(
12-
self,
13-
compiler,
14-
connection,
15-
operator=None,
16-
resolve_inner_expression=False,
17-
**extra_context, # noqa: ARG001
18-
):
11+
def aggregate(self, compiler, connection, operator=None, resolve_inner_expression=False):
1912
if self.filter:
2013
node = self.copy()
2114
node.filter = None
@@ -31,7 +24,7 @@ def aggregate(
3124
return {f"${operator}": lhs_mql}
3225

3326

34-
def count(self, compiler, connection, resolve_inner_expression=False, **extra_context): # noqa: ARG001
27+
def count(self, compiler, connection, resolve_inner_expression=False):
3528
"""
3629
When resolve_inner_expression=True, return the MQL that resolves as a
3730
value. This is used to count different elements, so the inner values are
@@ -64,12 +57,12 @@ def count(self, compiler, connection, resolve_inner_expression=False, **extra_co
6457
return {"$add": [{"$size": lhs_mql}, exits_null]}
6558

6659

67-
def stddev_variance(self, compiler, connection, **extra_context):
60+
def stddev_variance(self, compiler, connection):
6861
if self.function.endswith("_SAMP"):
6962
operator = "stdDevSamp"
7063
elif self.function.endswith("_POP"):
7164
operator = "stdDevPop"
72-
return aggregate(self, compiler, connection, operator=operator, **extra_context)
65+
return aggregate(self, compiler, connection, operator=operator)
7366

7467

7568
def register_aggregates():

0 commit comments

Comments
 (0)