From c7ce93732f334ece460e479cb104856cdd98432b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Martin=20Haa=C3=9F?= Date: Sat, 16 Mar 2019 17:28:59 -0400 Subject: [PATCH] Update error messages for SQLite no constraint support clarify that batch mode should be used. Closes: #526 Pull-request: https://github.com/sqlalchemy/alembic/pull/526 Pull-request-sha: 5d89cf4e77e5568887f2c8926a589c55427dab12 Change-Id: I06e7d8062ae7d1c96ec21318adf8f946a025aef8 --- alembic/ddl/sqlite.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/alembic/ddl/sqlite.py b/alembic/ddl/sqlite.py index 5a697786..f89b8548 100644 --- a/alembic/ddl/sqlite.py +++ b/alembic/ddl/sqlite.py @@ -33,17 +33,24 @@ class SQLiteImpl(DefaultImpl): if const._create_rule is None: raise NotImplementedError( "No support for ALTER of constraints in SQLite dialect" + "Please refer to the batch mode feature which allows for " + "SQLite migrations using a copy-and-move strategy." ) elif const._create_rule(self): util.warn( "Skipping unsupported ALTER for " "creation of implicit constraint" + "Please refer to the batch mode feature which allows for " + "SQLite migrations using a copy-and-move strategy." ) def drop_constraint(self, const): if const._create_rule is None: raise NotImplementedError( "No support for ALTER of constraints in SQLite dialect" + "Please refer to the batch mode feature which allows for " + "SQLite migrations using a copy-and-move strategy." + ) def compare_server_default( -- 2.47.2