pymedusa / Medusa

Automatic Video Library Manager for TV Shows. It watches for new episodes of your favorite shows, and when they are posted it does its magic.
https://pymedusa.com
GNU General Public License v3.0
1.79k stars 276 forks source link

"Remove torrents from client" option ignoring Seed ratio and removes all torrents #6979

Open knowair opened 5 years ago

knowair commented 5 years ago

Describe the bug I have tried to use "Remove torrents from client" with Deluge daemon connected (tried deluge-web too with the same results) but it removes them after they have been Postprocessed (copy) rather than per the specified provider ratio. I have tested with public, private and jackett providers it's the same each time.

So it IS removing the torrent after it's been post-processed which is ok, but I can't use it for allowing any seeding time, which is what it should be for.

To replicate Connect to deluge set a provider to any ratio and enable "Remove torrents from client" under Search Settings

Medusa info:

TorrentChecker Logs

2019-07-24 10:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.018/-1.000] or seed idle limit Removing it: torrent-9
2019-07-24 10:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.870/5.000] or seed idle limit Removing it: torrent-8
2019-07-24 10:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.521/1.000] or seed idle limit Removing it: torrent-7
2019-07-24 10:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent not yet post-processed. Skipping: torrent-6
2019-07-24 10:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent not yet post-processed. Skipping: torrent-5
2019-07-24 10:12:44 INFO    TORRENTCHECKER :: [74c3f12] Checking DelugeD torrent status.
2019-07-24 09:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.006/-1.000] or seed idle limit Removing it: torrent-2
2019-07-24 09:12:45 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.389/1.000] or seed idle limit Removing it: torrent-1
2019-07-24 09:12:44 INFO    TORRENTCHECKER :: [74c3f12] Checking DelugeD torrent status.
2019-07-24 08:12:44 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.069/2.000] or seed idle limit Removing it: torrent-4
2019-07-24 08:12:44 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.000/2.000] or seed idle limit Removing it: torrent-3
2019-07-24 08:12:43 INFO    TORRENTCHECKER :: [74c3f12] Checking DelugeD torrent status.

From teh logs

I enabled "remove torrents" provider "Seed ratio" blank = downloader default 8am first 2 torrents removed without ratio being reached

I then changed settings, one provider "Seed ratio" 1 another changed to -1 seed forever 9am both torrents removed without ratio being reached

Tried again with provider 1 set to 1:1, provider 2 set to 5:1, and provider 3 set to -1 10am three torrents removed (2 not finished and left alone)

Don't know what "seed idle limit" is referring to there's no mention in the Medusa settings about it nor in Deluge

medariox commented 5 years ago

This will only work for torrents that you have added since setting the ratio. It will show the required ratio in your client. Torrents that were added prior to that won't have a required ratio and they will consequently be removed.

knowair commented 5 years ago

Yes, i thought that might be the case.... So each of in the logs posted each torrent was added after making the change to the provider ratio saving and restarting medusa, yet all are removed without meeting the adjusted ratio.

knowair commented 5 years ago

Just to be sure i've reset and tested again!

1st disabled the "Remove torrents from client" option. Saved and restarted Medusa

Setup Medusa with a single new provider with ratio saved as 1 Saved and restarted Medusa

Enabled "Remove torrents from client" Saved and restarted Medusa

Added new "wanted" episode which is detected and downloaded perfectly, the post-processing is completed and when the TORRENTCHECKER is next run it is deleted and in the log i get the same as before:

2019-07-26 12:17:56 INFO    TORRENTCHECKER :: [74c3f12] Torrent completed and reached minimum ratio: [0.227/1.000] or seed idle limit Removing it: torrent-test-1