commit: e509519db4fe6c9c0c3942ebd9ccb540439fba18
parent 776b069a04ae77a54374fca9714e8d304d93fd19
Author: Mark Felder <feld@feld.me>
Date: Sat, 20 Jul 2024 21:21:21 -0400
Publisher jobs will not retry if the error received is a 400
Diffstat:
2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/changelog.d/oban-cancel-badreq.change b/changelog.d/oban-cancel-badreq.change
@@ -0,0 +1 @@
+Publisher jobs will not retry if the error received is a 400
diff --git a/lib/pleroma/web/activity_pub/publisher.ex b/lib/pleroma/web/activity_pub/publisher.ex
@@ -123,6 +123,7 @@ defmodule Pleroma.Web.ActivityPub.Publisher do
Logger.error("Publisher failed to inbox #{inbox} with status #{code}")
case response do
+ %{status: 400} -> {:cancel, :bad_request}
%{status: 403} -> {:cancel, :forbidden}
%{status: 404} -> {:cancel, :not_found}
%{status: 410} -> {:cancel, :not_found}