From b8f601f038a2203af02a99ab190ebbc1c489549a Mon Sep 17 00:00:00 2001 From: Lele Gaifax Date: Thu, 15 Dec 2022 08:51:55 +0100 Subject: [PATCH] Rectify isinstance() check, using Range instead of dynamic class --- lib/sqlalchemy/dialects/postgresql/ranges.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/sqlalchemy/dialects/postgresql/ranges.py b/lib/sqlalchemy/dialects/postgresql/ranges.py index 210b399499..609af5eb62 100644 --- a/lib/sqlalchemy/dialects/postgresql/ranges.py +++ b/lib/sqlalchemy/dialects/postgresql/ranges.py @@ -289,7 +289,7 @@ class Range(Generic[_T]): bounds inclusivity, returning ``True`` if they are equal. """ - if not isinstance(other, self.__class__): + if not isinstance(other, Range): return NotImplemented if self.empty and other.empty: -- 2.47.2