Autodownload script
Re: Autodownload script
Thanks markus! It did help me get started although I'm running this under Freenas with FreeBSD and for some reason I still can't get it to run right. Freenas says it can't execute the cron job. I'm asking over in there forums for help.
I ran into a problem with the TV show script where as I'm trying to download Judge Judy for my wife but the show name is like this Judge.Judy.S07E046.PDTV.XviD-W4F where as there is an extra 0 in the episode number which causes errors. Could this be fixed easily?
I ran into a problem with the TV show script where as I'm trying to download Judge Judy for my wife but the show name is like this Judge.Judy.S07E046.PDTV.XviD-W4F where as there is an extra 0 in the episode number which causes errors. Could this be fixed easily?
-
- Release Testers
- Posts: 7
- Joined: December 1st, 2008, 9:11 am
Re: Autodownload script
Okay, I figured out a way to adjust the movie script to check against the rottentomatoes rating. Right now it will download a movie from the nzbs.org rss-feed if the imdb or rottentomatoes rating is higher than 75. I am not at home in Python, so it is a bit of a hack, but hopefully someone will find it useful.
http://pastebin.com/f4e673063
Adjust the rss-feed and the directories at the start of the script.
http://pastebin.com/f4e673063
Adjust the rss-feed and the directories at the start of the script.
Re: Autodownload script
Mmmm new version. Does it fix by chance searching for folders negating case? I'm having issues with The Office (US) versus The Office (Us), SAB likes to rename the files after download to The Office (Us), whereas this script looks for The Office (US), which means either it won't automatically download, or it just attempts to download it until its out off the RSS feed (SAB rejects it as a duplicate NZB file which is nice).
Looking forward to the update.
-Markus
Looking forward to the update.
-Markus
Co-developer of NzbDrone (.Net NNTP PVR) - http://www.nzbdrone.com
Re: Autodownload script
Ok, I'm not sure exactly what happened but today the script picked up the extra 0 in the episode number just fine and downloaded the other episodes. Now I'm wondering if there is a way to output to a file the shows matched and shows not matched so I know if I'm missing something I may want.
Re: Autodownload script
I use redirection in Linux, shouldn't be an issue as the same exists for Windows.
Just run the command like this for example:
>> appends to a file
> erases the file and starts a new one
You can either call the above from command line directly or via a shell script, I use a shell script, which I call from cron, then I can add more commands without changes (or remove the logging).
For Windows a bat file would work great (plus can be called from scheduled tasks).
Hope this helps,
Markis
Just run the command like this for example:
Code: Select all
python /boot/scripts/rss_tv.py >> /mnt/staging/SABnzbd/logs/rss_tv_nb.log
> erases the file and starts a new one
You can either call the above from command line directly or via a shell script, I use a shell script, which I call from cron, then I can add more commands without changes (or remove the logging).
For Windows a bat file would work great (plus can be called from scheduled tasks).
Hope this helps,
Markis
Co-developer of NzbDrone (.Net NNTP PVR) - http://www.nzbdrone.com
Re: Autodownload script
Thanks Markus. That's exactly what I'm looking for. I'm actually running SABnzbd on my FreeNAS box that runs FreeBSD. I know about enough to get into trouble but I do have sabnzbd running and these scripts going as cron jobs now so I guess that's better than some. Thanks for all the help!
Re: Autodownload script
Haha no problem... I started running SAB on my unRAID Server, based on Slackware 12.1, I'm in the same boat, know enough to be deadly. I think the worse I've done is trying to run mplayer and mencoder on it to convert MKVs to MP4's... doesn't work at all, but the combining multiple AVI's works...go figure. Glad I can help, FreeNAS was going to be my storage server of choice until I discovered unRAID (http://www.lime-technology.com).
-Markus
-Markus
Co-developer of NzbDrone (.Net NNTP PVR) - http://www.nzbdrone.com
Re: Autodownload script
What are you doing to combine the multiple avi's for movies that are two discs and what not? That may be worth it's own thread on how you got that going in a linux environment.
Re: Autodownload script
Will do, I'm using a script I found here and modified it, I ended up posting the steps over on the unRAID forums, but didn't think of posting it here. I'll have to re-write a bi as it was very specific to unRAID (using slackware packages), but it shoudl work find for other flavors. I'll see what I can do to get that up a bit later today...
EDIT: Uploaded what I did in Slackware to get it going...hopefully it points you in the right direction, its not 100% specific to Slackware, but it leans that way for sure.
http://forums.sabnzbd.org/index.php?topic=1712.0
-Markus
EDIT: Uploaded what I did in Slackware to get it going...hopefully it points you in the right direction, its not 100% specific to Slackware, but it leans that way for sure.
http://forums.sabnzbd.org/index.php?topic=1712.0
-Markus
Last edited by markus101 on February 4th, 2009, 11:44 am, edited 1 time in total.
Co-developer of NzbDrone (.Net NNTP PVR) - http://www.nzbdrone.com
Re: Autodownload script
Got a solution for the US shows where Newzbin/TheTVDB look for (US) and SAB renames them to (Us), check out this thread with switches fixed attached to his post: http://forums.sabnzbd.org/http://forums ... 667#p10667
It will only work with Newzbin, as other RSS feeds drop the () around US, I have it working on a trunk version of SAB, but it should work for 0.4.6 as well, it requires editing a python file, so it won't work with Windows Compiled Binaries (unless they still call the python files?).\
-Markus
It will only work with Newzbin, as other RSS feeds drop the () around US, I have it working on a trunk version of SAB, but it should work for 0.4.6 as well, it requires editing a python file, so it won't work with Windows Compiled Binaries (unless they still call the python files?).\
-Markus
Co-developer of NzbDrone (.Net NNTP PVR) - http://www.nzbdrone.com
Re: Autodownload script
Hi Markus,
Good call. Looked at the other thread and made the changes that the devs suggested.
http://pastebin.com/f5bc3244f
Is version 0.88.
Does slow the script down a bit (by maybe upto half a second per entry, depending on number of shows in your library)
Good call. Looked at the other thread and made the changes that the devs suggested.
http://pastebin.com/f5bc3244f
Is version 0.88.
Does slow the script down a bit (by maybe upto half a second per entry, depending on number of shows in your library)
Re: Autodownload script
Hi,
Woohoo an update to test out, glad to see you're still working on it. The Down will be manageable, better than editing the tvsort.py on each new version, although that would've have been worth it in the long run. Glad to see it was a pretty easy fix - On both sides of the field. Hopefully they do commit the changes they made as a switch, I'd love to see that as an option, just to make it look cleaner.
As always I look forward to testing it out and seeing the magic happen. I'll post back my feedback once I get a chance to test it out.
EDIT: I was talking with someone that recently got into Newsgroups/SAB. They have their folder structure as follows, they've played with other options, but haven't found anything that worked as well for them as RSS Feeds did in uTorrent (with smart episode matching as they call it).
Windows based...
Sounds like they'd be interested in the script, if it could handle their semi-obscure naming structure.
Cheers,
Markus
Woohoo an update to test out, glad to see you're still working on it. The Down will be manageable, better than editing the tvsort.py on each new version, although that would've have been worth it in the long run. Glad to see it was a pretty easy fix - On both sides of the field. Hopefully they do commit the changes they made as a switch, I'd love to see that as an option, just to make it look cleaner.
As always I look forward to testing it out and seeing the magic happen. I'll post back my feedback once I get a chance to test it out.
EDIT: I was talking with someone that recently got into Newsgroups/SAB. They have their folder structure as follows, they've played with other options, but haven't found anything that worked as well for them as RSS Feeds did in uTorrent (with smart episode matching as they call it).
Windows based...
Code: Select all
Z:\tv\Series Name\Season 1\S01E01 - Show Name.mkv
Cheers,
Markus
Last edited by markus101 on February 6th, 2009, 6:42 pm, edited 1 time in total.
Co-developer of NzbDrone (.Net NNTP PVR) - http://www.nzbdrone.com
Re: Autodownload script
minimad,
Have you fixed the issue with 1 digit season numbers in the folder names? (ie: /mnt/user/tv/Lost/Season 1/Lost 1x01 - Pilot.avi)
Have you fixed the issue with 1 digit season numbers in the folder names? (ie: /mnt/user/tv/Lost/Season 1/Lost 1x01 - Pilot.avi)
Re: Autodownload script
EDIT**
Disregard I think it was just a no internet connection thing. I was confused because I was getting to the box but the box didn't connect to the outside.
Anyone else getting this error now with version 0.88?
Disregard I think it was just a no internet connection thing. I was confused because I was getting to the box but the box didn't connect to the outside.
Anyone else getting this error now with version 0.88?
Code: Select all
PROCESS NZB FEED: http://feeds.feedburner.com/minimad
FEED: Other
Traceback (most recent call last):
File "rsstv.py", line 755, in <module>
Main()
File "rsstv.py", line 692, in Main
dom=xml.dom.minidom.parse(urllib.urlopen(feed))
File "/usr/local/lib/python2.5/urllib.py", line 82, in urlopen
return opener.open(url)
File "/usr/local/lib/python2.5/urllib.py", line 190, in open
return getattr(self, name)(url)
File "/usr/local/lib/python2.5/urllib.py", line 325, in open_http
h.endheaders()
File "/usr/local/lib/python2.5/httplib.py", line 860, in endheaders
self._send_output()
File "/usr/local/lib/python2.5/httplib.py", line 732, in _send_output
self.send(msg)
File "/usr/local/lib/python2.5/httplib.py", line 699, in send
self.connect()
File "/usr/local/lib/python2.5/httplib.py", line 683, in connect
raise socket.error, msg
IOError: [Errno socket error] (51, 'Network is unreachable')
Last edited by pinion on February 8th, 2009, 8:04 pm, edited 1 time in total.
Re: Autodownload script
Hi Stokkes,
Nope, not quite fixed it, I have a solution (I think) but battling with python to do what I want it to do. I'm able to turn the 1 into 01 but i seem to be having trouble turning back the other way.
Not spent much time since the other night (not moved more than 10 feet from bed to bathroom if you know what I mean).
Nope, not quite fixed it, I have a solution (I think) but battling with python to do what I want it to do. I'm able to turn the 1 into 01 but i seem to be having trouble turning back the other way.
Not spent much time since the other night (not moved more than 10 feet from bed to bathroom if you know what I mean).