Closed ukrarome closed 1 year ago
Caching on .aggregate() method is broken in PR #https://github.com/Suor/django-cacheops/commit/e277e1ea09258cd981091be777abcc3cef79b03a It no longer takes aliases into account Example:
.aggregate()
s.packages.all().aggregate(dives=Max('dives_in_package')) >> {'dives': None} # cache s.packages.all().aggregate(another_alias=Max('dives_in_package')) >> {'dives': None} # no cache s.packages.all().nocache().aggregate(another_alias=Max('dives_in_package')) >> {'another_alias': None}
Interesting, can you make a test of it? There is an instruction in README.
Is it fixed?
Yes
7.0.1 - still not working
Caching on
.aggregate()
method is broken in PR #https://github.com/Suor/django-cacheops/commit/e277e1ea09258cd981091be777abcc3cef79b03a It no longer takes aliases into account Example: