Page 4 of 11

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 4:18 am
by minimad
Hi All,

Re, the issue markus had with the config file.  If you tried 0.9.3 before it's release some of the config items have now been corrected.

main issue that no config item should have ' or " in them, e.g. SeasonNumber_Type was '1' before release its now just 1.

Please compare your config file with the new one for formatting

I'll add the relative path thingy to Trac, not a biggy to fix I think.

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 11:25 am
by markus101
Hi Minimad,

To clarify I started with a fresh 0.9.3 config file as I had deleted 0.9.2 and was still using the old school 0.8.8. Figured it was best to start fresh as everything was working proper now and I know screwed up some of the config before.

If you're referring to out put

Code: Select all

'MEDIA LOCATION - LINUX'
it's because Python quoted it like that when it through the error, although it was not quoted in the config file.

I use a Shell script to call tv_rss.py which helps me bypass the relative path issue, works for now, but a true fix is welcomed.

Code: Select all

#! /bin/bash
    
set -u

cd /boot/scripts/tv_rss
echo "Current Directory is: $PWD"
python /boot/scripts/tv_rss/tv_rss.py
Hope the above helps clarify my issue. I've also setup a ticket in Trac for the relative path (sorry should have done that last night).

-Markus

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 4:40 pm
by JohnnyV
Edit: Read my following post

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 5:29 pm
by minimad
Hi JohnnyV,

The colon is irrelevant, NewzBin are added to SAB using the NewzBin ID and not the web address. the line after ADD QUEUE should be REPORT ID which confirms that it found a NEWzBin ID.

Do you have duplicate checking enabled on SAB?  If so then it will look like its not adding but in reality it has added it but SAB has discounted it as a duplicate, that one caught me out for a while when I was testing, now I remember to clear out the nzb backup directory before every test.

Do you have Authentication enabled in SAB? could be related

I've just tested the NewzBin and its has added it every time.

Try it with a show you don't normally get.

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 7:26 pm
by JohnnyV
I did I added 2 empty show folders (shows I do not have) insuring that they are present in the rss feed. None get added and nothing is downloaded.
Something is wrong for me.

It shows it's trying to add them, shows a newzbin ID but nothing is added to SAB. Strange.
I triple checked everything. All the settings are correct. My IP to SAB is 100%. The old TV script runs fine so I know these settings are correct.
I have no idea whats going on here. Any suggestions?

UPDATE:
Ok found the issue. Its the SAB log Password and name. I do not use one and I have them blank. When I removed them from the code line:

Code: Select all

urllib.urlopen(my_SAB + "/sabnzbd/api?mode=addid&name=" + report_id + my_SAB_params + "&ma_username=" + my_SAB_username + "&ma_password=" + my_SAB_password)

TO

urllib.urlopen(my_SAB + "/sabnzbd/api?mode=addid&name=" + report_id + my_SAB_params)
It added to queue perfectly.
There is an issue if you do not use web login (Name/Password) in SAB.

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 10:03 pm
by pilGrim
Hey all,

I am back after a week of mohitos and sun and then a week of work travel.  I am trying to catch up and it looks like a LOT has happened with the script.  I just downloaded the 0.9.3 files, set my config file and when trying to run the code hits a snag on line 123:

fileloghandler = dailylogrotation.DailyRollingFileHandler(errorlog)

My debug log shows:

Traceback (most recent call last):
  File "C:\Users\Admin\Python Scripts\tv_rss.py", line 123, in
    fileloghandler = dailylogrotation.DailyRollingFileHandler(errorlog)
  File "C:\Users\Admin\Python Scripts\dailylogrotation.py", line 63, in __init__
    logging.FileHandler.__init__(self, self.getFilename(), mode)
  File "C:\Python26\lib\logging\__init__.py", line 790, in __init__
    stream = self._open()
  File "C:\Python26\lib\logging\__init__.py", line 810, in _open
    stream = open(self.baseFilename, self.mode)
IOError: [Errno 2] No such file or directory: 'C:\\var\\SSD-2009-02-28.log'


Did I miss some setup instructions somewhere in the file?

TIA

Re: SABnzbd Smart Downloader

Posted: February 27th, 2009, 11:51 pm
by JohnnyV
pilGrim wrote: Hey all,

I am back after a week of mohitos and sun and then a week of work travel.  I am trying to catch up and it looks like a LOT has happened with the script.  I just downloaded the 0.9.3 files, set my config file and when trying to run the code hits a snag on line 123:

fileloghandler = dailylogrotation.DailyRollingFileHandler(errorlog)

My debug log shows:

Traceback (most recent call last):
  File "C:\Users\Admin\Python Scripts\tv_rss.py", line 123, in
    fileloghandler = dailylogrotation.DailyRollingFileHandler(errorlog)
  File "C:\Users\Admin\Python Scripts\dailylogrotation.py", line 63, in __init__
    logging.FileHandler.__init__(self, self.getFilename(), mode)
  File "C:\Python26\lib\logging\__init__.py", line 790, in __init__
    stream = self._open()
  File "C:\Python26\lib\logging\__init__.py", line 810, in _open
    stream = open(self.baseFilename, self.mode)
IOError: [Errno 2] No such file or directory: 'C:\\var\\SSD-2009-02-28.log'


Did I miss some setup instructions somewhere in the file?

TIA
I had this same issue myself. It was not able to create the 'var' folder to place the log files correctly. I corrected this by re-defining the directoy in the main cfg file.
For me '/var/log.cfg' did not work.
My script is located in a folder  c:\TV Scripts\
So I did '/TV Scripts/var/log.cfg' and manually added the 'var' folder.

Re: SABnzbd Smart Downloader

Posted: February 28th, 2009, 5:29 am
by minimad
oops.  I really should have updated the README.

Good spot JohnnyV, but you don't need the /var , you can point the log file anywhere,  /var is for my Linux system and python defaults that to C: on a Windows system.  So you could put D:\SSD.log or Z:\This is my SSD file with a really long file name.whatever etc.

I'll raise a ticket for creating the dirs if not found.

Re: SABnzbd Smart Downloader

Posted: February 28th, 2009, 11:09 am
by pilGrim
Thanks got it now.  I was thinking that "var" was a variable for the main drive path.  I had not really looked at the code yet.  Seems to be working now.

minimad, is the blackhole rename download feature working?  I set it to True and found that it did not dl an episode of CSI.  Was hoping it would rename the NZB as CSI Crime Scene Investigation.   Darn SABnzbd always dls as CSI and then I have to manually move the shows.  I guess I could change the directory structure now as I think the script should work with just plan ol CSI.

New script looks like it is working great.  Just need to figure out the aliases and blackhole feature work.

We should pool out efforts and put together some good documentation for the newbies.  When I first started playing with these scripts I was major lost as I had never used python or scripts on my pc. 

:-)

Re: SABnzbd Smart Downloader

Posted: February 28th, 2009, 4:14 pm
by minimad
Hi Greg,

Good to be back? :-)

The 'Blackhole' is working, just tested with nzbs.org & good eats (not a show I've ever go, it was just in the feed), downloaded two nzbs to my folder.  Was the show in the nzb backups?

Aliases, shouldn't be to hard to figure out, normally it be one name to another, but it can accept regex's, if you notice it's a reasonable one for CSI NY :-) (took me about 1/2 hour of tweaking on that one alone)

User Documentation - Ah, you've got me there, never my strong point, I usually get the User Testing team to write that for me (they have a better way of reaching the 'user')

Re: SABnzbd Smart Downloader

Posted: February 28th, 2009, 11:20 pm
by pilGrim
minimad wrote: Hi Greg,

Good to be back? :-)

The 'Blackhole' is working, just tested with nzbs.org & good eats (not a show I've ever go, it was just in the feed), downloaded two nzbs to my folder.  Was the show in the nzb backups?

Aliases, shouldn't be to hard to figure out, normally it be one name to another, but it can accept regex's, if you notice it's a reasonable one for CSI NY :-) (took me about 1/2 hour of tweaking on that one alone)

User Documentation - Ah, you've got me there, never my strong point, I usually get the User Testing team to write that for me (they have a better way of reaching the 'user')
Good to be back?  yes and no.. haha..  Mohitos, pool, spa and general relaxing is great but there does come a point where you are ready to get back.  Problem is worked is so backed up right now I kinda wish I was back by the pool.

For CSI, yes I did remove it from the SABnzbd already downloaded folder, so it would not get caught up there.  I was using a TVBINZ feed and I walked through the code step by step and it looked like it hit the download line of code, but nothing happened.  Maybe works with NZBs.org and not TVBINZ?  I can test later today with NZBs.org.  I guess I can switch over to that feed.

Will report back after I test.  Right now I am wrestling with the movie script code and suggestions you gave me. 

Regarding documentation, I don't mind starting it at some point soon, maybe the others using will want to pitch in. 

Re: SABnzbd Smart Downloader

Posted: March 1st, 2009, 8:56 pm
by pinion
I've downloaded .93 from the /tag directory and configured SSD.cfg to what should be everything.  I'm using linux so I run the command sudo python2.5 rss_tv.py and it goes through the feed and finds a file I want and says it ads it but it doesn't.  I tried downloading the nzb to the blackhole and nothing show up there either nor does anything get added to sab.  Anyone else have problems with it not adding the files?

BTW, I was using .88 before with no problems but I've changed to using linux now from running it under FreeNAS so I figured I'd start from scratch.

I was just checking and the nzb's actually got downloaded but wouldn't open because they had an error.  Maybe it had something to do with the permission since I was running the command sudo.  I changed the logs to a different dir so it owuld run and I'm trying it again but it appears nothing is still being automatically put in my queue.  And actually it's saying "INFO FAILED PROCESSING:"

Re: SABnzbd Smart Downloader

Posted: March 2nd, 2009, 11:01 am
by imthenachoman
I am new to sabnzbd and so far I love it

I found this post for an autodownloader but I cannot figure out how to download it and install it.

Any help please? I realize it is a dumb question but I'm still trying to understand how all this stuff works...

Thanks

Re: SABnzbd Smart Downloader

Posted: March 2nd, 2009, 12:52 pm
by markus101
imthenachoman wrote: I am new to sabnzbd and so far I love it

I found this post for an autodownloader but I cannot figure out how to download it and install it.

Any help please? I realize it is a dumb question but I'm still trying to understand how all this stuff works...

Thanks
You will need to install python (if you're using anything other than Windows this should already be installed). Then you will need to download and configure the script. Once configured you run it with the following:

Code: Select all

python tv_rss.py
Hope this helps,

Markus

Re: SABnzbd Smart Downloader

Posted: March 2nd, 2009, 2:01 pm
by markus101
I found what appears to be a nasty bug with this script running on Linux. If I download a show that has In/The/A in it, SAB rename each word in a show's title to start that word with a capital letter, but Words in titles are not capitalized unless they are "meaningful" in/the/a should be lower case in a title, unless it starts the Title.

This appears to force this script to download a show over and over (SAB catches the duplicates if they were recently downloaded though). I downloaded two shows yesterday that had this odd behavior, but did not have ' or () in the title, yet the SAB warnings show these Episodes trying to download numerous times. This script is properly picking up the show (as it is now compared lower-case), but it doesn't look like specific episodes are being compared lower-case, but instead it is looking for exact matches, which it won't find.

I'm creating a ticket in Trac, but thought I would point this out on the forums as well.

EDIT: Looks like the episodes are being compared case-insensitive (good), but somehow the path is not. IE a show with "In" (where it should be "in") as the folder gets re-downloaded repeatedly, but if that same show "in" is proper it does not.

-Markus