Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 08-11-2016, 05:06 PM   #1
OmarKN
Junior Member
OmarKN began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2016
Device: iPad Air 2
Cannot ADD ebook (error mess.)

Hi and good day,

Just starting with calibre on OSX 10.11.6 with iBooks (and iPad Air 2).

Unsuccessful to ADD an ebook (which I find in OSX Library - see screendump.)

- neither .epub nor .ibooks, same error message.

Please hv a look here:

https://www.abc.se/home/m9783/ir/x/_...ibre-error.jpg


Why I want to use calibre.app?
For easier copying text for quoting.

/
with best regards,
Omar KN
Stockholm, Sweden
OmarKN is offline   Reply With Quote
Old 08-11-2016, 05:14 PM   #2
HarryT
eBook Enthusiast
HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.HarryT ought to be getting tired of karma fortunes by now.
 
HarryT's Avatar
 
Posts: 85,544
Karma: 93383043
Join Date: Nov 2006
Location: UK
Device: Kindle Oasis 2, iPad Pro 10.5", iPhone 6
If you have a question about Calibre, please post it in the Calibre forum, to where I'm now moving this.

Thank you.
HarryT is offline   Reply With Quote
Old 08-11-2016, 05:48 PM   #3
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
The problem is that iBooks does something extraordinarily stupid when importing ebooks.
It unpacks the ebook into a directory -- which it then names with a *.epub extension.

...

You can use the AppleScript wrapper here to turn those back into real ebooks: https://www.mobileread.com/forums/showthread.php?t=55681
Afterwards you will be able to import them into calibre.

Note: The *.ibooks folders use Apple's custom format, so I have no idea what challenges you may face in turning them into a format that other applications (like calibre) can understand.

...
...

tl;dr
iBooks is a really bad piece of software.

Last edited by eschwartz; 08-11-2016 at 05:51 PM.
eschwartz is offline   Reply With Quote
Old 08-15-2016, 09:13 AM   #4
OmarKN
Junior Member
OmarKN began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2016
Device: iPad Air 2
Thanks for the script (using vs.3 for iBooks)

It succeeded to unpack an iBook (through the script) and could view it in Calibre.app!!

So far so good!

But every further trial for other iBooks (some have the epub, some the ibooks extension) give me the same error message as always:

—————————————..————————————-

calibre, version 2.64.0
WARNING: Errors while adding: There were problems adding some files, click "Show details" for more information


----------------------------------------------------------------------
Failed to add the file /Users/okn/Library/Containers/com.apple.BKAgentService/Data/Documents/iBooks/Books/522063581.epub to the book: /Users/okn/Library/Containers/com.apple.BKAgentService/Data/Documents/iBooks/Books/522063581
With error:
Traceback (most recent call last):
File "site-packages/calibre/gui2/add.py", line 408, in add_formats
File "site-packages/calibre/db/cache.py", line 1374, in add_format
File "site-packages/calibre/startup.py", line 118, in local_open
IOError: [Errno 21] Is a directory: u'/Users/okn/Library/Containers/com.apple.BKAgentService/Data/Documents/iBooks/Books/522063581.epub'

—————————————..————————————-

Even after restart, any idea what going on here?

/
with best regards,
Omar K N
Stockholm, Sweden
(on OSX 10.11.6)
OmarKN is offline   Reply With Quote
Old 08-15-2016, 09:22 AM   #5
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,984
Karma: 307500000
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Quote:
Originally Posted by OmarKN View Post
Thanks for the script (using vs.3 for iBooks)

It succeeded to unpack an iBook (through the script) and could view it in Calibre.app!!

So far so good!

But every further trial for other iBooks (some have the epub, some the ibooks extension) give me the same error message as always:
"IOError: [Errno 21] Is a directory: u'/Users/okn/Library/Containers/com.apple.BKAgentService/Data/Documents/iBooks/Books/522063581.epub'"

The problem is that iBooks store ePubs unzipped in a folder (directory), not as an actual ePub file.

Trying to add a folder to calibre won't work. You'll need to use my AppleScript to convert the folders to actual epub files before importing.
pdurrant is offline   Reply With Quote
Old 08-15-2016, 02:13 PM   #6
OmarKN
Junior Member
OmarKN began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2016
Device: iPad Air 2
Smile

Quote:
Originally Posted by pdurrant View Post
"…You'll need to use my AppleScript to convert the folders to actual epub files before importing.
Alright, what I did now is I copied an iBooks (zipped file, so a folder) out of Library into Documents (because the script asked me if I want to replace the iBooks file, as it already existed.)

Then I tried to unpack it and got the ff error:

Problem adding mimetype to ePub "522063581.epub":

sh: line 0: cd: /Users/okn/Documents/522063581.epub/: No such file or directory

And really this file is gone!!

- - - -

If I unzip the iBooks file in the Library/Containers …

more / less the same error:

Problem adding mimetype to ePub "522063581.epub":

sh: line 0: cd: /Users/okn/Library/Containers/com.apple.BKAgentService/Data/Documents/iBooks/Books/522063581.epub/: No such file or directory

The file is actually in the Trash:

522063581 20.08.14.epub
also with:
522063581.epub

So here I'm stuck, if you know a way out, very good.

But then if the iBooks file is DRM-locked the whole exercise would be useless anyway.

/
with best regards,
Omar K N
Stockholm, Sweden
OmarKN is offline   Reply With Quote
Old 08-15-2016, 02:24 PM   #7
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,984
Karma: 307500000
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Quote:
Originally Posted by OmarKN View Post
Then I tried to unpack it and got the ff error:
Perhaps this is just a translation/terminology problem. Or perhaps it's a basic misunderstanding.

The iBooks ".epubs" are NOT compressed files. They are folders. They may look like files to you in the Finder, but they are really folders. You can't unpack them. They are already unpacked.

But as you say, they also probably have DRM. I beleive there are some commercial applications that claim to be able to remove the DRM, but I've avoided the problem by never buying from the iBook Store.
pdurrant is offline   Reply With Quote
Old 08-19-2016, 03:21 AM   #8
OmarKN
Junior Member
OmarKN began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2016
Device: iPad Air 2
Thank you pdurrant, - it's not easy.

/
with best regards,
Omar K N
Stockholm, Sweden
OmarKN is offline   Reply With Quote
Reply

Tags
add a book, error adding books, file access


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Add Book error glbell Calibre 3 03-07-2016 04:53 PM
Error: Could not add icecoldx Calibre 4 06-21-2015 06:45 PM
ERROR:Add to library. What im i doing wrong? MisMee23 Devices 5 10-07-2011 10:25 PM
Error Message - can't add books davidwat Calibre 4 03-01-2009 11:25 PM
Waterstones eBook store - what a mess jaffab News 8 09-09-2008 08:53 AM


All times are GMT -4. The time now is 01:11 PM.


MobileRead.com is a privately owned, operated and funded community.