Добавление return True не решит проблему , поскольку при выполнении туда просто "не дойдет"
почему же? Если не вернуть ничего, то
отошлет ошибкуюif not self.Playlistparser(): connection.send_error()
в allfon есть возврат после исключений:
Python:
self.playlisttime = gevent.time.time()
except requests.exceptions.RequestException:
logging.error("[%s]: can't download %s playlist!" % (self.__class__.__name__, config.url))
return False
except: logging.error(traceback.format_exc()); return False
return True
def handle(self, connection):
# 30 minutes cache
if not self.playlist or (gevent.time.time() - self.playlisttime > 30 * 60):
if not self.Playlistparser(): connection.send_error()
а вот torrent-telik, frytv нет.
Python:
self.playlisttime = gevent.time.time()
except requests.exceptions.RequestException:
logging.error("[%s]: can't download %s playlist!" % (self.__class__.__name__, config.url))
return False
except: logging.error(traceback.format_exc()); return False
def handle(self, connection):
# 30 minutes cache
if not self.playlist or (gevent.time.time() - self.playlisttime > 30 * 60):
if not self.Playlistparser(): connection.send_error()