本文整理汇总了Python中sickbeard.tv.TVShow.next_episode方法的典型用法代码示例。如果您正苦于以下问题:Python TVShow.next_episode方法的具体用法?Python TVShow.next_episode怎么用?Python TVShow.next_episode使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sickbeard.tv.TVShow
的用法示例。
在下文中一共展示了TVShow.next_episode方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: load_shows_from_db
# 需要导入模块: from sickbeard.tv import TVShow [as 别名]
# 或者: from sickbeard.tv.TVShow import next_episode [as 别名]
def load_shows_from_db():
"""
Populates the showList with shows from the database
"""
logger.log('Loading initial show list', logger.DEBUG)
main_db_con = db.DBConnection()
sql_results = main_db_con.select('SELECT indexer, indexer_id, location FROM tv_shows;')
sickbeard.showList = []
for sql_show in sql_results:
try:
cur_show = TVShow(sql_show[b'indexer'], sql_show[b'indexer_id'])
cur_show.next_episode()
sickbeard.showList.append(cur_show)
except Exception as error: # pylint: disable=broad-except
logger.log('There was an error creating the show in {}: Error {}'.format
(sql_show[b'location'], error), logger.ERROR)
logger.log(traceback.format_exc(), logger.DEBUG)