XBMC Community Forum
Sick Beard - Automatic TV Show Episode download/sort/rename, nfo/tbn maker & TV Guide - Printable Version

+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Help and Support (/forumdisplay.php?fid=33)
+--- Forum: Supplementary Tools for XBMC (/forumdisplay.php?fid=116)
+--- Thread: Sick Beard - Automatic TV Show Episode download/sort/rename, nfo/tbn maker & TV Guide (/showthread.php?tid=63591)



- midgetspy - 2010-04-06 18:30

NZBMatrix Users: Update your Sick Beard!

They have changed the API rules to require only one search every 60 seconds, which means old version of Sick Beard will be considered hammering. The newest Git and windows build 442 have a forced timeout when using NZBMatrix.

Also NZBMatrix is the worst provider in every way, use NZBs.org if you want one that doesn't suck.


Sinister: post logs for the post processing problems. If the output verbosity is wrong please post the output and the equivalent sickbeard.log section so I can compare them.

wattershed: No there is no support for every episode in its own folder. I've never understood the reasoning for such a silly structure but it's been requested a few times so it'll probably happen eventually.


Manual Post-Processing Log - Pr.Sinister - 2010-04-06 18:50

What i see in Sick Beard :

Code:
Postprocessing results
Processing folder E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE
Auto processing file: E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv

sickbeard.log

Code:
Apr-06 12:41:35 DEBUG    CP Server Thread-8 :: sickbeard.db: SELECT COUNT(*) FROM tv_episodes WHERE season != 0 AND episode != 0 AND status=4
Apr-06 12:41:35 DEBUG    CP Server Thread-8 :: sickbeard.db: SELECT COUNT(*) FROM tv_episodes WHERE season != 0 AND episode != 0 AND airdate <= 733868
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Processing folder E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: sickbeard.db: SELECT * FROM tv_shows
Apr-06 12:41:43 INFO     CP Server Thread-8 :: Auto processing file: E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Processing file E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv (with folder name None and NZB name None)
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Attempting to parse name E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Found the show in our list, continuing
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: TVDB thinks the file is The Pacific1x4
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: 85539: An object for episode 1x4 didn't exist in the cache, trying to create it
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: 85539: Loading episode details from DB for episode 1x4
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: sickbeard.db: SELECT * FROM tv_episodes WHERE showid = 85539 AND season = 1 AND episode = 4
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: 85539: Loading episode details from theTVDB for episode 1x4
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: 85539: Setting status for 1x4 based on status Snatched and existence of
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: 85539: Saving episode details to database
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: STATUS IS 2
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: sickbeard.db: UPDATE tv_episodes SET status = ?, tvdbid = ?, airdate = ?, location = ?, description = ?, hasnfo = ?, hastbn = ?, name = ? WHERE season = ? AND showid = ? AND episode = ? with args [2, u'446091', 733866, '', u'Finally enlisted as a Marine, Sledge trains for combat at Camp Elliott. The 1st Marine Division lands at Cape Gloucester on the Japanese-held island of New Britain. As Leckie and the other Marines battle the Japanese, they quickly realize that the more ominous enemy is the smothering jungle itself. Having survived Gloucester and stationed on the godforsaken island of Pavuvu, Leckie begins displaying the physical and mental effects of combat and is sent to a naval hospital on nearby Banika for psychiatric observation.', False, False, u'Gloucester - Pavuvu - Banika', 1, 85539, 4]
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: sickbeard.db: INSERT INTO history (action, date, showid, season, episode, quality, resource, provider) VALUES (?,?,?,?,?,?,?,?) with args [3, '20100406124143', 85539, 1, 4, -1, u'E:\\Downloads\\~TV\\Process\\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv', -1]
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Sending notification for The Pacific - 1x04 - Gloucester - Pavuvu - Banika
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Encoded message is Download+Finished%2CThe+Pacific+-+1x04+-+Gloucester+-+Pavuvu+-+Banika
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Sending notification to XBMC via URL: http://cns-workstation:80/xbmcCmds/xbmcHttp?command=ExecBuiltIn&parameter=Notification(Download+Finished%2CThe+Pacific+-+1x04+-+Gloucester+-+Pavuvu+-+Banika) username: xbmc password: xxxxxxxxxx
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Adding Password to XBMC url
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Sending notification to XBMC via URL: http://cns-mediacenter:80/xbmcCmds/xbmcHttp?command=ExecBuiltIn&parameter=Notification(Download+Finished%2CThe+Pacific+-+1x04+-+Gloucester+-+Pavuvu+-+Banika) username: xbmc password: xxxxxxxxxx
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Adding Password to XBMC url
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Seasonfolders were 1 which gave Season 1
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: The ultimate destination for E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv is o:\tv shows\The Pacific\Season 1\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.mkv
Apr-06 12:41:43 DEBUG    CP Server Thread-8 :: Moving from E:\Downloads\~TV\Process\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv to o:\tv shows\The Pacific\Season 1
Apr-06 12:42:24 DEBUG    CP Server Thread-8 :: File was moved successfully
Apr-06 12:42:24 DEBUG    CP Server Thread-8 :: Renaming the file o:\tv shows\The Pacific\Season 1\The.Pacific.s01e04.Pt.IV.REPACK.720p.HDTV.x264-IMMERSE.mkv to o:\tv shows\The Pacific\Season 1\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.mkv
Apr-06 12:42:24 DEBUG    CP Server Thread-8 :: 85539: Saving episode details to database
Apr-06 12:42:24 DEBUG    CP Server Thread-8 :: STATUS IS 4
Apr-06 12:42:24 DEBUG    CP Server Thread-8 :: sickbeard.db: UPDATE tv_episodes SET status = ?, tvdbid = ?, airdate = ?, location = ?, description = ?, hasnfo = ?, hastbn = ?, name = ? WHERE season = ? AND showid = ? AND episode = ? with args [4, u'446091', 733866, u'o:\\tv shows\\The Pacific\\Season 1\\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.mkv', u'Finally enlisted as a Marine, Sledge trains for combat at Camp Elliott. The 1st Marine Division lands at Cape Gloucester on the Japanese-held island of New Britain. As Leckie and the other Marines battle the Japanese, they quickly realize that the more ominous enemy is the smothering jungle itself. Having survived Gloucester and stationed on the godforsaken island of Pavuvu, Leckie begins displaying the physical and mental effects of combat and is sent to a naval hospital on nearby Banika for psychiatric observation.', False, False, u'Gloucester - Pavuvu - Banika', 1, 85539, 4]
Apr-06 12:42:24 DEBUG    CP Server Thread-8 :: Creating metadata for myself (1x4)
Apr-06 12:42:24 INFO     CP Server Thread-8 :: Writing nfo to o:\tv shows\The Pacific\Season 1\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.nfo
Apr-06 12:42:24 INFO     CP Server Thread-8 :: Writing thumb to o:\tv shows\The Pacific\Season 1\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.tbn
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: 85539: Saving episode details to database
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: STATUS IS 4
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: sickbeard.db: UPDATE tv_episodes SET status = ?, tvdbid = ?, airdate = ?, location = ?, description = ?, hasnfo = ?, hastbn = ?, name = ? WHERE season = ? AND showid = ? AND episode = ? with args [4, u'446091', 733866, u'o:\\tv shows\\The Pacific\\Season 1\\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.mkv', u'Finally enlisted as a Marine, Sledge trains for combat at Camp Elliott. The 1st Marine Division lands at Cape Gloucester on the Japanese-held island of New Britain. As Leckie and the other Marines battle the Japanese, they quickly realize that the more ominous enemy is the smothering jungle itself. Having survived Gloucester and stationed on the godforsaken island of Pavuvu, Leckie begins displaying the physical and mental effects of combat and is sent to a naval hospital on nearby Banika for psychiatric observation.', True, True, u'Gloucester - Pavuvu - Banika', 1, 85539, 4]
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: 85539: Saving episode details to database
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: STATUS IS 4
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: sickbeard.db: UPDATE tv_episodes SET status = ?, tvdbid = ?, airdate = ?, location = ?, description = ?, hasnfo = ?, hastbn = ?, name = ? WHERE season = ? AND showid = ? AND episode = ? with args [4, u'446091', 733866, u'o:\\tv shows\\The Pacific\\Season 1\\The Pacific - 1x04 - Gloucester - Pavuvu - Banika.mkv', u'Finally enlisted as a Marine, Sledge trains for combat at Camp Elliott. The 1st Marine Division lands at Cape Gloucester on the Japanese-held island of New Britain. As Leckie and the other Marines battle the Japanese, they quickly realize that the more ominous enemy is the smothering jungle itself. Having survived Gloucester and stationed on the godforsaken island of Pavuvu, Leckie begins displaying the physical and mental effects of combat and is sent to a naval hospital on nearby Banika for psychiatric observation.', True, True, u'Gloucester - Pavuvu - Banika', 1, 85539, 4]
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: Updating library in XBMC
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: Adding Password to XBMC url
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: Adding Password to XBMC url
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: Post processing finished successfully
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: sickbeard.db: SELECT COUNT(*) FROM tv_episodes WHERE season != 0 AND episode != 0 AND status=4
Apr-06 12:42:25 DEBUG    CP Server Thread-8 :: sickbeard.db: SELECT COUNT(*) FROM tv_episodes WHERE season != 0 AND episode != 0 AND airdate <= 733868



Snatched status - emanon - 2010-04-06 19:10

First off, thanks for a great piece of software! I love it.

One question though:

When an episode is downloaded and put in my Blackhole-folder status is changed to Snatched. This i get. But it stays tagged as Snatched forever.
Shouldn't a refresh of the show set the episode-status to Downloaded?
Am i missing something?


To those affected by NZBMatrix bad search results - Pr.Sinister - 2010-04-06 19:15

If the NZBMatrix bad search results made Sick Beard download the wrong
episodes, you can reset them so they are downloaded tonight by doing the
following :

Go to your Sick Beard history and find all episodes snatched but not downloaded

Go to each episode that was wrongly Snatched and set them to Missed.

Shutdown Sick Beard and restart it (Make sure you have the latest version with
the NZBMatrix 60 second sleep)

Your episodes will now be back to the Unaired state.

Here's a list of my shows that were affected :

90210 - 2x17
Justified - 1x04
Lost - 6x11
Parenthood (2009) - 1x06
Southland - 2x06


- midgetspy - 2010-04-06 19:35

emanon: Yes. If you are using Sick Beard post processing then the episode should go to Downloaded as soon as it's done. If not then the next time the show gets updated/refreshed the status should change. If that's not the case please send a log of a refresh and give me the name of the file and the folder structure it's in and I'll take a look.

Sinister: Fixed that verbosity problem, was a missed case.


- kri kri - 2010-04-06 21:53

Can someone re-post how to pull Git with Windows? I am running a Windows Home Server box if that matters.


- midgetspy - 2010-04-06 22:55

Install msysgit, install TortoiseGit, clone http://github.com/midgetspy/Sick-Beard.git.

Or apparently GitHub now allows read-only access to the repos so if you have TortoiseSVN you could checkout http://svn.github.com/midgetspy/Sick-Beard.git instead.


More Post-Processing Woes - Pr.Sinister - 2010-04-07 04:37

3 Things :

1)
Code:
except ConfigParser.NoSectionError, ConfigParser.NoOptionError:
Doesn't seem to have fixed things. Changed it to
Code:
except ConfigParser.NoOptionError:
That worked.

2) The source folder doesn't get deleted at the end of post-processing.
This may be because it doesn't get the error code it wants so i will
have to try again once you fix #3

3) Post-Processing a folder containing 9 episodes of a show where those epsiodes
already existed in lower quality, the post-process replaced the first 6 files but
not the last 3. They were copied to the Season folder but not renamed since it
didn't delete the ones that were already there.

Log : http://pastebin.com/ZBwtftCA


One More for the road! - Pr.Sinister - 2010-04-07 04:45

I have this file in my FlashForward folder :

FlashForward - 1x14 - Better Angels.mkv

It is 1.09 GB

I Post-Processed this file :

FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv

It is 1.32 GB

Manual Post-Processing should replace the file but this is what i get :

Code:
Postprocessing results
Processing folder E:\Downloads\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.H264.RANDi-SURFER
Auto processing file: E:\Downloads\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.H264.RANDi-SURFER\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv
Processing file E:\Downloads\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.H264.RANDi-SURFER\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv (with folder name None and NZB name None)
Attempting to parse name E:\Downloads\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.H264.RANDi-SURFER\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv
Found the show in our list, continuing
TVDB thinks the file is FlashForward1x14
Seasonfolders were 1 which gave Season 1
The ultimate destination for E:\Downloads\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.H264.RANDi-SURFER\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv is O:\TV Shows\FlashForward\Season 1\FlashForward - 1x14 - Better Angels.mkv
Moving from E:\Downloads\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.H264.RANDi-SURFER\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv to O:\TV Shows\FlashForward\Season 1
File was moved successfully
Failed renaming O:\TV Shows\FlashForward\Season 1\FlashForward.S01E14.Better.Angels.720p.WEB-DL.DD5.1.h.264-RANDi.mkv to O:\TV Shows\FlashForward\Season 1\FlashForward - 1x14 - Better Angels.mkv: [Error 183] Cannot create a file when that file already exists



No Air Date on Ended Shows - Pr.Sinister - 2010-04-07 05:52

Would it be possible to have Sick Beard not care about Air Dates if the show
is Ended?

I have a bunch of children TV Shows from when i was a kid and they have
ended since 1978! I do not want to even attempt to go through adding fictitious
air dates for all those episodes.

I know i don't HAVE to put them in Sick Beard since there is no need to download
anymore but i like having everything in Sick Beard for easy reference.

-Pr.


- gbdesai - 2010-04-07 06:36

midgetspy Wrote:OK the web_root problem is fixed, I will have to pick through the rest of the thread later to see if there are bugs here or if it's all NZBMatrix's fault.

I've been using the Alpha2 branch (because I love new features and potential instability Smile) Anyway I just did a GIT PULL and now have the web_root problem. Are the fixes only being done in Master or should they be propagating to Alpha2. And what is the actual change so I can make it manually if needed?

Is it as simple as adding "web_root=" to the auto process cfg file?

Thanks a million.

UPDATE: The last bit about adding "web_root=" worked thanks Pr.Sinister, but I'm still interested in the process of pulling updates (especially bug fixes) into newer alpha branches when fixes are made in the master...


- midgetspy - 2010-04-07 07:17

OK I pushed a bunch more post processing fixes so let me know if that fixes your problems Sinister.

gbdesai: alpha2 is being kept roughly in sync with master but not commit-per-commit - I'll just merge it every few days. Yes, adding web_root="" should fix it, or you could also do a pull of the master branch over top of your alpha2 branch to get the master's fixes.

Sinister: air dates are currently ingrained into the data model inside Sick Beard. Some fundamental changes are being worked on that'll hopefully come in alpha2 and will make the reliance on airdate much easier to remove, but for now it's gonna stay.


- Pr.Sinister - 2010-04-07 07:22

gbdesai Wrote:UPDATE: The last bit about adding "web_root=" worked thanks Pr.Sinister, but I'm still interested in the process of pulling updates (especially bug fixes) into newer alpha branches when fixes are made in the master...

midgetspy just applied a working fix in the main branch. So you can wait until
he merges it, stick to the web_root= workaround or you can download the
alpha 2 and fix it yourself... it is very simple.

Just edit autoProcessTV.py and change

this :
Code:
except ConfigParser.NoSectionError, ConfigParser.NoOptionError:

to this :
Code:
except ConfigParser.NoOptionError:

If you are using SABnzbd, make sure you copy autoProcessTV.py to the scripts
folder you have configured in there IF it's not pointing to the one in the
$sickbeard_root/autoProcessTV

-Pr.


- xexe - 2010-04-07 09:44

midgetspy Wrote:Well the only reason I use SQLite is because it requires no dependencies since it's built into Python. The multithreading (or lack of) in sqlite is fairly annoying and it has significantly less features than most DBs. It's just that it is extremely inconvenient for users to have to install and configure a DBMS just to use a TV show manager and I will never require it.

With that in mind, I will not be implementing any features that I can't also support in sqlite, in which case I'm not sure what the advantage would be? Unless somebody wants to start implementing MySQL-only features or addons (I'm not going to do that myself) the only difference would be the tool you use if you want to examine the DB yourself, hehe. I actually don't even have a local MySQL server at the moment, so unless somebody else wants to implement this themselves it's not gonna happen, sorry.

midgetspy understood. If you could add the optional ability to connect to a mysql database I will provide a a blank sickbeard compatible mysql dbase.

It goes without saying that sqlite should always be the default but for more advanced users I believe mysql would be of interest.

If you need the .sql file in advance to help you do the connector let me know.


- eztiger - 2010-04-07 13:22

I'm seeing the following error whenever attempting to post process (manually or automatically) an episode :

Code:
Traceback (most recent call last):
  File "/mnt/cache/.permanent/midgetspy-Sick-Beard-40f9b32/cherrypy/_cprequest.py", line 660, in respond
    response.body = self.handler()
  File "/mnt/cache/.permanent/midgetspy-Sick-Beard-40f9b32/cherrypy/lib/encoding.py", line 193, in __call__
    self.body = self.oldhandler(*args, **kwargs)
  File "/mnt/cache/.permanent/midgetspy-Sick-Beard-40f9b32/cherrypy/_cpdispatch.py", line 25, in __call__
    return self.callable(*self.args, **self.kwargs)
  File "/mnt/cache/.permanent/midgetspy-Sick-Beard-40f9b32/sickbeard/webserve.py", line 561, in processEpisode
    result = processTV.processDir(dir, nzbName)
  File "/mnt/cache/.permanent/midgetspy-Sick-Beard-40f9b32/sickbeard/processTV.py", line 188, in processDir
    result = processFile(curFile)
  File "/mnt/cache/.permanent/midgetspy-Sick-Beard-40f9b32/sickbeard/processTV.py", line 408, in processFile
    returnStr += logger.log("Existing result: "+str(existingResult), logger.DEBUG)
TypeError: coercing to Unicode: need string or buffer, NoneType found

Any ideas? Source checked out a few hours ago..