Drone Factory is Deprecated [unrar]

I’ve mentioned this above, but I now have my setup using the DownloadEpisodesScan API, so am not using Complete Download Handling or the Drone Factory, so can we have a way of turning off the health check warning “Enable Completed Download Handling or configure Drone factory” please.

For new users I think its a good waning, but for existing, there should be a way of switching it off, as with myself I’m not using any deprecated sonarr features now but am getting this waning.

Unfortunately remote drive mounting isn’t available with this particular seedbox as it is a bit unconventional but suits the needs from a price / utility standpoint.

The seedbox does have a nice utility that can be run on the local machine which transfers torrent pieces as they arrive on the server. When all the pieces have been received the utility assembles them into the final files / directories and places them in a folder (which Drone Factory has been monitoring).

The utility has this option which I’m guessing should be able to provide the path parameter:

file_finished_command: specify a command/script to execute whenever a file finishes. 3 parameters will be passed: the file path, the info hash for the torrent, and the label. it is possible the label has been subjected to cleanup if you enabled cleanup_filenames and include_label_in_file_names.

What I am not sure is how to make a script to achieve this as I have zero experience :confused:

Would you be able to give me some pointers, preferably for powershell as I’m running windows.

Thanks!

OK, Reading all this and all related things made me few things to conclude.

  1. Drone Factory is very useful, quick to setup, slice food, blend, sort, cook, serve on plate, … but occasionally cut few fingers and mix them in smoothy so you can’t be sure until you try the end product.
  2. It will go
  3. I really need it due the facts/settings/stated below in appendix
  4. Solution needs to be made.

so regarding above statements:

  1. Currently I can’t live without it. I’m missing only few fingers (read episodes over the time I use Sonarr) as I carefully used/set my clients and scripts to minimize probability of that happening. eg. I have Download client setup but do not use it as I use DirectDownload client which is neither NZB not Torrent.
  2. Huh, well even hard at times it was loved and I will come to funeral
  3. Ahh, read appendix
  4. Ok. Solution found but needs to be polished.

Appendix:
I have custom made client that handles both DL + Unpack + Move to Join folder (eg. drone folder) and say I’m done. Just wrote Jscript to tell me that, so I have an DL client Event that contain path+filename where the file is saved, but do not know which show it belongs simply can’t know that and this even I can use to trigger downloadedepisodesscan. Hooray, 50% done.

I need help for next 50 percent which involves making Jscript that will work both on Win and linux.
I was thinking about something like this:

// Sending and receiving data in JSON format using POST mothod
//
var xhr = new XMLHttpRequest();
var url = "url";
xhr.open("POST", url, true);
xhr.setRequestHeader("Content-type", "application/json");
xhr.setRequestHeader("X-Api-Key","MyKey");
xhr.onreadystatechange = function () {
    if (xhr.readyState === 4 && xhr.status === 200) {
        var json = JSON.parse(xhr.responseText);
    }
};
var data = JSON.stringify({"name": "downloadedepisodesscan","path": "/serverA/var/temp/Download.S01E01","importMode":"Move","downloadClientId":"{infohash}"});
xhr.send(data);

So anyone help Please?

Windows 10 Pro/ Sonarr/ altbinz/ drone factory/ 4TB NAS. My set up has been working great for a long time. I hope that I can figure out how to replace drone factory. Subscribed.

@dhcrees Why not simply keep Completed Download Handling enabled, assuming you provide the downloadClientID in the API command, it should be properly handled. And that way you can see which downloads have not yet been imported.

@spurf Something like this https://gist.github.com/Taloth/e02e76bcb29942f791cc2e8595192846
No warranties, and you’ll need to tweak and test it.

@Peke I’d say it’s a good start, but I’m no JScript expert. You probably don’t need to set downloadClientID since you’re using a DirectDownload client.

@wtfchuck What’s special about your setup that it requires a Drone Factory? If you’re insistent on using alt.binz, consider using the Usenet Blackhole client in Sonarr to interface with it. But I’d recommend using sabnzbd or nzbget for better integration and failed download handling.

1 Like

@ everybody else, If you have a specific usecase or problems with switching away from using the Drone Factory, or would like advice on how to do so.
Please open a new topic, preferably with the format “Import without Drone Factory [usecase]” where ‘usecase’ is something unique with your setup, ‘seedbox’, ‘btsync’, ‘unrar’ etc.
Or post in a topic that already mentions your exact usecase.
It’ll help to keep threads specific to a particular usecase, or I’ll lose track of it all and end up making replies like you see above here. :smiley:

1 Like

@seanvree To get back to the topic OP posted, could you take a look at nzbToMedia? I thought it was usenet only but clinton hall appears to have quite a bit of torrent support, transcoding and unrar, and has built in support for the DownloadedEpisodesScan command. It might match your particular usecase for unrar.
At least, if you still want to spend time on it, coz I can imagine you’ve had enough…

Thanks for the help. Drone factory is gone and completed DL handling is working. Black Hole.

@taloth ,

Yeah, looks good. I was using it the past, but I can’t remember why I bailed on it.

Got it working mostly…the only thing I’m not seeing is how to envoke the DownloadedEpisodesScan which would tell Sonarr to look in the directory for the extracted file.

Fantastic work @Taloth will test ASAP

All:

I ALMOST have this working perfectly on windows… No scripts, all automatic and NO Blackhole Directory!!!

.Doing some testing. I’ll write a tutorial and post it here when I’m done.

Yo dudes,

We ALMOST have this working. If you want to join the discussion, see below:

All:

After many hours of jameson and formatting, I’ve completed a new guid which is MUCH MORE lightweight and streamlined to get this problem done, it’s tested, and it works. HERE:

Hi @Taloth. I can confirm your powershell script works exactly as expected :smile:

I added an extra bit of code after your filter “#TODO: Filter on Label?” to end the script if the torrent doesn’t match the ‘tv’ label that I use for Sonarr

if ($Label -NotMatch ‘tv’) {
Write-Host "Not for Sonarr"
break
}

I couldn’t get the utility I use to download from my seedbox provider to execute the powershell script directly but found I could get it to run a batch file instead with this command inside:

start /min “” powershell.exe -ExecutionPolicy Bypass -noexit -file “D:\Down\Sonarr.ps1” D:\Down%1 %2 %3

I needed the ‘D:\Down%1’ as the utility doesn’t pass the full windows directory for the downloaded file location.

Thanks again!

Tnx for the update, I appreciate that.

Please note that -NotMatch is a Regex match and, since it lacks anchors, would match ‘fdfdtvdjf’ as well. I suspect you intended to use -ne (not equal).

Anyway, nice work.

Thnaks for that, I was wondering what the differnce was between -eq & -match. Couldn’t work it out from my google searches :flushed:

The episodes successfully import into Sonarr but I’m getting this message in my Sonarr log:

External directory scan request for unknown download 8f925c36b5c9514c8a96a4bfdd9d6e67ed36b23c, attempting normal import. [D:\Down\downloads\tv############.mkv

Is this OK?

I checked, the infohash must be upper case: 'downloadClientId' = $InfoHash.ToUpper() should do it.

1 Like

Awesome! It’s this bit of code in your script?

$command = @{
‘name’ = “DownloadedEpisodesScan”
‘path’ = $FilePath
’importMode’ = ‘Move’
‘downloadClientId’ = $InfoHash.ToUpper()
} | ConvertTo-Json

yup, that’s what I meant.

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.