problem with script execution - timeout not applied - extractor

Specific support for Deluge on Microsoft Windows OS
Post Reply
Autocat
Member
Member
Posts: 19
Joined: Sun Nov 20, 2016 1:16 pm

problem with script execution - timeout not applied - extractor

Post by Autocat »

hi there,

Since windows 10 the extractor plugin is broken (actually never used it myself with other versions of windows), it sometimes works and sometimes doesn't. Probably related with the issue i am facing. In search for a script that could do the extracting I found the following batch script on reddit:

cd /D %3/%2
echo ScriptName: %0 id:%1 name: %2 folder: %3 >> 7ziplog.txt
echo "Waiting 90 seconds to flush to disk" >> 7ziplog.txt
TIMEOUT 90
echo "Attempting to Unzip" >> 7ziplog.txt
7z e *.rar >> 7ziplog.txt
echo "Script is exiting" >> 7ziplog.txt

Saved the bat file at C:\Scripts\simple_extract.bat.

It all looked very promising, when I executed the script from the torrent folder itself it worked perfectly. Log output:

ScriptName: "I:\Deluge\torrentname\simple_extract.bat" id: name: folder:
"Waiting 90 seconds to flush to disk"
"Attempting to Unzip"

7-Zip [32] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21

Scanning the drive for archives:
1 file, 50000000 bytes (48 MiB)

Extracting archive: torrentname.rar
--
Path = torrentname.rar
Type = Rar
Physical Size = 50000000
Total Physical Size = 1010404602
Characteristics = Volume FirstVolume VolCRC
Solid = -
Blocks = 1
Multivolume = +
Volume Index = 0
Volumes = 21

Everything is Ok

Size: 1010402061
Compressed: 1010404602
"Script is exiting"

After this test moving the script to the above specified folder and waited to see what happens when a torrent completes. It didnt work.. (actually it worked 1 time).

When the torrent finishes, for a very short moment of time I see a window opening and immediately closing, a log file appears in the folder which hold the completed torrent. Saying it was attempting to unzip, but failed. It seems the TIMEOUT is not getting applied because in the log file it directly shows that unzipping fails, while it should wait 90 seconds before attempting to unzip.

Is the execute plugin broken? Or am i am doing something wrong, hope someone can help me here.

Output in logfile:

ScriptName: C:\Scripts\simple_extract.bat id:3185aa484e48e20bfe8a79e38bc57f7fe53e16b8 name: torrentname folder: I:\Deluge
"Waiting 90 seconds to flush to disk"
"Attempting to Unzip"

7-Zip [32] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21

Scanning the drive for archives:
1 file, 50000000 bytes (48 MiB)

Extracting archive: torrentname.rar

Can't open as archive: 1
Files: 0
Size: 0
Compressed: 0
"Script is exiting"
Autocat
Member
Member
Posts: 19
Joined: Sun Nov 20, 2016 1:16 pm

Re: problem with script execution - timeout not applied - extractor

Post by Autocat »

I found a different approach to fully automate the extraction and deletion of torrents, and also to keep seeding, fully automated, will post it soon on this forum :)

Ifve started with a basic guide, you can find it here: http://forum.deluge-torrent.org/viewtop ... 12&t=54277
Post Reply