Recent versions of sab break job portability

Report & discuss bugs found in SABnzbd
Forum rules
Help us help you:
  • Are you using the latest stable version of SABnzbd? Downloads page.
  • Tell us what system you run SABnzbd on.
  • Adhere to the forum rules.
  • Do you experience problems during downloading?
    Check your connection in Status and Interface settings window.
    Use Test Server in Config > Servers.
    We will probably ask you to do a test using only basic settings.
  • Do you experience problems during repair or unpacking?
    Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Post Reply
Cpuroast
Release Testers
Release Testers
Posts: 69
Joined: December 15th, 2010, 11:19 pm

Recent versions of sab break job portability

Post by Cpuroast »

Hi,

In the past, I was able to pause a job, shutdown sab, move the job folder to sab's temp folder on another computer.
Then status, queue repair and click add. The other instance of sab would then resume exactly where the previous one left off and finish the job.

However 0.7.18 does not, upon import it instead tries to verify and repair a job which hasn't finished downloading. If I do retry and feed it the exact same nzb, it then resumes and all is good.

This was not needed in the past. So I dug a bit further and it seems a change in sab's behaviour now removes the nzb.gz file contained in the job's "__Admin__" folder shortly after the job starts which breaks job portability as the other instance of sab, has no reference to what the job was downloading.

If I pause sab, feed it an nzb, it creates a job folder in the temp folder and within it's "__Admin__" folder, it drops in a nzb.gz. If I unpause sab, the job starts and the nzb.gz gets removed shortly after, even before the job completes.

I don't see any reason for sab to erase the nzb.gz it created shortly after it created it, it should simply leave it until the job finishes which would allow job portability to function.
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Recent versions of sab break job portability

Post by shypike »

Cpuroast wrote: it seems a change in sab's behaviour now removes the nzb.gz file contained in the job's "__Admin__" folder shortly after the job starts
That would count as a bug.
I'll look into it.
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Recent versions of sab break job portability

Post by shypike »

Do you happen to have a debug log of this phenomenon?
I cannot reproduce it.
Could it be a question of access rights? Which OS are you using?
Cpuroast
Release Testers
Release Testers
Posts: 69
Joined: December 15th, 2010, 11:19 pm

Re: Recent versions of sab break job portability

Post by Cpuroast »

Sorry for the late late late reply.

So I ran the test again in 0.7.20 on OSX 10.9.5 and I seem to have found that it only occurs when you enable "Check before download".

From I gather in the logs, it seems to end up trying to wipe the entire "__ADMIN__" folder after the check completes, wiping the "SomeDownloadJob.nzb.gz" file in the process.

I have the full log if needed, I just cropped what seems relevant.

2015-04-07 19:55:19,258::DEBUG::[nzbstuff:1159] Download Quality: enough=True, have=2257852343, need=1958979540, ratio=1.15256555615
2015-04-07 19:55:19,258::DEBUG::[__init__:844] Saving data for SABnzbd_nzo_uNWSUx in /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,293::DEBUG::[nzbstuff:1159] Download Quality: enough=True, have=2257852343, need=1958979540, ratio=1.15256555615
2015-04-07 19:55:19,293::INFO::[__init__:908] /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__/SABnzbd_nzf_JPFHPC removed
2015-04-07 19:55:19,294::INFO::[__init__:908] /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__/SABnzbd_nzf_C4ZB4F removed
...
2015-04-07 19:55:19,530::INFO::[misc:1329] Cannot remove folder /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,531::INFO::[misc:1329] Cannot remove folder /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,534::INFO::[misc:1329] Cannot remove folder /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,534::INFO::[misc:1329] Cannot remove folder /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,535::DEBUG::[__init__:844] Saving data for SABnzbd_nzf_GnmsMp in /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,535::INFO::[nzbstuff:444] File SomeDownloadJob [01/58] - "SomeDownloadJob.par2" yEnc (1/1) added to queue
2015-04-07 19:55:19,537::DEBUG::[__init__:844] Saving data for SABnzbd_nzf_1yzg0c in /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,537::INFO::[nzbstuff:444] File SomeDownloadJob [02/58] - "SomeDownloadJob.part01.rar" yEnc (1/53) added to queue
...
2015-04-07 19:55:19,618::DEBUG::[nzbstuff:474] META-DATA = {}
2015-04-07 19:55:19,618::INFO::[__init__:584] Backing up /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__/SomeDownloadJob.nzb.gz
2015-04-07 19:55:19,631::INFO::[__init__:874] /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__/__renames__ missing
2015-04-07 19:55:19,633::INFO::[nzbqueue:218] Saving queue
2015-04-07 19:55:19,633::DEBUG::[__init__:844] Saving data for SABnzbd_nzo_B6CBGD in /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,635::DEBUG::[__init__:844] Saving data for SABnzbd_nzo_B6CBGD in /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__
2015-04-07 19:55:19,637::INFO::[__init__:919] Saving data for queue9.sab in /Users/CpuroastXP/Library/Application Support/SABnzbd/admin/queue9.sab
2015-04-07 19:55:20,259::DEBUG::[nzbstuff:209] Finishing import on SomeDownloadJob [01/58] - "SomeDownloadJob.par2" yEnc (1/1)
2015-04-07 19:55:20,259::DEBUG::[__init__:878] Loading data for SABnzbd_nzf_GnmsMp from Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__/SABnzbd_nzf_GnmsMp
2015-04-07 19:55:20,260::DEBUG::[nzbstuff:209] Finishing import on SomeDownloadJob [02/58] - "SomeDownloadJob.part01.rar" yEnc (1/53)
2015-04-07 19:55:20,260::DEBUG::[__init__:878] Loading data for SABnzbd_nzf_1yzg0c from /Users/CpuroastXP/Downloads/SABnzbd/Temporary/SomeDownloadJob/__ADMIN__/SABnzbd_nzf_1yzg0c
...
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Recent versions of sab break job portability

Post by shypike »

You are right, but the bug is also very old.
In fact it has been wrong since introduction of pre-check.
However, the bug is also limited to pre-check.
I'll seen what I can do for 0.8.0, but we're not really recommending the usage any more.
The "Abort if completion is not possible" is a better choice,
unless you have very low caps or only use a block server.

Good detective work!
Cpuroast
Release Testers
Release Testers
Posts: 69
Joined: December 15th, 2010, 11:19 pm

Re: Recent versions of sab break job portability

Post by Cpuroast »

I like using pre-check, it guarantees the download will work, and with 10 connections to both eu and us servers on both unlimited and block fill server, it's actually very fast since it spins up 40 connections, and goes through all articles very quickly.

I assume you won't be fixing it in 0.7.x and I'll have to wait until 0.8.0 is released?
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Recent versions of sab break job portability

Post by shypike »

Cpuroast wrote: I assume you won't be fixing it in 0.7.x and I'll have to wait until 0.8.0 is released?
Pre-check has more problems than this.
(Like not subtracting files manually deleted from the NZB when calculating the required amount.)
Like I said, I have doubts about spending much more effort on this feature.
Maybe in 0.8.0.
But there won't be a new 0.7.x unless there is a very pressing reason.
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Recent versions of sab break job portability

Post by shypike »

The nzb.gz problem will be fixed in the first Alpha release of 0.8.0
(Next weekend)
Post Reply