Page 1 of 1

Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 30th, 2009, 4:16 pm
by Assmonkey
I'm not using any Unpacking on my downloads, just the PAR check. When the download completes and it gets moved according to what is set up in the categories, it first creates the folder with _UNPACK_ in the name. When it's done copying, it renames itself by removing the _UNPACK_ part. Why do this in the first place since it's basically just copying/moving the directory in question?
If someone enters the dir while SABnzbd is still copying files to it, SABnzbd won't be able to rename it since it's in use. Any way of stopping this behavior?

Re: Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 30th, 2009, 4:19 pm
by switch
There is no way to stop this behaviour currently.

We use it as an indication that the file is not yet complete, as moving or unpacking can take a long period, depending on whether it it being movied to other hard drives or partitions.

Yes _UNPACK_ is technically wrong and should maybe be changed to _MOVING_ however it is still a good indication that the download is not yet finished.

Re: Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 30th, 2009, 5:21 pm
by meh
Ah, that reminds me - if the unrar fails, the _UNPACK_ folder will remain. Maybe a rename would be in place, if possible.

Re: Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 30th, 2009, 5:31 pm
by switch
The folder should be renamed from _UNPACK_ to _FAILED_ assuming it is allowed to rename the folder by the operating system. If it isn't, please verify an anti-virus or media scanner is not preventing a rename from taking place and file a bug report.

Re: Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 31st, 2009, 1:36 am
by Assmonkey
Well technically the release/files are done, in the the complete folder, so all it is doing now is moving it to the folder entered in the category section. I just don't see the benefit of putting it into a folder and then rename the folder when it's done with the filecopy, imo it only creates more possible problems/things that can go wrong. :)

Re: Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 31st, 2009, 1:55 am
by switch
The files are moved from the incomplete folder directly to the category location. This can be on another drive, partition, or even over a network so it can take some time to complete. The rename of the folder is an easy way to tell from explorer that the download is not yet finished.

Re: Why rename to _UNPACK_ when it's just moving/copying the dir?

Posted: July 31st, 2009, 8:58 am
by Assmonkey
Any way to modify what it gets renamed to? Like you said, _UNPACK_ doesn't make much sense in my case and somebody accessing my server won't know what to do with a dir with that name.
I'd rather have it like this if it has to be renamed to something:

Dir_Name_Here.INCOMPLETE