From d5adcaf76c6de5518c0b63237eb4e81d1119a291 Mon Sep 17 00:00:00 2001 From: spiral Date: Sat, 10 Dec 2022 16:50:43 +0000 Subject: [PATCH] fix(bot): ignore "out of shared memory" postgres error --- PluralKit.Bot/Utils/MiscUtils.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/PluralKit.Bot/Utils/MiscUtils.cs b/PluralKit.Bot/Utils/MiscUtils.cs index 6845d858..e60ef52e 100644 --- a/PluralKit.Bot/Utils/MiscUtils.cs +++ b/PluralKit.Bot/Utils/MiscUtils.cs @@ -70,6 +70,9 @@ public static class MiscUtils // Ignore *other* "database is shutting down" error (57P01) if (e is PostgresException pe2 && pe2.SqlState == "57P01") return false; + // ignore "out of shared memory" error + if (e is PostgresException pe3 && pe3.SqlState == "53200") return false; + // Ignore database timing out as well. if (e is NpgsqlException tpe && tpe.InnerException is TimeoutException) return false;