diff --git a/recipes/nature.recipe b/recipes/nature.recipe index e7f50bdd70..d21b8e092d 100644 --- a/recipes/nature.recipe +++ b/recipes/nature.recipe @@ -51,7 +51,7 @@ class Nature(BasicNewsRecipe): 'img', attrs={'data-test': check_words('issue-cover-image')} )['src'] try: - self.cover_url = self.cover_url.replace("w200","w500") # enlarge cover size resolution + self.cover_url = self.cover_url.replace("w200","w500") # enlarge cover size resolution except: """ failed, img src might have changed, use default width 200 diff --git a/recipes/new_yorker.recipe b/recipes/new_yorker.recipe index 7197dd1c61..cd5d6057c9 100644 --- a/recipes/new_yorker.recipe +++ b/recipes/new_yorker.recipe @@ -82,9 +82,9 @@ class NewYorker(BasicNewsRecipe): cover_url_width_index = self.cover_url.find("w_") old_width = self.cover_url[cover_url_width_index:cover_url_width_index+5] self.cover_url = self.cover_url.replace(old_width, "w_560") - except Exception as e: + except Exception: self.log('Failed enlarging cover img, using the original one') - + self.log('Found cover:', self.cover_url) stories = defaultdict(list) last_section = 'Unknown' diff --git a/src/calibre/ebooks/rtf2xml/check_encoding.py b/src/calibre/ebooks/rtf2xml/check_encoding.py index 4f8a04ceda..c98a4cfce3 100644 --- a/src/calibre/ebooks/rtf2xml/check_encoding.py +++ b/src/calibre/ebooks/rtf2xml/check_encoding.py @@ -5,6 +5,7 @@ import sys from polyglot.builtins import unicode_type + class CheckEncoding: def __init__(self, bug_handler):