Opened 9 years ago

Closed 9 years ago

#23876 closed Cleanup/optimization (fixed)

SQLAggregateCompiler.as_sql() accepts a compiler arg that it doesn't use

Reported by: Carl Meyer Owned by: nobody
Component: Database layer (models, ORM) Version: 1.6
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

It even goes to the trouble of setting the compiler arg to self if one wasn't passed in; but then compiler is never used in the method.

Many of the other SQLCompiler subclasses have as_sql methods that don't accept compiler, so it doesn't appear to be an invariant.

Test suite lasses without that argument, at least on SQLite. Will push a cleanup PR to check if anything else breaks on CI.

Change History (2)

comment:2 by Carl Meyer <carl@…>, 9 years ago

Resolution: fixed
Status: newclosed

In d6e2bbe734fe65f1cec825b9c507ad7bbb09f2f0:

Fixed #23876 -- Removed dead code in SQLAggregateCompiler.

Note: See TracTickets for help on using tickets.
Back to Top