From 9a0cb34c8c3a3c47ad5074bd73ad5369ee852192 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Mon, 12 Jul 2021 16:20:15 -0500 Subject: [PATCH 1/2] Fix Activity.delete_all_by_object_ap_id/1 timeout so users can be deleted --- lib/pleroma/activity.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pleroma/activity.ex b/lib/pleroma/activity.ex index 6542e684e..0d2cb91cd 100644 --- a/lib/pleroma/activity.ex +++ b/lib/pleroma/activity.ex @@ -286,7 +286,7 @@ defmodule Pleroma.Activity do |> Queries.by_object_id() |> Queries.exclude_type("Delete") |> select([u], u) - |> Repo.delete_all() + |> Repo.delete_all(timeout: :infinity) |> elem(1) |> Enum.find(fn %{data: %{"type" => "Create", "object" => ap_id}} when is_binary(ap_id) -> ap_id == id From 65514484cc5d8457a85e6c9d162da20f32210489 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Mon, 12 Jul 2021 16:59:54 -0500 Subject: [PATCH 2/2] CHANGELOG: fixed user deletion database timeout --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 036b9e775..8befe7476 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Checking activated Upload Filters for required commands. - Remote users can no longer reappear after being deleted. - Deactivated users may now be deleted. +- Deleting an activity with a lot of likes/boosts no longer causes a database timeout. - Mix task `pleroma.database prune_objects` - Linkify: Parsing crash with URLs ending in unbalanced closed paren, no path separator, and no query parameters