sqlalchemy icon indicating copy to clipboard operation
sqlalchemy copied to clipboard

Deprecate array any/all implementation specific implementations

Open CaselIT opened this issue 2 years ago • 2 comments

These method have a peculiar signature that's quite different from the rest of the api.

Since there are alternatives these should be deprecated in 2.1

CaselIT avatar Jan 03 '24 00:01 CaselIT

searching around it looks like this starts with:

https://github.com/sqlalchemy/sqlalchemy/blob/a04deb60ac28fa9e2555bb89ffdcd676514ef05d/lib/sqlalchemy/dialects/postgresql/array.py#L50C1-L74C1

and then these two which are marked legacy (so they are already legacy)

https://github.com/sqlalchemy/sqlalchemy/blob/a04deb60ac28fa9e2555bb89ffdcd676514ef05d/lib/sqlalchemy/sql/sqltypes.py#L3119C8-L3215C14

so folks use just any_() and all_() going forward

zzzeek avatar Sep 20 '25 15:09 zzzeek

Mike Bayer has proposed a fix for this issue in the main branch:

deprecate ARRAY.any(), ARRAY.all(), postgresql.Any(), postgresql.All() https://gerrit.sqlalchemy.org/c/sqlalchemy/sqlalchemy/+/6155

sqla-tester avatar Sep 20 '25 17:09 sqla-tester