Page 8 of 10

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 03 Nov 2017, 20:21
by hati39
Hi and thanks for this script!

Problem:
Added about 600 nzbs to the queue, unrar downloads manually, sucks after 100+ files...
Found this script, got python work, got script work (I'm still running win 7).
Have still 450++ file collections with different pwds in the queue. How do I run the script on these? I tried to choose "post-process again" on the failed files from the history, without success. Any ideas?
Unbenannt.png

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 24 Aug 2018, 08:28
by zaemon
Thanks for the hard work put into this script.

The problem I have with it is the following: the script processes every single file in the NZB directory even if the file does not have the .nzb extension.

Example: I download a rared NZB. The rar file is processed. Then nothing happens because the rar file is renamed and the NZB not extracted (logical). If I put manually the unrared NZB into the NZB directory, the script processes it correctly and extracts the password.

Any thoughts?

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 21 Feb 2019, 21:44
by Raki72
Is there a script available that runs with Python 2.7.10 on Windows 10 with nzbget 20.0? I've tried the scripts here and none of them worked (yes, I changed the first line to the python.exe executable).

Kind Time Text
INFO Thu Feb 21 2019 22:41:52 Collection CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}} added to history
ERROR Thu Feb 21 2019 22:41:52 Unpack for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}} failed
WARNING Thu Feb 21 2019 22:41:52 Interrupted unpack for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
WARNING Thu Feb 21 2019 22:41:52 Cancelling unpack for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}} due to errors
INFO Thu Feb 21 2019 22:41:52 Unrar: The specified password is incorrect.
INFO Thu Feb 21 2019 22:41:52 Unrar: Extracting from CikDcV2Oyo40080.part1.rar
INFO Thu Feb 21 2019 22:41:52 Unrar: UNRAR 5.50 x86 freeware Copyright (c) 1993-2017 Alexander Roshal
DETAIL Thu Feb 21 2019 22:41:52 Unpacking into W:\finished\CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}\_unpack
INFO Thu Feb 21 2019 22:41:52 Unpacking CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
INFO Thu Feb 21 2019 22:41:52 No renamed archive files found for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
INFO Thu Feb 21 2019 22:41:52 Checking renamed archive files for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
INFO Thu Feb 21 2019 22:41:51 No renamed files found for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
INFO Thu Feb 21 2019 22:41:51 Loaded par2-file CikDcV2Oyo40080.par2 for par-rename
INFO Thu Feb 21 2019 22:41:51 Checking renamed files for CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
INFO Thu Feb 21 2019 22:41:51 Queueing CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}} for post-processing
INFO Thu Feb 21 2019 22:41:51 CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}} returned from history back to download queue
INFO Thu Feb 21 2019 22:41:51 Post-processing again CikDcV2Oyo40080{{1NIMK3SyAMX6eRu8}}
INFO Thu Feb 21 2019 22:41:45 nzbget 20.0 server-mode

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 06 Mar 2019, 00:48
by lantura
Any help for this issues with NZBget v20.0?
* script is displayed in the setting view (left side)
* Python v 3.5.1-0108 is installed (on Synology)
* script is activated in "extension scripts"
* EOL of script are Unix

Result is that the file is shown in Download view but the password is not extracted.

pfftn_3x: SyntaxError: invalid syntax
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: ^
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: print('[NZB] NZBNAME=', f, sep='')
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: File "/output/_sys/scripts/pfftn_3x.py", line 91
INFO Wed Mar 06 2019 01:09:11 Executing scan-script pfftn_3x.py for <filename>{{password}}.nzb
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: SyntaxError: invalid syntax
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: ^
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: print('[NZB] NZBNAME=', f, sep='')
INFO Wed Mar 06 2019 01:09:11 pfftn_3x: File "/output/_sys/scripts/pfftn_3x.py", line 91
Wed Mar 06 2019 01:09:11 Executing scan-script pfftn_3x.py for <filename>{{password}}.nzb@SynoEAStream

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 08 Mar 2019, 23:21
by lantura
Any hints? Can anybody help? Thanks.

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 11 Mar 2019, 23:58
by abc08154711
Hi I'm trying to get that script to work but have no luck so far. I'm running NZBGet 20.0 on Raspbian OS and should be able to use either Python 2.x or 3.x. I tried both but neither works.
The scripts do have the same rights than the builtin scripts EMail.py - even groups and owner are same - so I can rule that out.
The script appears on the left side between the other scripts in the settings page. I use categories and put the 2.x version or 3.x version in there. I already tried not using categories and putting both of the scripts (not at the same time of course) in the extension scripts part.
I read that even if there is a problem somehow there should be at least something in the messages tab in NZBGet. In my case there is nothing. So nothing I can share to help figure out what's wrong here.
What's even more strange is that when i open the download in the history, click on Postprocess the pfftn extension isn't shown at all. What am I missing? Does anyone have a clue or even better had the same issue and knows how to solve it?

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 12 Mar 2019, 06:32
by hugbug
The script works when an nzb is added to queue. Now, when you have the script activated, add a new nzb to queue and check the messages if the script was executed. Maybe pause downloading before adding nzb to prevent nzb from downloading and reduce number of messages.

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 12 Mar 2019, 20:47
by abc08154711
Okay, that explains a lot. I thought the script works as post process script. So I got that all wrong. My bad. By pausing download I get the error messages i was hoping for. I hope that this will help to solve the problem.

The Python 2 Version drops the following errors:
Executing scan-script pfftn_2x.py for something{{password}}.nzb
pfftn_2x: Could not start /opt/nzbget/scripts/pfftn_2x.py: No such file or directory

Python 3 drops this errors:
Executing scan-script pfftn_3x.py for something{{password}}.nzb
pfftn_3x: File "/opt/nzbget/scripts/pfftn_3x.py", line 81
pfftn_3x: print('[NZB] NZBPR_*Unpack:Password=', p.group(1), sep='')
pfftn_3x: ^
pfftn_3x: SyntaxError: invalid syntax

Thanks a lot for helping me so far.

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 13 Mar 2019, 06:01
by hugbug
To make Python 2 version work you need to change the first line of the script or use option ShellOverride in nzbget.

Re: [Scan-Script] pfftn (formerly pass-from-file-to-nzbget.py)

Posted: 13 Mar 2019, 21:34
by abc08154711
That's it. I changed the path in the first line to where python is located and the python 2 version is running. thanks for your help.