From: Radek Czajka <rczajka@rczajka.pl>
Date: Fri, 1 Mar 2019 10:25:31 +0000 (+0100)
Subject: Fix
X-Git-Tag: 1.7.1
X-Git-Url: https://git.mdrn.pl/librarian.git/commitdiff_plain/8fefa7358bf9f799c8a7d700b58a00362b26419e?ds=inline

Fix
---

diff --git a/CHANGELOG.md b/CHANGELOG.md
index dbc3209..8a18029 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,13 @@
 
 This document records all notable changes to Librarian.
 
+
+## 1.7.1 (2019-03-01)
+
+### Fixed
+- Bug in cover generation.
+
+
 ## 1.7 (2019-02-27)
 
 ### Added
diff --git a/librarian/cover.py b/librarian/cover.py
index 09c8071..c32751d 100644
--- a/librarian/cover.py
+++ b/librarian/cover.py
@@ -305,7 +305,7 @@ class WLCover(Cover):
             bg_src = None
             if bg_src is None:
                 bg_src = URLOpener().open(url)
-            self.background_img = StringIO(bg_src.read())
+            self.background_img = BytesIO(bg_src.read())
             bg_src.close()
 
     def pretty_author(self):
diff --git a/setup.py b/setup.py
index b391f0c..111e83b 100755
--- a/setup.py
+++ b/setup.py
@@ -21,7 +21,7 @@ def whole_tree(prefix, path):
 
 setup(
     name='librarian',
-    version='1.7',
+    version='1.7.1',
     description='Converter from WolneLektury.pl XML-based language to XHTML, TXT and other formats',
     author="Marek Stępniowski",
     author_email='marek@stepniowski.com',