mirror of
https://github.com/django/django.git
synced 2024-12-26 02:56:25 +00:00
4e9a74b81d
Thanks to Jeremy Dunck for pointing out the problem with this change. If in a
single transaction, the master deletes a record and then get_or_creates a
similar record, under the new behavior the get_or_create would find the record
in the slave db and fail to re-create it, leaving the record nonexistent, which
violates the contract of get_or_create that the record should always exist
afterwards. We need to do everything against the master here in order to ensure
correctness.
This reverts commit
|
||
---|---|---|
.. | ||
__init__.py | ||
models.py | ||
tests.py |