It would be great to add per indexer seed ratio into Qbittorrent.
In #2272, where the per indexer seed ratio feature was added, it said that Qbittorrent did not have the capabilities to do this. As can be seen here https://github.com/qbittorrent/qBittorrent/issues/9033 it does, it was just undocumented.
Can it be set when a torrent is added? Without that it'll likely fail some time though appear successful to Sonarr (same as setting the the label fails occasionally).
@markus101 It appears to be a v2 api feature on qbit, didn't exist in v1.
And no, v2 does not support it on add.
Btw. It'd be prudent to add a v2 api proxy for qbit.
Any update on this ? Would be nice to get it done.
@Taloth -- thanks for this! Do you know when it's expected to land on master?
Do you know when it's expected to land on master?
No, I don't. I have no idea how many users on develop have qbit and it may take a while for them to notice any potential issues.
But if you want to test it and you're using the built-in updater: switch to develop, update, then switch back to master. That'll allow you to test this feature now, but still automatically get the next master release instead of any subsequent develop releases.
I use the latest master, and it works with qbit, sorta...
Every torrent get's the proper seed time rules (episode or season pack), but when sonarr removes the torrent from qbittorrent, it doesn't remove the files. Is this how Complete Download Handling should work for every other client as well? Only remove the torrent, but keep the file even in the download folder (I use hardlinks)
I used Deluge before, but it doesn't work with that either (i know, paused...)
Removal of the files has little to do with the seed criteria logic.
We tell qbit to remove the files using this api, here in the Sonarr sourcecode.
If the files aren't removed, then either we call the api incorrectly, or qbit has an issue, or the files you're talking about were not part of the torrent itself (in case of unrar for example).
As you said, sonarr only monitors the clients.
at grab it sends the seed goal to the client.
when the client reaches said goal, sonarr will remove the torrent (should it remove files as well?)
Sonarr doesn't remove the files, it tells the client to remove it along with the torrent itself.
OK, so the expected behavior is that qbittorrent removes the torrent and the file, when sonarr tells it, right? Well in my case it only removes the torrent. Is this expected or a bug?
Thanks!
I wouldn't expect it to only remove the torrent, but at the moment it's not possible to ascertain if that problem is caused by Sonarr or Qbit or something else.
https://github.com/qbittorrent/qBittorrent/wiki/Web-API-Documentation#delete-torrents
the v2 API was implemented recently, right?
Does the sonarr api call uses the 'deleteFiles' parameter or not? In the webUI if i click remove and tick the delete files, they are removed, so there is no permission issue or something.
Thank you for all the informaton btw!
Does the sonarr api call uses the 'deleteFiles' parameter or not?
Yes, we do, I linked to the specific code in an earlier comment. But the api call itself is logged at trace level.
Thanks for your help. It seems that qbittorrent auto removes these torrents, when the seed goal set by sonarr is reached. sonarr complete download handling has no chance to even do something.
I looked through the trace logs, and there were no 'deleteFiles' API calls, even after the torrent was removed from the client
Than I added a torrent with 3 minute seed goal (for test). After 1 minute, it was imported. After that I stopped sonarr, and the torrent was still removed from qbittorrent :(
after an additional hour of trying, I worked it out finally.
sonarr can (and will) set a per torrent seed goal. there is a global setting as well, and in there you can set what should be the action (pause or remove). I didn't have this global setting checked, but it was set to remove on the unticked line.
If I set the global setting to a value (irrelevant in my case, since sonarr will overwrite it with the per torrent setting) and set the pause action, the same action will be used by the per torrent seed goal as well. So the torrent will be paused, and sonarr will remove AND DELETE THE FILE as well.
I can't believe it, that I finally could reach this goal:) thanks for the information Taloth!
Nice work :)
Yes, unfortunately qbit doesn't have that remove/pause setting per torrent, otherwise I would override it.
Most helpful comment
Thanks for your help. It seems that qbittorrent auto removes these torrents, when the seed goal set by sonarr is reached. sonarr complete download handling has no chance to even do something.
I looked through the trace logs, and there were no 'deleteFiles' API calls, even after the torrent was removed from the client
Than I added a torrent with 3 minute seed goal (for test). After 1 minute, it was imported. After that I stopped sonarr, and the torrent was still removed from qbittorrent :(
after an additional hour of trying, I worked it out finally.
sonarr can (and will) set a per torrent seed goal. there is a global setting as well, and in there you can set what should be the action (pause or remove). I didn't have this global setting checked, but it was set to remove on the unticked line.
If I set the global setting to a value (irrelevant in my case, since sonarr will overwrite it with the per torrent setting) and set the pause action, the same action will be used by the per torrent seed goal as well. So the torrent will be paused, and sonarr will remove AND DELETE THE FILE as well.
I can't believe it, that I finally could reach this goal:) thanks for the information Taloth!