diff --git a/src/calibre/ebooks/oeb/polish/container.py b/src/calibre/ebooks/oeb/polish/container.py index 19ea0eb14c..f6b5841ca5 100644 --- a/src/calibre/ebooks/oeb/polish/container.py +++ b/src/calibre/ebooks/oeb/polish/container.py @@ -10,7 +10,6 @@ __docformat__ = 'restructuredtext en' import os, logging, sys, hashlib, uuid, re, shutil from collections import defaultdict from io import BytesIO -from urllib import unquote as urlunquote, quote as urlquote from urlparse import urlparse from future_builtins import zip @@ -29,7 +28,7 @@ from calibre.ebooks.mobi.reader.headers import MetadataHeader from calibre.ebooks.mobi.tweak import set_cover from calibre.ebooks.oeb.base import ( serialize, OEB_DOCS, _css_logger, OEB_STYLES, OPF2_NS, DC11_NS, OPF, - rewrite_links, iterlinks, itercsslinks) + rewrite_links, iterlinks, itercsslinks, urlquote, urlunquote) from calibre.ebooks.oeb.polish.errors import InvalidBook, DRMError from calibre.ebooks.oeb.parse_utils import NotHTML, parse_html, RECOVER_PARSER from calibre.ptempfile import PersistentTemporaryDirectory, PersistentTemporaryFile diff --git a/src/calibre/ebooks/oeb/polish/tests/container.py b/src/calibre/ebooks/oeb/polish/tests/container.py index 4d854c32f7..0ca95730d1 100644 --- a/src/calibre/ebooks/oeb/polish/tests/container.py +++ b/src/calibre/ebooks/oeb/polish/tests/container.py @@ -149,7 +149,7 @@ class ContainerTests(BaseTest): # Test renaming of text files c = new_container() - rename_files(c, {'index_split_000.html':'text/page one.html', 'index_split_001.html':'text/page two.html'}) + rename_files(c, {'index_split_000.html':'text/page one fällen.html', 'index_split_001.html':'text/page two fällen.html'}) self.check_links(c) # self.run_external_tools(c, gvim=True)