diff options
| author | mike bayer <mike_mp@zzzcomputing.com> | 2021-01-07 20:58:55 +0000 |
|---|---|---|
| committer | Gerrit Code Review <gerrit@bbpush.zzzcomputing.com> | 2021-01-07 20:58:55 +0000 |
| commit | 7f92fdbd8ec479a61c53c11921ce0688ad4dd94b (patch) | |
| tree | 332e8a4c93aedb0fd0f7487b0758c6e0a0fe2cbc /lib/sqlalchemy/sql | |
| parent | 489301137a4d76e5a46d754ae9c91aad2b3d2c1f (diff) | |
| parent | c12012452e11093a06e3c83c19fe4d794f5bb21e (diff) | |
| download | sqlalchemy-7f92fdbd8ec479a61c53c11921ce0688ad4dd94b.tar.gz | |
Merge "Remove special rule for TypeDecorator of TypeDecorator"
Diffstat (limited to 'lib/sqlalchemy/sql')
| -rw-r--r-- | lib/sqlalchemy/sql/type_api.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/sqlalchemy/sql/type_api.py b/lib/sqlalchemy/sql/type_api.py index 59e0f18dd..462a8763b 100644 --- a/lib/sqlalchemy/sql/type_api.py +++ b/lib/sqlalchemy/sql/type_api.py @@ -1082,8 +1082,7 @@ class TypeDecorator(SchemaEventTarget, TypeEngine): In most cases this returns a dialect-adapted form of the :class:`.TypeEngine` type represented by ``self.impl``. - Makes usage of :meth:`dialect_impl` but also traverses - into wrapped :class:`.TypeDecorator` instances. + Makes usage of :meth:`dialect_impl`. Behavior can be customized here by overriding :meth:`load_dialect_impl`. @@ -1091,8 +1090,6 @@ class TypeDecorator(SchemaEventTarget, TypeEngine): adapted = dialect.type_descriptor(self) if not isinstance(adapted, type(self)): return adapted - elif isinstance(self.impl, TypeDecorator): - return self.impl.type_engine(dialect) else: return self.load_dialect_impl(dialect) @@ -1117,7 +1114,6 @@ class TypeDecorator(SchemaEventTarget, TypeEngine): method. """ - # some dialects have a lookup for a TypeDecorator subclass directly. # postgresql.INTERVAL being the main example typ = self.dialect_impl(dialect) |
