From 14e14c5bbd9721e37bd3365186b6827339a723e0 Mon Sep 17 00:00:00 2001 From: Andy Freeland Date: Thu, 2 Jun 2022 09:23:40 -0700 Subject: [PATCH] Support caching `CIText` in SQLAlchemy's SQL compilation caching Fixes #25. --- citext/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/citext/__init__.py b/citext/__init__.py index b9c4bd9..5126aa6 100644 --- a/citext/__init__.py +++ b/citext/__init__.py @@ -10,6 +10,8 @@ class CIText(types.Concatenable, types.UserDefinedType): + cache_ok = True + # This is copied from the `literal_processor` of sqlalchemy's own `String` # type. def literal_processor(self, dialect):