From bb0359982616d32969c593b033400c2b4fa83c1b Mon Sep 17 00:00:00 2001 From: Martin Kofahl Date: Tue, 13 Mar 2018 08:52:39 +0100 Subject: [PATCH] Allow use of older sqlalchemy versionsby using outerjoin() instead of join(.., isouter=True). --- GeoHealthCheck/models.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/GeoHealthCheck/models.py b/GeoHealthCheck/models.py index d26ff7ee..b8f7bc68 100644 --- a/GeoHealthCheck/models.py +++ b/GeoHealthCheck/models.py @@ -273,9 +273,8 @@ def is_webhook(self): def burry_dead(cls): RN = ResourceNotification q = DB.session.query(cls)\ - .join(RN, - RN.recipient_id == cls.id, - isouter=True)\ + .outerjoin(RN, + RN.recipient_id == cls.id)\ .filter(RN.recipient_id.is_(None)) for item in q: DB.session.delete(item)