]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
Deprecate the declarative_mixin decorator
authorFederico Caselli <cfederico87@gmail.com>
Thu, 13 Feb 2025 19:10:10 +0000 (20:10 +0100)
committerFederico Caselli <cfederico87@gmail.com>
Fri, 20 Jun 2025 20:55:01 +0000 (20:55 +0000)
References: #12346
Change-Id: I6709c7b33bf99ef94c3dc074a25386e8c13c9131

doc/build/orm/declarative_mixins.rst
lib/sqlalchemy/orm/decl_api.py

index 9f26207c07aaa1d5efcdd8ae4f1ffa24cd26cb75..32f03334a8b1f7bf3426a6b43a31d17a241032fb 100644 (file)
@@ -724,7 +724,7 @@ define on the class itself. The
 here to create user-defined collation routines that pull
 from multiple collections::
 
-    from sqlalchemy.orm import declarative_mixin, declared_attr
+    from sqlalchemy.orm import declared_attr
 
 
     class MySQLSettings:
index 60468237ee01bf64ecd624862f3a6712ec41f664..8d2e90f44157c65aae93223284abc2936f7120e7 100644 (file)
@@ -512,6 +512,9 @@ def declarative_mixin(cls: Type[_T]) -> Type[_T]:
 
     .. versionadded:: 1.4.6
 
+    .. legacy:: This api is considered legacy and will be deprecated in the next
+      SQLAlchemy version.
+
     .. seealso::
 
         :ref:`orm_mixins_toplevel`