Torrents keep redownloading after removal and blacklisting

Sonarr version 4.0.4.1491:
Mono version N/A:
OS Unraid 6.12.8
Debug logs: gist:304f25400e60e3fbd638e13a45ec706b (github.com)
Description of issue: I run a cleanup script that removes stalled downloads from my Sonarr and Radarr queues and blocklists them. This issue also occurs when I do it manually so it is not related to that. Once such items are blocklisted, Sonarr searches for other releases as is intended. However, it always decides to re-download the same ones again each time, as if it does not care that they are blocklisted. From what I have read in the logs, it IS blocklisting them, but it just downloads again anyway. I use Prowlarr which is connected directly to the indexers (1337x, BitSearch, EZTV, Internet Archive, Isohunt2, kickasstorrents.ws, TBP). I have attached debug logs from a few seconds before and after the cleanup script ran so you can see what happeend. The two files that seem to be constantly added to the blocklist(the list is full of duplicate entries for them) are:
Ray.Donovan.S05E03.1080p.WEB.H264 DEFLATE [rarbg] and
South.Park.S17E04.Goth.Kids.3.Dawn.of.the.Posers.1080p.WEB-DL.AAC2.0.H.264 NTb [PublicHD]

I have had this problem since I have used Sonarr, it does not happen only in this release. Hopefully someone else has experience with this. Thanks.