]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Default create_constraint to False
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 2 Jun 2020 18:21:03 +0000 (14:21 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Wed, 3 Jun 2020 20:19:40 +0000 (16:19 -0400)
commit97cd0a5db8bb2e47f38899592740d1bc75ec0412
treebea2062f7e2b3e60fd8b87bdba7e368cc8e87724
parentc7c564b57f3ce2fee30b44f22db7baf2f0fa9fe0
Default create_constraint to False

The :paramref:`.Enum.create_constraint` and
:paramref:`.Boolean.create_constraint` parameters now default to False,
indicating when a so-called "non-native" version of these two datatypes is
created, a CHECK constraint will not be generated by default.   These CHECK
constraints present schema-management maintenance complexities that should
be opted in to, rather than being turned on by default.

Fixes: #5367
Change-Id: I0a3fb608ce32143fa757546cc17ba2013e93272a
doc/build/changelog/unreleased_14/5367.rst [new file with mode: 0644]
lib/sqlalchemy/sql/sqltypes.py
test/dialect/mysql/test_types.py
test/dialect/postgresql/test_compiler.py
test/dialect/postgresql/test_types.py
test/dialect/test_sqlite.py
test/sql/test_metadata.py
test/sql/test_types.py