Sonarr version (exact version): 3.0.3.652
Mono version (if Sonarr is not running on Windows):
OS: Windows 10 (1903)
Debug logs:
(Make sure debug logging is enabled in settings and post the full log to hastebin/pastebin/dropbox/google drive or something similar, do not post them directly here. Post in .txt not .doc, .rtf or some other formatted document)
Description of issue:
I have been testing preferred words in v3 for the purpose of preferring HEVC/H265 releases with 10bit encoding and 5.1 audio.
Whilst the collection of preferred words I have selected has been largely successful, it still consistently fails when the uploader names the release incorrectly, because the preferred words engine seems to compare the file name of the original release rather than the carefully formed filename that I have configured via the renaming engine.
Here is an example:
I have the following preferred words set up
HEVC _ 0 points
x265 _ 0 points
H.265 _ 0 points
5.1 _ 0 points
6CH _ 0 points
10bit _ 0 poimts
2.0 _ -50 points
8 bit _ -10 points
x264 _ -100 points
(I use 0 points for my desired words, because I want to avoid doubling up on terms like HEVC & x265 which often both appear in release names and skews preferred word comparisons when given a positive score)
I monitor a series called Series.Name
Sonarr finds an early HEVC release called:
“Series.Name.S04E03.Episode.Name.1080p.AMZN.WEB-DL.DDP5.1.H.265 hevc SceneName.mkv”
The release name contains some of the preferred words I want (H.265, HEVC, 5.1) and is within the size limits for my quality profile, so it sends the release to my download client to be downloaded
So Far So Good
Once the file is downloaded, Sonarr renames the file and imports it into my library. My rename settings are:
{Series Title} - S{season:00}E{episode:00} - {Episode Title} - {MediaInfo VideoCodec}{MediaInfo VideoBitDepth}Bit - {MediaInfo AudioCodec}{MediaInfo AudioChannels} - {Quality Full}
So the renamed file is this:
Series.Name - S04E03 - Episode.Name - x265_10Bit - Opus_2.0 - WEBDL-1080p.mkv
You’ll notice that this is where the uploaders incorrectly named release is discovered. The file actually only has 2.0 audio, not 5.1 and also a different codec. We also discover at this point that the file is 10bit, which wasn’t in the original file name. (so an error and an omission in the original file name - at least in relation to the info that I am looking for)
Some time later, Sonarr finds another release. This time called:
“Series.Name.S04E03.Episode.Name.1080p.10bit.WEBRip.6CH.x265.HEVC-SceneName.mkv”
It checks this against the file in my library. I have Web-DL and Webrip as the same quality level and my quality cutoff is BluRay-1080p, to the first file “can be upgraded”
The new file passes all the std quality checks, so it compares the preferred words score
The new file has 3 of my preferred words (10bit, HEVC, 6CH), so it should have a higher score than the first file, which only has two of my preferred words (10bit, x265) and a non-preferred word (2.0) to which I have assigned a negative score
So the scores “should be”
current -50, new 0
and the new file should be downloaded and imported to upgrade the existing file
However, because the engine appears to be comparing against the original release name rather than my renamed file with the correct media info, we get the following entry in the debug log:
19-10-22 08:19:51.8|Debug|UpgradableSpecification|Comparing preferred word score. Current: 0 New: 0
and the new release is rejected (incorrectly, in my opinion) because “the existing file has an equal or better preferred word score”
In this particular example, this means that the only way to upgrade the existing file that is below my preferred level, is to find a release labelled BluRay-1080p, which will be months away at best
This system seems to be entirely dependent of the uploader naming their releases fully and correctly, but I don’t understand why we wouldn’t put some checks in to confirm this once the file is downloaded or even just give us the option to compare against the final file name (which will likely always contain the info the the individual user wants) rather than comparing against the original file name which most of the time will be inconsistent