Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 08-09-2014, 12:31 PM   #1
goyta
Junior Member
goyta began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Aug 2014
Location: São Paulo, Brazil
Device: none
Error importing/editing metadata with files from Feedbooks - Calibre 1.48 Windows x64

I have recently downloaded four e-books from Feedbooks (actually only two, but one of them in three different formats), and Calibre 1.48 (Windows, x64) is having problems processing them. The problem seems to be unrelated to any specific format; it's happening with all of them (the books are in MOBI, ePub and PDF, and the same problem is happening with all of them).

First, when I add the book to the library, the Management module shows the message:

WARNING: Failed to read metadata originating from:

The detailed message is in the spoiler below:

Spoiler:

calibre, version 1.48.0
AVISO: Falhou na leitura dos metadados: Falhou na leitura dos metadados vindos de:

2029.mobi
Traceback (most recent call last):
File "site-packages\calibre\gui2\add.py", line 165, in start
File "site-packages\calibre\gui2\add.py", line 254, in add
File "site-packages\calibre\db\legacy.py", line 211, in create_book_entry
File "site-packages\calibre\db\cache.py", line 57, in call_func_with_lock
File "site-packages\calibre\db\cache.py", line 1474, in create_book_entry
File "site-packages\calibre\db\cache.py", line 1215, in set_metadata
File "site-packages\calibre\db\cache.py", line 1202, in set_field
File "site-packages\calibre\db\cache.py", line 1024, in set_field
File "site-packages\calibre\db\write.py", line 513, in set_books
File "site-packages\calibre\db\write.py", line 375, in many_many
File "site-packages\calibre\db\write.py", line 241, in get_db_id
File "site-packages\calibre\ebooks\metadata\__init__.py", line 67, in author_to_author_sort
UnicodeDecodeError: 'utf8' codec can't decode bytes in position 1-2: invalid continuation byte


In spite of the error, after that the book appears on the Management module's library list, but when I try to open it by double-clicking on the entry, the following message appears (also in Portuguese, I've translated it):

ERROR: Unable to view: [book title] has no available formats

(There is no further detailed message.)

I guess this must be because Management is not copying the e-book file to the library folder or creating the appropriate subfolders.

However, when I open the e-book file directly from Windows Explorer (Calibre is set as my default e-book reader), the Viewer module opens it normally and without any problems. The problem seems to be only in the Management module, which is why I have posted this thread on this sub-forum.

After importing the book, it also appears without the author on the library list in Calibre Management. (Oddly, when I sort the list by author name, the book appears between author letters D and E - the books are by William Olaf Stapledon.) When I try to edit the metadata to include the author, sometimes the author appears correctly in the "Author(s)" field, sometimes in the "Ordered author" field, sometimes in neither, randomly and for the same book. Then I try to edit the blank field, but as I type each single character, the following error message appears:

UnicodeDecodeError:'utf8' codec can't decode bytes in position 1-2: invalid continuation byte

(This message is not localized and appears in English.)

Detailed message:

Spoiler:

calibre, version 1.48.0
ERRO: Exceção sem tratamento: <b>UnicodeDecodeError</b>:'utf8' codec can't decode bytes in position 1-2: invalid continuation byte

calibre 1.48 [64bit] isfrozen: True is64bit: True
Windows-8-6.2.9200 Windows ('64bit', 'WindowsPE')
('Windows', '8', '6.2.9200')
Python 2.7.5
Windows: ('8', '6.2.9200', '', 'Multiprocessor Free')
Traceback (most recent call last):
File "site-packages\calibre\gui2\metadata\basic_widgets.py", line 373, in update_state_and_val
File "site-packages\calibre\ebooks\metadata\__init__.py", line 95, in authors_to_sort_string
File "site-packages\calibre\ebooks\metadata\__init__.py", line 67, in author_to_author_sort
UnicodeDecodeError: 'utf8' codec can't decode bytes in position 1-2: invalid continuation byte



Even if I patiently type each character and dismiss the message every time, I can't save the edit, because the message above appears again and the window doesn't close. I have to cancel and lose my changes. The same message also appears if I paste the full text or try to move the "Author(s)" field's contents to "Ordered author" by clicking on the arrow. I'm stuck.

I'm running Calibre on a powerful PC with a hexa-core processor, 16 GB RAM, tons of free disk space, no malware, running Windows 8.1 Update 1 x64.

Any hints to solve the problem? Thank you very much for your help.

Last edited by goyta; 08-09-2014 at 12:37 PM. Reason: Clarification
goyta is offline   Reply With Quote
Old 08-09-2014, 01:27 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,251
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Which book is it?
kovidgoyal is offline   Reply With Quote
Advert
Old 08-09-2014, 01:29 PM   #3
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,251
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Actually, looking at that error message, it looks like you entered some invalid data in Preferences->Tweaks. Go to Preferences->Tweaks and click Restore Defaults and then Apply.
kovidgoyal is offline   Reply With Quote
Old 08-09-2014, 01:39 PM   #4
goyta
Junior Member
goyta began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Aug 2014
Location: São Paulo, Brazil
Device: none
The books are Star Maker (.mobi) and Last and First Men (.mobi, .epub and .pdf), both by William Olaf Stapledon. I never changed anything in the Tweaks section of the settings, but I restored the defaults anyway, as you instructed. No effect, the same errors are still happening.
goyta is offline   Reply With Quote
Old 08-09-2014, 09:36 PM   #5
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,251
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Did you restart calibre after restoring defaults?

Adding the epub for star maker caused no errors for me.
kovidgoyal is offline   Reply With Quote
Advert
Old 08-10-2014, 05:52 AM   #6
goyta
Junior Member
goyta began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Aug 2014
Location: São Paulo, Brazil
Device: none
Problem solved with a reinstall

Yes, I did. The errors happened all the same. I forgot to mention one thing: when I tried to edit the metadata and the error occurred after each character I typed, this only happened after I typed the first name and pressed the spacebar. That is, I could type the first name. However, if I copied and pasted the full text, the error also happened. Very strange. This was already happening before the settings were reset, it didn't change.

However, your suggestion still gave me an idea that should have been obvious, but somehow it didn't occur to me before. I decided to try something more radical and it worked: I thoroughly uninstalled and then reinstalled Calibre. I even used Revo Uninstaller Pro for a complete uninstall (it removed some leftover Registry entries, but it still missed the \AppData folders, which I manually deleted). Then I reinstalled Calibre and left it with the default settings. It imported the e-books normally. So, my problem is solved. Apparently, something in the Calibre install had been corrupted and that was fixed when I reinstalled it afresh.

Thanks a lot for your help, and also thanks for Calibre, which has become one of my favorite and indispensable pieces of software. You do a great job with it!
goyta is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Error Messages after editing Metadata mogli@home Calibre 7 03-15-2013 01:28 AM
Startup Calibre-server on windows 7 x64 profesional roadrunnerm Calibre 0 10-19-2012 04:18 AM
Error importing mobi files Nomadin Calibre 27 02-19-2010 04:15 AM
Renaming LRF files, Editing Metadata? brandoniain LRF 9 06-18-2009 08:13 AM
Error when importing MobiPocket files. mbovenka Calibre 7 08-16-2008 10:07 AM


All times are GMT -4. The time now is 06:42 PM.


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