django1/django/db
Loic Bistuer 20399083f4 Fixed #19816 -- Pre-evaluate querysets used in direct relation assignments.
Since assignments on M2M or reverse FK descriptors is composed of a `clear()`,
followed by an `add()`, `clear()` could potentially affect the value of the
assigned queryset before the `add()` step; pre-evaluating it solves the problem.

This patch fixes the issue for ForeignRelatedObjectsDescriptor,
ManyRelatedObjectsDescriptor, and ReverseGenericRelatedObjectsDescriptor.
It completes 6cb6e1 which addressed ReverseManyRelatedObjectsDescriptor.
2014-03-30 15:36:45 +07:00
..
backends Add a useful stacklevel to some RemovedInDjango19Warnings 2014-03-27 15:44:52 +13:00
migrations Fixed #22331 -- Made MigrationAutodetector ignore unmanaged models. 2014-03-25 18:30:58 -04:00
models Fixed #19816 -- Pre-evaluate querysets used in direct relation assignments. 2014-03-30 15:36:45 +07:00
__init__.py Removed unused imports. 2014-03-21 20:18:19 -04:00
transaction.py Fixed #22291 -- Avoided shadowing deadlock exceptions on MySQL. 2014-03-23 20:45:22 +01:00
utils.py Removed deprecated TRANSACTIONS_MANAGED setting. 2014-03-21 21:34:47 +01:00