]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Revise setinputsizes approach
authorMike Bayer <mike_mp@zzzcomputing.com>
Sun, 19 Jul 2020 21:39:14 +0000 (17:39 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Sun, 19 Jul 2020 21:45:41 +0000 (17:45 -0400)
commit83b3ce6b7c7991d2faf314dc44571de9e6e9c27b
tree35e789e551aae9f15a2dd40a9ab66f38f0ba3cfb
parent547e959157f841f4f6d1e405ceed14755fcbd0bd
Revise setinputsizes approach

in order to support asyncpg as well as pg8000,
we need to revise setinputsizes to work for more cases as well
as adjust NativeForEmulated a bit to work more completely with
the INTERVAL datatype.

- put most of the setinputsizes work into the compiler where
the computation can be cached.

- support per-element setinputsizes for a tuple

- adjust TypeDecorator so that _unwrapped_dialect_impl
will honor a type that the dialect links to directly in
it's adaption mapping.    Decouble _unwrapped_dialect_impl
from TypeDecorator._gen_dialect_impl() which has a different
purpose.   This allows setinputsizes to do the right thing
with the INTERVAL datatype.

- test cases for Oracle with Variant continue to work

Change-Id: I9e1ea33aeca3b92b365daa4a356d778191070c03
lib/sqlalchemy/engine/default.py
lib/sqlalchemy/sql/compiler.py
lib/sqlalchemy/sql/type_api.py