From 3605a4893367b8aa39ffb6b0043e95224eaace2c Mon Sep 17 00:00:00 2001 From: angelblue05 Date: Sun, 4 Oct 2015 06:40:39 -0500 Subject: [PATCH] Fix for tv show is not found on server When processing episodes, if the show failed to be added. --- resources/lib/LibrarySync.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/resources/lib/LibrarySync.py b/resources/lib/LibrarySync.py index 7a53caf4..26acab11 100644 --- a/resources/lib/LibrarySync.py +++ b/resources/lib/LibrarySync.py @@ -436,9 +436,13 @@ class LibrarySync(threading.Thread): allKodiEpisodeIds = list() allEmbyEpisodeIds = list() - #get the kodi parent id + # Get the kodi parent id cursor.execute("SELECT kodi_id FROM emby WHERE emby_id=?",(showId,)) - kodiShowId = cursor.fetchone()[0] + try: + kodiShowId = cursor.fetchone()[0] + except: + self.logMsg("Unable to find show itemId:%s" % showId, 1) + return allEmbyEpisodes = ReadEmbyDB().getEpisodes(showId) allKodiEpisodes = ReadKodiDB().getKodiEpisodes(connection, cursor, kodiShowId)