From fd433d643256368c9c14109186c9be0e3a87ece9 Mon Sep 17 00:00:00 2001 From: BasioMeusPuga Date: Mon, 26 Aug 2019 17:42:56 -0700 Subject: [PATCH] Tag generation stopgap --- lector/library.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lector/library.py b/lector/library.py index 4cb341b..aa73bb8 100644 --- a/lector/library.py +++ b/lector/library.py @@ -61,9 +61,13 @@ class Library: books = [] current_qdatetime = QtCore.QDateTime().currentDateTime() for i in parsed_books.items(): - _tags = i[1]['tags'] - if _tags: - _tags = ', '.join([j for j in _tags if j]) + try: + _tags = i[1]['tags'] + if _tags: + _tags = ', '.join([j for j in _tags if j]) + except: # Continuing seems more important than being correct + _tags = [] + logger.warning('Tag generation error for: ' + i[1]['path']) books.append([ i[1]['title'], i[1]['author'], i[1]['year'], current_qdatetime,