Page 1 of 1

Cannot create final folder

Posted: September 1st, 2020, 12:09 pm
by PiERiT
Some completed downloads (not all) are failing to extract to my NAS with the following error. I thought this was maybe due to the 3.0.1 bug where NZB names weren't being parsed as strings, causing issues with names containing numbers, but the problem is persisting in 3.0.2. Never happened in 2.X.X. Any ideas?

Code: Select all

a few seconds ago Cannot create final folder \\?\UNC\Matt-NAS\Share\1109-UhjiRAdwaYamRZNV4Z95
ERROR a few seconds ago Failed making (\\Matt-NAS\Share)
Traceback (most recent call last):
  File "sabnzbd\filesystem.py", line 560, in create_all_dirs
  File "os.py", line 213, in makedirs
  File "os.py", line 213, in makedirs
  File "os.py", line 223, in makedirs
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: '\\\\?\\UNC\\'

Re: Cannot create final folder

Posted: September 2nd, 2020, 2:09 am
by safihre
I tried to reproduce but couldn't.
Maybe you can enable +Debug logging in the status and Interface settings window and then after it happens again send me the whole log at [email protected].
I wonder why some jobs fail and some don't.
Do you maybe have specific folders setup in Categories?

Re: Cannot create final folder

Posted: September 2nd, 2020, 10:58 am
by PiERiT
Sorry, yes, I am using categories. The one in this instance has the Folder/Path configured as:

\\Matt-NAS\Share*

The * is to have it put the files in that Share folder as opposed to a subfolder named after the NZB. If I remove the *, that fixes the issue. Is there another way to accomplish this? Let me know if you still want the debug logs, too.

Re: Cannot create final folder

Posted: September 3rd, 2020, 2:23 am
by safihre
I can reproduce it now. Very strange.
It seems it fails because the directory already exsists. Seems like a python bug.

Re: Cannot create final folder

Posted: September 3rd, 2020, 10:06 am
by PiERiT
Is there another way to have jobs not create extra folders? Maybe something in the Sorting options?

Re: Cannot create final folder

Posted: September 3rd, 2020, 2:31 pm
by safihre
Hmm, not really at this point. I need to make a workaround in the code.

For reference, the bug at Python: https://bugs.python.org/issue41705

Re: Cannot create final folder

Posted: September 3rd, 2020, 2:53 pm
by safihre
I updated the code, in a few minutes you should be able to download a patched release here:
https://github.com/sabnzbd/sabbuild/rel ... est-build1

Re: Cannot create final folder

Posted: September 3rd, 2020, 7:38 pm
by PiERiT
That worked but direct unpack is very slow now. It only unpacked 31% of an 11GB file by the time the downloaded completed in 3m45s. In 2.X.X it would have unpacked all of it.

Is that some side effect of the workaround you had to make? That's fine if so and I'll figure out which problem is more bothersome and go with the lesser one. I just thought I'd mention it in case it shouldn't be occurring.

I appreciate your help. Thanks.

Re: Cannot create final folder

Posted: September 4th, 2020, 1:59 am
by safihre
Direct Unpack didn't change between 2.3.9 and now.
I am pretty sure it's the download itself: either the uploader used compression (non-regular uploaders usually do this) so unpacking takes much more CPU and memory, or for example a middle RAR-file is missing so it has to pause direct unpack until that one is downloaded.

Re: Cannot create final folder

Posted: September 4th, 2020, 9:03 am
by PiERiT
Hmm ok, I must be misremembering how long this particular download took to extract in older versions.

Thanks again.

Re: Cannot create final folder

Posted: September 13th, 2020, 3:24 pm
by PiERiT
Was this workaround not included in 3.0.2? I am having the same issue again, or a very similar one. Are you able to re-host the hotfix version for me please? The link from Sep 3rd 404's.

Code: Select all

ERROR a few seconds ago Failed making (\\Matt-NAS\Share)
Traceback (most recent call last):
  File "sabnzbd\filesystem.py", line 560, in create_all_dirs
  File "os.py", line 213, in makedirs
  File "os.py", line 213, in makedirs
  File "os.py", line 223, in makedirs
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: '\\\\?\\UNC\\'

Re: Cannot create final folder

Posted: September 13th, 2020, 4:15 pm
by sander
PiERiT wrote: September 13th, 2020, 3:24 pm Was this workaround not included in 3.0.2? I am having the same issue again, or a very similar one. Are you able to re-host the hotfix version for me please? The link from Sep 3rd 404's.

Code: Select all

ERROR a few seconds ago Failed making (\\Matt-NAS\Share)
Traceback (most recent call last):
  File "sabnzbd\filesystem.py", line 560, in create_all_dirs
  File "os.py", line 213, in makedirs
  File "os.py", line 213, in makedirs
  File "os.py", line 223, in makedirs
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: '\\\\?\\UNC\\'
I think you need SABnzbd 3.1.0 Beta 2. See https://sabnzbd.org/downloads#

Re: Cannot create final folder

Posted: September 13th, 2020, 4:35 pm
by PiERiT
sander wrote: September 13th, 2020, 4:15 pm
PiERiT wrote: September 13th, 2020, 3:24 pm Was this workaround not included in 3.0.2? I am having the same issue again, or a very similar one. Are you able to re-host the hotfix version for me please? The link from Sep 3rd 404's.

Code: Select all

ERROR a few seconds ago Failed making (\\Matt-NAS\Share)
Traceback (most recent call last):
  File "sabnzbd\filesystem.py", line 560, in create_all_dirs
  File "os.py", line 213, in makedirs
  File "os.py", line 213, in makedirs
  File "os.py", line 223, in makedirs
OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: '\\\\?\\UNC\\'
I think you need SABnzbd 3.1.0 Beta 2. See https://sabnzbd.org/downloads#
Perfect. Thank you.

Re: Cannot create final folder

Posted: November 16th, 2021, 6:51 am
by PearsonFlyer
I know this is pretty old, but I am on version 3.4.2 and experiencing this intermittent problem on Windows using a networked drivepool for my final destination.

Code: Select all

2021-11-16 01:21:12,565::INFO::[postproc:436] Finished unpack_magic on Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX
2021-11-16 01:21:12,621::INFO::[notifier:122] Sending notification: Error - Error renaming "I:\sab\complete\tv\_UNPACK_Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX" to "I:\sab\complete\tv\Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX" (type=error, job_cat=None)
2021-11-16 01:21:12,621::ERROR::[postproc:496] Error renaming "I:\sab\complete\tv\_UNPACK_Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX" to "I:\sab\complete\tv\Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX"
2021-11-16 01:21:12,621::INFO::[postproc:501] Traceback: 
Traceback (most recent call last):
  File "sabnzbd\postproc.py", line 494, in process_job
  File "sabnzbd\postproc.py", line 1189, in rename_and_collapse_folder
  File "sabnzbd\decorators.py", line 36, in call_func
  File "sabnzbd\filesystem.py", line 939, in renamer
FileExistsError: [WinError 183] Cannot create a file when that file already exists: '\\\\?\\I:\\sab\\complete\\tv\\_UNPACK_Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX' -> '\\\\?\\I:\\sab\\complete\\tv\\Maid.S01.1080p.NF.WEB-DL.DDP5.1.DV.HEVC-FLUX'
Any thoughts on how I can resolve this? I'm happy to provide more logs, debug logs, or whatever else you need. I didn't in this case because it appears you know what the issue is - but that it had been resolved with a workaround in an earlier version.

Thanks!

Re: Cannot create final folder

Posted: November 16th, 2021, 7:49 am
by sander
But this is a unique, not-seen-before message: "FileExistsError: [WinError 183] Cannot create a file when that file already exists: "
And FYI: this is just what the operating system tells SABnzbd

First things first: what if you download that same NZB with Complete on your local disk (not your networked drive pool I: )?