Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to prefer magnet links for torrents #1799

Open
1 task done
datcactus opened this issue Jul 27, 2023 · 4 comments · May be fixed by #1800
Open
1 task done

Add option to prefer magnet links for torrents #1799

datcactus opened this issue Jul 27, 2023 · 4 comments · May be fixed by #1800
Assignees
Labels
Area: Indexer Issue is related to indexers. Status: Investigating We're looking in to it Type: Feature Request Issue is a feature request.

Comments

@datcactus
Copy link

Is there an existing issue for this?

  • I have searched the existing open and closed issues

Is your feature request related to a problem? Please describe

There are occasionally situations where a torrent name (so what shows up and is scored in Sonarr/Radarr for grab purposes) is different between the magnet link and the torrent file. This mainly affects anime as torrent/release naming vs file naming can vary significantly between various release groups, but could affect anything where these naming differences occur.

Example of a current VARYG release for Bleach from AnimeTosho:
Torrent name: Bleach Thousand-Year Blood War S01E16 The Fundamental Virulence 1080p NF WEB-DL AAC2.0 H 264-VARYG (Multi-Subs)
File name: Bleach.Thousand-Year.Blood.War.S01E16.The.Fundamental.Virulence.1080p.NF.WEB-DL.AAC2.0.H.264-VARYG.mkv
.torrent file name: Bleach.Thousand-Year.Blood.War.S01E16.The.Fundamental.Virulence.1080p.NF.WEB-DL.AAC2.0.H.264-VARYG.torrent
Magnet name: Bleach%20Thousand-Year%20Blood%20War%20S01E16%20The%20Fundamental%20Virulence%201080p%20NF%20WEB-DL%20AAC2.0%20H%20264-VARYG%20%28Multi-Subs%29 (url encoded, it's the same as the torrent name)

What happens in this scenario is that Sonarr will initially score the release high, but on import using the .torrent file it will be scored lower due to how the regex for VARYG is currently crafted. The regex is such that the release title must contain Multi-Subs to avoid their raw release as they have relatively poor naming. So it scores high initially (as it matches the regex via torrent name), but scores low on actual import. This has been noted to cause download loops as well. If added via magnet link (which Nyaa.si supports) the scoring is correct across the board and avoids issues.

Since the general recommendation is to not point automation at Nyaa.si it's not currently possible to automate magnet links from other sources that have magnet link support, such as AnimeTosho.

Describe the solution you'd like

Similar to how Nyaa.si is implemented in Prowlarr currently, add an option to toggle prefer magnet links.

Describe alternatives you've considered

N/A

Anything else?

N/A

@datcactus datcactus added Status: Needs Triage New Issue needing triage Type: Feature Request Issue is a feature request. labels Jul 27, 2023
@bakerboy448
Copy link
Contributor

the magnet hasn't the hash infohash in it

defer to @mynameisbogdan

@bakerboy448 bakerboy448 added Area: Indexer Issue is related to indexers. Priority: Low Issue does not affect Radarr functionality in a serious way. Status: Unlikely This issue is unlikely to be fixed, since it would only be useful to one person or is out of scope. labels Jul 27, 2023
@mynameisbogdan
Copy link
Contributor

We must check if we forgot parsing magnetUrl but I'm 100% sure we generate magnet urls based on infohash if non-private.

@mynameisbogdan mynameisbogdan self-assigned this Jul 27, 2023
@datcactus
Copy link
Author

datcactus commented Jul 27, 2023

@bakerboy448 I was chatting with bogdan about this one and a FR was requested for review. As far as it only being for tosho, the ask here was generic magnet support for torrent indexers but if the work involved proves to be overly complex it makes sense for it to be broken out if needed. I haven't tested with other anime indexers since I only have access to a couple of them, but the renaming isn't a tosho-specific thing. The source from Nyaa.si has the same behavior (and is resolved by preferring magnet) so it's probably just being copied directly over to tosho.

@mynameisbogdan
Copy link
Contributor

@mynameisbogdan mynameisbogdan linked a pull request Jul 27, 2023 that will close this issue
@bakerboy448 bakerboy448 added Status: Investigating We're looking in to it and removed Status: Needs Triage New Issue needing triage Priority: Low Issue does not affect Radarr functionality in a serious way. Status: Unlikely This issue is unlikely to be fixed, since it would only be useful to one person or is out of scope. labels Jul 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Indexer Issue is related to indexers. Status: Investigating We're looking in to it Type: Feature Request Issue is a feature request.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants