]> git.ipfire.org Git - thirdparty/sqlalchemy/alembic.git/commitdiff
Remove warning regarding cache key when using MSSQL.
authorCaselIT <cfederico87@gmail.com>
Tue, 28 Dec 2021 21:15:32 +0000 (22:15 +0100)
committerCaselIT <cfederico87@gmail.com>
Wed, 29 Dec 2021 20:18:26 +0000 (21:18 +0100)
Change-Id: I5eacf7c2030d8dbdaf1e5d2eba836a7596365ae3

alembic/ddl/mssql.py
docs/build/unreleased/cache_warning.rst [new file with mode: 0644]

index 9e1ef76eae5cc65612f015b8a0d1914d6a545b6c..ff75694022654ead55bbe1484b88fa2b384fb546 100644 (file)
@@ -255,6 +255,8 @@ class MSSQLImpl(DefaultImpl):
 
 
 class _ExecDropConstraint(Executable, ClauseElement):
+    inherit_cache = False
+
     def __init__(
         self,
         tname: str,
@@ -269,6 +271,8 @@ class _ExecDropConstraint(Executable, ClauseElement):
 
 
 class _ExecDropFKConstraint(Executable, ClauseElement):
+    inherit_cache = False
+
     def __init__(
         self, tname: str, colname: "Column", schema: Optional[str]
     ) -> None:
diff --git a/docs/build/unreleased/cache_warning.rst b/docs/build/unreleased/cache_warning.rst
new file mode 100644 (file)
index 0000000..19abad1
--- /dev/null
@@ -0,0 +1,5 @@
+.. change::
+    :tags: mssql
+
+    Removed a warning raised by SQLAlchemy when dropping constraints
+    on MSSQL regarding statement caching.