Sourced from sqlalchemy's releases.
2.0.44
Released: October 10, 2025
platform
- [platform] [bug] Unblocked automatic greenlet installation for Python 3.14 now that there are greenlet wheels on pypi for python 3.14.
orm
[orm] [usecase] The way ORM Annotated Declarative interprets Python PEP 695 type aliases in
Mapped[]
annotations has been refined to expand the lookup scheme. A PEP 695 type can now be resolved based on either its direct presence in_orm.registry.type_annotation_map
or its immediate resolved value, as long as a recursive lookup across multiple PEP 695 types is not required for it to resolve. This change reverses part of the restrictions introduced in 2.0.37 as part of #11955, which deprecated (and disallowed in 2.1) the ability to resolve any PEP 695 type that was not explicitly present in_orm.registry.type_annotation_map
. Recursive lookups of PEP 695 types remains deprecated in 2.0 and disallowed in version 2.1, as do implicit lookups ofNewType
types without an entry in_orm.registry.type_annotation_map
.Additionally, new support has been added for generic PEP 695 aliases that refer to PEP 593
Annotated
constructs containing_orm.mapped_column()
configurations. See the sections below for examples.References: #12829
[orm] [bug] Fixed a caching issue where
_orm.with_loader_criteria()
would incorrectly reuse cached bound parameter values when used with_sql.CompoundSelect
constructs such as_sql.union()
. The issue was caused by the cache key for compound selects not including the execution options that are part of the_sql.Executable
base class, which_orm.with_loader_criteria()
uses to apply its criteria dynamically. The fix ensures that compound selects and other executable constructs properly include execution options in their cache key traversal.References: #12905
engine
- [engine] [bug] Implemented initial support for free-threaded Python by adding new tests and reworking the test harness to include Python 3.13t and Python 3.14t in
... (truncated)