Download quality not being categorised correctly

For some reason, I’m not able to make a trello card, so i’ll pop the report here.

I’ve got a couple of 720p HDTV episodes that nzbdrone has now found 1080p bluray’s for. It’s downloading the bluray but moving them to the library as hdtv. The next time it scans, it downloads the same release (because bluray > hdtv) but again imports it as hdtv. It’s doing this for a couple of episodes in the series (i’ve since turned the series to unmonitored to stop wasting bandwidth).

here’s the trace log: http://pastebin.com/PUa1evyn

Its because the file name doesn’t contain bluray in it. It contains 1080p, but without the bluray it would fallback to HDTV 1080p (or it should at least).

This is a problem I’ve seen a couple times, almost exclusive to BR releases, not an easy problem to handle since we can’t assume the file is in a folder with the quality.

I haven’t look at the API for sabnzbd, but…

Does sabnzbd return the download location? when nzbdrone passed it to sab, it knew it was a bluray. So if we could match up the download folder with the nzb, that might do it

Drone doesn’t get told when a download complete, but instead checks for completed downloads, this saves you from having to configure a script in SAB and avoids a possible issue if the location in SAB differs from drone due to them being on different systems.

What I’ve been thinking is to check the containing folder for the quality and if its something other than unknown use it for the quality instead of the file quality as theres not a way to check the file itself and determine the source, that would only work to determine its resolution.

Added to Trello: https://trello.com/c/f51f1Z1U/462-better-handling-of-file-names-that-don-t-contain-a-proper-quality

This is now in develop, it will make its way to master later on.