Skip to content

Draft: add options to mix prune_objects to delete more things

Related issue: #3042

This is based on https://akkoma.dev/AkkomaGang/akkoma/pulls/350 and a few others. Commits:

This adds three options to mix prune_objects:

  • --keep-threads: Don't prune posts when they are part of a thread where at least one post has seen local interaction
  • --keep-non-public: Keep non-public posts like DM's and followers-only, even if they are remote.
  • --prune-orphaned-activities: Prune orphaned activities (Like, Announce, etc.) related to deleted posts. Note: very slow.

With --keep-non-public --prune-orphaned-activities, my database shrunk by about 60%.

Breaking change: the current task does not remove non-public posts by default. With this PR, administrators will need to use the --keep-non-public flag for the same behavior.

Checklist

  • Adding a changelog: In the changelog.d directory, create a file named <code>.<type>.

Merge request reports