From de9b3891008b64fc834465628e9963d1de41ad9f Mon Sep 17 00:00:00 2001 From: Zsolt Botykai Date: Tue, 11 Jun 2024 20:28:48 +0200 Subject: [PATCH] linting corrections --- o2e.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/o2e.py b/o2e.py index 97f36a1..4ba132f 100755 --- a/o2e.py +++ b/o2e.py @@ -30,7 +30,7 @@ def main(): """ This is the business part. """ - token = open('API.key', 'r').read().strip() + token = open('API.key', 'r', encoding='utf-8').read().strip() logger.debug("API key found") book = mkepub.Book(title='OmniVore saved articles') @@ -81,10 +81,10 @@ def main(): oc.archive_article(aid) - with open('cover.jpg', 'rb') as file: + with open('cover.jpg', 'rb', encoding='utf-8') as file: book.set_cover(file.read()) - with open('base.css') as file: + with open('base.css', encoding='utf-8') as file: book.set_stylesheet(file.read())