]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Don't populate expired attrs w/ evaluator
authorMike Bayer <mike_mp@zzzcomputing.com>
Wed, 21 Oct 2020 17:58:22 +0000 (13:58 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Wed, 21 Oct 2020 18:03:12 +0000 (14:03 -0400)
commite3dc20ff27fa75e571fb2631e64737ea8f25f7c5
tree7bc037f85ad4a3ac0399bef46fb05bdefd1f1973
parent04d45f8adeafe5bb8981e7cfd94b11d36248d860
Don't populate expired attrs w/ evaluator

Fixed bug in :meth:`_orm.Query.update` where objects in the
:class:`_orm.Session` that were already expired would be unnecessarily
SELECTed individually when they were refreshed by the "evaluate"
synchronize strategy.

For 1.4 there was also a similar issue with fetch that would actually
get the wrong data back, as the new value would be loaded, then
applied with the evaluator.

Fixes: #5664
Change-Id: I6e6aff88462654fcefa9fce2b45f5446c418deee
doc/build/changelog/unreleased_13/5664.rst [new file with mode: 0644]
lib/sqlalchemy/orm/persistence.py
test/orm/test_update_delete.py