diff options
author | mike bayer <mike_mp@zzzcomputing.com> | 2022-03-25 19:35:32 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@ci3.zzzcomputing.com> | 2022-03-25 19:35:32 +0000 |
commit | 59308fd60fd8f7750205063134df4b944d12704b (patch) | |
tree | e51596b2f6772322acffb8ab266dd6ca0e394f78 /lib/sqlalchemy/sql/compiler.py | |
parent | 221aff778e1eb3c3aa8f8a1f72629177442694bc (diff) | |
parent | 57877461c1bd3b43a9d833fbca873d59db36b6f7 (diff) | |
download | sqlalchemy-59308fd60fd8f7750205063134df4b944d12704b.tar.gz |
Merge "generalize conditional DDL throughout schema / DDL" into main
Diffstat (limited to 'lib/sqlalchemy/sql/compiler.py')
-rw-r--r-- | lib/sqlalchemy/sql/compiler.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/sqlalchemy/sql/compiler.py b/lib/sqlalchemy/sql/compiler.py index 176e3637e..7fd37e9b1 100644 --- a/lib/sqlalchemy/sql/compiler.py +++ b/lib/sqlalchemy/sql/compiler.py @@ -4891,10 +4891,7 @@ class DDLCompiler(Compiled): for p in ( self.process(constraint) for constraint in constraints - if ( - constraint._create_rule is None - or constraint._create_rule(self) - ) + if (constraint._should_create_for_compiler(self)) and ( not self.dialect.supports_alter or not getattr(constraint, "use_alter", False) |