]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Warn when trying to execute a query object with a session.
authorFederico Caselli <cfederico87@gmail.com>
Fri, 1 Oct 2021 20:16:14 +0000 (22:16 +0200)
committerMike Bayer <mike_mp@zzzcomputing.com>
Mon, 4 Oct 2021 18:33:29 +0000 (14:33 -0400)
commit3f2209776183193552cbc9516710deb6598fd6cd
treeb86ec0e0a8f0f77c12c8ed2857e199d67d747da6
parent71e463506217e3acc379a3f459e68a81792a0aac
Warn when trying to execute a query object with a session.

Passing a :class:`.Query` object to :meth:`_orm.Session.execute` is not
the intended use of this object, and will now raise a deprecation warning.

Fixes: #6284
Change-Id: I30a406d5a72335f9405f10f0a2030a32ccda41b9
doc/build/changelog/unreleased_14/6284.rst [new file with mode: 0644]
lib/sqlalchemy/sql/coercions.py
test/ext/test_baked.py
test/orm/test_bind.py
test/orm/test_query.py