]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
restore declared_attr consumption for __table__
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 18 Jun 2024 02:45:16 +0000 (22:45 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 18 Jun 2024 03:23:09 +0000 (23:23 -0400)
commit30ec43440168fa79a4d45db64c387562ef8f97e6
tree753767a461833aebf76b33b01d92f96632a346cc
parent52b03301b3ca6cb285b5290de4dfe6806f4836f1
restore declared_attr consumption for __table__

Fixed bug in ORM Declarative where the ``__table__`` directive could not be
declared as a class function with :func:`_orm.declared_attr` on a
superclass, including an ``__abstract__`` class as well as coming from the
declarative base itself.  This was a regression since 1.4 where this was
working, and there were apparently no tests for this particular use case.

Fixes: #11509
Change-Id: I82ef0f93d00cb7a43b0b1b16ea28f1a9a79eba3b
doc/build/changelog/unreleased_20/11509.rst [new file with mode: 0644]
lib/sqlalchemy/orm/decl_base.py
test/orm/declarative/test_mixin.py