]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
handle builtins types in annotations with __allow_unmapped__
authorPascal Corpet <pascal@co2ai.com>
Thu, 28 Sep 2023 18:08:23 +0000 (14:08 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Fri, 29 Sep 2023 15:00:48 +0000 (11:00 -0400)
commit37b1303d94f47d76f7e5ab3dbcc705161a93d6e7
treeac2a1f3a397058b0b37465b2d976469dfc3d1d5e
parent93146598a49d4a56e0bc0e0232ea9a9467250543
handle builtins types in annotations with __allow_unmapped__

Fixed issue with ``__allow_unmapped__`` declarative option where types that
were declared using collection types such as ``list[SomeClass]`` vs. the
typing construct ``List[SomeClass]`` would fail to be recognized correctly.
Pull request courtesy Pascal Corpet.

Fixes: #10385
Closes: #10390
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/10390
Pull-request-sha: f8796965aefc1852d4b1137d04bf811072a1a0e9

Change-Id: I114d29c3c076386508300e979371b0d760b761c7
doc/build/changelog/unreleased_20/10385.rst [new file with mode: 0644]
lib/sqlalchemy/util/typing.py
test/orm/declarative/test_tm_future_annotations_sync.py
test/orm/declarative/test_typed_mapping.py