From 64d48f778c170572a11ed384d54bed975b984e0e Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 2 Mar 2014 08:56:42 +0530 Subject: [PATCH] Edit Book: Fix import HTML file as new book not working on OS X --- src/calibre/ebooks/oeb/polish/import_book.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/calibre/ebooks/oeb/polish/import_book.py b/src/calibre/ebooks/oeb/polish/import_book.py index 5c014b89ad..0275f70e8b 100644 --- a/src/calibre/ebooks/oeb/polish/import_book.py +++ b/src/calibre/ebooks/oeb/polish/import_book.py @@ -34,6 +34,7 @@ def import_book_as_epub(srcpath, destpath, log=default_log): if not destpath.lower().endswith('.epub'): raise ValueError('Can only import books into the EPUB format, not %s' % (os.path.basename(destpath))) with TemporaryDirectory('eei') as tdir: + tdir = os.path.abspath(os.path.realpath(tdir)) # Needed to handle the multiple levels of symlinks for /tmp on OS X plumber = Plumber(srcpath, tdir, log) plumber.setup_options() if srcpath.lower().endswith('.opf'):