Unrar .rar files in .rar archives

Share your scripts or request scripts with specific features.
Forum rules
Please keep the forum clean - one topic per script. Questions not related to a specific script should be posted in Support forum.
EndoMorph
Posts: 5
Joined: 16 May 2015, 22:38

Re: Unrar .rar files in .rar archives

Post by EndoMorph » 16 May 2015, 22:47

Hello guys

i've got some errors with this script if the path or file contains spaces.
So here a short workaround for this problem (maybe i can help someone with the same problem!)

You must edit line 149 and 153 (line 149 is optional):

line 149:
replace the old

Code: Select all

print UnrarPath+" e -o- "+dirpath+"/"+file+" "+os.environ['NZBPP_DIRECTORY']
with this

Code: Select all

print UnrarPath+" e -o- '"+dirpath+"/"+file+"' '"+os.environ['NZBPP_DIRECTORY']+"'"
line 153:
replace the old

Code: Select all

retcode = subprocess.call(UnrarPath+" e -o- "+dirpath+"/"+file+" "+os.environ['NZBPP_DIRECTORY'], shell=True)
with this

Code: Select all

retcode = subprocess.call(UnrarPath+" e -o- '"+dirpath+"/"+file+"' '"+os.environ['NZBPP_DIRECTORY']+"'", shell=True)
Cheers

EndoMorph

starpc
Posts: 5
Joined: 03 Sep 2015, 20:29

Re: Unrar .rar files in .rar archives

Post by starpc » 04 Sep 2015, 02:07

Is there a newer version of the ExtendUnrar script available?

starpc
Posts: 5
Joined: 03 Sep 2015, 20:29

Re: Unrar .rar files in .rar archives

Post by starpc » 16 Sep 2015, 05:54

The script keeps failing for me :(

Code: Select all

ERROR	Tue Sep 15 2015 17:42:43	Post-process-script ExtendedUnrar.py for Random.2014.LIMITED.720p.BluRay.x264-DRONES failed (terminated with unknown status)
INFO	Tue Sep 15 2015 17:42:43	ExtendedUnrar: ValueError: could not convert string to float:
INFO	Tue Sep 15 2015 17:42:43	ExtendedUnrar: time.sleep(float(waittime))
INFO	Tue Sep 15 2015 17:42:43	ExtendedUnrar: File "C:\ProgramData\NZBGet\scripts\ExtendedUnrar.py", line 129, in <module>
INFO	Tue Sep 15 2015 17:42:43	ExtendedUnrar: Traceback (most recent call last):
INFO	Tue Sep 15 2015 17:42:43	ExtendedUnrar: Waiting seconds to give NZBGet time to delete old rar files
INFO	Tue Sep 15 2015 17:42:43	ExtendedUnrar: All preliminary checks successfully performed...

thorli
Posts: 5
Joined: 02 Jan 2015, 15:00

Re: Unrar .rar files in .rar archives

Post by thorli » 17 Oct 2015, 17:53

It seems that the timeout value is not correct, it must be a floting point value something like "5.0" then it should work.

You can configure it in the Web-Interface under Settings > ExtendedUnrar > WaitTime (see attached screenshot)

I have done this script quickly in the past so i have not implemented a thorough input value validation or type casting, sorry for that ;)
Attachments
ext-unrar-settings.jpg
Settings

kjKmcQN3
Posts: 61
Joined: 29 Aug 2015, 15:09

Re: Unrar .rar files in .rar archives

Post by kjKmcQN3 » 04 Dec 2017, 11:17

I stumbled upon this script while searching for a way to process .sub files that are double packed (.rar within a .rar).

Here is a typical scenario for double rared subtitle releases. The file Example.nzb contains the following files.
Example.rar
Example.r00
Example.r01
Example.r02
Example.r03
Example.subs.rar
Example.par2


The file Example.subs.rar, when unpacked, creates a folder Example.subs, which in turn has the files Example.idx and Example.rar. The Example.rar file has to be further unpacked to get the Example.sub file.

Here are my experiences with this script so far and the issues I faced.
  • The script doesn't always work. In a few instances it was able to output the .sub file but not always.
  • Every time I have run the script it has reported a failure (ExtendedUnrar: Unpack Failed with Returncode 10)
Given that it's been a while since this script was updated I would wondering if these issues are a result of it not being current with the latest developments on the NZBGet side of things.

@hugbug - Would it be possible to bake this functionality into NZBGet itself so that one doesn't have to rely on an external script? An elegant solution that takes care of double-rared files would be great! Thanks.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests