NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
PyPI · #888 most downloaded on PyPI
Various utility functions for SQLAlchemy.
Last release 9 months ago
13 Dec 2025
Release timing varies
gaps range from 8 days to 1.4 years
Nearly every release is documented
notes for 60 of the last 60 stable releases
6 versions withdrawn
withdrawn after publishing
14 years old
217 releases · first in 2013
Fixed import issue with latest version of SQLAlchemy
Fixed import issue with latest version of SQLAlchemy (#215)
Added LtreeType for PostgreSQL ltree extension
Added LtreeType for PostgreSQL ltree extension
Added Ltree primitive data type
One column per quarter.
Added support for PhoneNumber objects as composites
Added support for PhoneNumber objects as composites
Fixed PasswordType to not access LazyCryptContext on type init (#211, pull request courtesy of olegpidsadnyi)
Fixed PasswordType to not access LazyCryptContext on type init (#211, pull request courtesy of olegpidsadnyi)
Fixed database helpers for sqlite (#208, pull request courtesy of RobertDeRose)
Fixed database helpers for sqlite (#208, pull request courtesy of RobertDeRose)
Fixed TranslationHybrid aliased entities handling (#198, pull request courtesy of jmagnusson)
Made PasswordType to use LazyCryptContext by default (#204, courtesy of olegpidsadnyi)
Dropped py26 support
Made PasswordType to use LazyCryptContext by default (#204, courtesy of olegpidsadnyi)
Added literal parameter processing for ArrowType (#182, pull request courtesy of jmagnusson)
Added literal parameter processing for ArrowType (#182, pull request courtesy of jmagnusson)
Fixed scalar parsing of LocaleType
Fixed scalar parsing of LocaleType (#173)
Fixed column alias handling with assert_* functions
Fixed column alias handling with assert_* functions (#175)
Fixed non-ascii string handling in composite types
Fixed non-ascii string handling in composite types (#170)
Fixed observes crashing when observable root_obj is None
Fixed observes crashing when observable root_obj is None (#168)
Column observers only notified when actual changes have been made to underlying columns
Column observers only notified when actual changes have been made to underlying columns (#138)
Made has_index allow fk constraint as parameter
Made has_index allow fk constraint as parameter
Made has_unique_index allow fk constraint as parameter
Made the extra packages in setup.py to be returned in deterministic order (courtesy of thomasgoirand)
Removed is_indexed_foreign_key (superceded by more versatile has_index)
Fixed LocaleType territory parsing (courtesy of dahlia)
Added correlate parameter to select_correlated_expression function
Added correlate parameter to select_correlated_expression function
Fixed sort_query handling of aliased classes with hybrid properties
Fixed sort_query handling of aliased classes with hybrid properties
Added support for aliased classes in get_hybrid_properties utility function
Added support for aliased classes in get_hybrid_properties utility function
- Added cast_if utility function
Added cast_if utility function
Added support for InstrumentedAttributes, ColumnProperties and Columns in get_columns function
Added support for InstrumentedAttributes, ColumnProperties and Columns in get_columns function
Added support for PhoneNumber extensions
Added support for PhoneNumber extensions (#121)
Fix None type handling of ChoiceType
Fix None type handling of ChoiceType
Make locale casting for translation hybrid expressions cast locales on compilation phase. This extra lazy locale casting is needed in some cases where translation hybrid expressions are used before get_locale
function is available.
Added better support for dynamic locales in translation_hybrid
Added better support for dynamic locales in translation_hybrid
Make babel dependent primitive types to use Locale('en') for data validation instead of current locale. Using current locale leads to infinite recursion in cases where the loaded data has dependency to the loaded object's locale.
Added get_type utility function
Added get_type utility function
Added default parameter for array_agg function
Added row_to_json GenericFunction
Added Asterisk compiler
Added row_to_json GenericFunction
Added array_agg GenericFunction
Made quote function accept dialect object as the first paremeter
Made has_index work with tables without primary keys (#148)
Fixed CompositeType null handling
Fixed CompositeType null handling
Made psycopg2 requirement optional (#145, #146)
Made psycopg2 requirement optional (#145, #146)
Made CompositeArray work with tuples given as bind parameters
Fixed CompositeType bind parameter processing when one of the fields is of TypeDecorator type and CompositeType is used inside ARRAY type.
Fixed CompositeType bind parameter processing when one of the fields is of TypeDecorator type and
CompositeType is used inside ARRAY type.
Fixed CompositeType bind parameter processing when one of the fields is of TypeDecorator type.
Fixed CompositeType bind parameter processing when one of the fields is of TypeDecorator type.
Added length property to range types
Added length property to range types
Added CompositeType for PostgreSQL
Fixed assert_max_length, assert_non_nullable, assert_min_value and assert_max_value not properly raising an AssertionError when the assertion failed.
Fixed assert_max_length, assert_non_nullable, assert_min_value and assert_max_value not properly raising an AssertionError when the assertion failed.
Drop undocumented batch fetch feature. Let's wait until the inner workings of SQLAlchemy loading API is well-documented.
Drop undocumented batch fetch feature. Let's wait until the inner workings of SQLAlchemy loading API is well-documented.
Fixed GenericRelationshipProperty comparator to work with SA 1.0.x (#139)
Make all foreign key helpers SA 1.0 compliant
Make translation_hybrid expression work the same way as SQLAlchemy-i18n translation expressions
Update SQLAlchemy dependency to 1.0
Removed deprecated function generates
Added __hash__ method to Country class
Made Country validate itself during object initialization
Made Country string coercible
Removed deprecated function generates
Fixed observes function to work with simple column properties
Added CurrencyType (#19) and Currency class
Added CurrencyType (#19) and Currency class
Added get_class_by_table ORM utility function
Added get_class_by_table ORM utility function
Added Enum representation support for ChoiceType
Added Enum representation support for ChoiceType
Added customizable TranslationHybrid default value
Added customizable TranslationHybrid default value
Made assert_max_length support PostgreSQL array type
Made assert_max_length support PostgreSQL array type
Made CaseInsensitiveComparator not cast already lowercased types to lowercase
Made CaseInsensitiveComparator not cast already lowercased types to lowercase
Fixed analyze function runtime property handling for PostgreSQL >= 9.4
Fixed analyze function runtime property handling for PostgreSQL >= 9.4
Fixed drop_database and create_database identifier quoting (#122)
Removed deprecated defer_except (SQLAlchemy's own load_only should be used from now on)
Removed deprecated defer_except (SQLAlchemy's own load_only should be used from now on)
Added json_sql PostgreSQL helper function
Added assert_min_value and assert_max_value testing functions
Added assert_min_value and assert_max_value testing functions
Removed TSVectorType.match_tsquery (now replaced by TSVectorType.match to be compatible with SQLAlchemy)
Removed TSVectorType.match_tsquery (now replaced by TSVectorType.match to be compatible with SQLAlchemy)
Removed undocumented function tsvector_concat
Added support for TSVectorType concatenation through OR operator
Added documentation for TSVectorType (#102)
Made aggregated fully support column aliases
Made aggregated fully support column aliases
Changed test matrix to run all tests without any optional dependencies (as well as with all optional dependencies)
Fixed issue with Color importing
Fixed issue with Color importing (#104)
Improved EncryptedType to support more underlying_type's; now supports: Integer, Boolean, Date, Time, DateTime, ColorType, PhoneNumberType, Unicode(Te
Improved EncryptedType to support more underlying_type's; now supports: Integer, Boolean, Date, Time, DateTime, ColorType, PhoneNumberType, Unicode(Text), String(Text), Enum
Allow a callable to be used to lookup the key for EncryptedType
Added observes decorator (generates decorator will be deprecated later)
Fixed PhoneNumber string coercion (#93)
Added observes decorator (generates decorator will be deprecated later)
Added loose typed column checking support for get_column_key
Added loose typed column checking support for get_column_key
Made get_column_key throw UnmappedColumnError to be consistent with SQLAlchemy
Fixed column alias handling in dependent_objects
Fixed column alias handling in dependent_objects
Fixed aggregated decorator many-to-many relationship handling
Fixed aggregated decorator many-to-many relationship handling
Fixed aggregated column alias handling
Removed deprecated has_any_changes
Added is_loaded utility function
Removed deprecated has_any_changes
Added support for Column and ColumnEntity objects in get_mapper
Added support for Column and ColumnEntity objects in get_mapper
Made make_order_by_deterministic add deterministic column more aggressively
Fixed assert_max_length not working with non nullable columns
Fixed assert_max_length not working with non nullable columns
Add PostgreSQL < 9.2 support for drop_database
Made assert_* functions automatically rollback session
Made assert_* functions automatically rollback session
Changed make_order_by_deterministic attach order by primary key for queries without order by
Fixed alias handling in has_unique_index
Fixed alias handling in has_index
Fixed alias handling in make_order_by_deterministic
Added assert_non_nullable, assert_nullable and assert_max_length testing functions
Added assert_non_nullable, assert_nullable and assert_max_length testing functions
Added supported for various SQLAlchemy objects in make_order_by_deterministic (previosly this function threw exceptions for other than Column objects)
Added supported for various SQLAlchemy objects in make_order_by_deterministic (previosly this function threw exceptions for other than Column objects)
Fixed MapperEntity handling in get_mapper and get_tables utility functions
Fixed MapperEntity handling in get_mapper and get_tables utility functions
Fixed make_order_by_deterministic handling for queries without order by (no just silently ignores those rather than throws exception)
Made make_order_by_deterministic if given query uses strings as order by args
Added support for more SQLAlchemy based objects and classes in get_tables function
Added support for more SQLAlchemy based objects and classes in get_tables function
Added has_unique_index utility function
Added make_order_by_deterministic utility function
- Added EncryptedType
Added EncryptedType
Added explain and explain_analyze expressions
Added explain and explain_analyze expressions
Added analyze function
Fix aggregate value handling for cascade deleted objects
Fix aggregate value handling for cascade deleted objects
Fix ambiguous column sorting with join table inheritance in sort_query
Fix sort_query support for queries using mappers (not declarative classes) with calculated column properties
Fix sort_query support for queries using mappers (not declarative classes) with calculated column properties
Your coding agent can read these notes before it upgrades. Set up the MCP server →