MobileRead Forums

MobileRead Forums (https://www.mobileread.com/forums/index.php)
-   Calibre (https://www.mobileread.com/forums/forumdisplay.php?f=166)
-   -   Error message when deleting books (https://www.mobileread.com/forums/showthread.php?t=341224)

BookJunkieLI 08-15-2021 11:18 AM

Error message when deleting books
 
I've recently been working on combining all of the various libraries I've created over the years and getting rid of duplicates. Of which there are a lot.

In the last couple weeks I've started running into the following error message when deleting files.

Code:

calibre, version 5.23.0
ERROR: Failed to delete: Failed to delete some books, click the "Show details" button for details.

==> Man and Brother
Traceback (most recent call last):
  File "calibre\db\backend.py", line 949, in executemany
apsw.IOError: IOError: disk I/O error

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "calibre\gui2\actions\delete.py", line 66, in delete_one
  File "calibre\db\legacy.py", line 459, in delete_book
  File "calibre\db\cache.py", line 76, in call_func_with_lock
  File "calibre\db\cache.py", line 1785, in remove_books
  File "calibre\db\tables.py", line 272, in remove_books
  File "calibre\db\backend.py", line 949, in executemany
apsw.SQLError: SQLError: no such savepoint: _apsw-0

I've also noticed the same message periodically when using the FanFicFare plugin but I don't think it's a plugin issue.
Spoiler:
calibre, version 5.23.0
ERROR: Error Updating Metadata: <p>An error has occurred while FanFicFare was updating calibre's metadata for <a href='https://archiveofourown.org/works/6859174'>Born This Way</a>.</p>The ebook has been updated, but the metadata has not.

Traceback (most recent call last):
File "calibre\db\backend.py", line 949, in executemany
apsw.IOError: IOError: disk I/O error

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "calibre_plugins.fanficfare_plugin.fff_plugin" , line 2185, in set_custom
File "calibre\db\legacy.py", line 769, in set_custom
File "calibre\db\cache.py", line 1233, in set_field
File "calibre\db\cache.py", line 1159, in mark_as_dirty
File "calibre\db\cache.py", line 1152, in update_last_modified
File "calibre\db\write.py", line 543, in set_books
File "calibre\db\write.py", line 197, in one_one_in_books
File "calibre\db\backend.py", line 949, in executemany
apsw.SQLError: SQLError: no such savepoint: _apsw-0

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "calibre_plugins.fanficfare_plugin.fff_plugin" , line 1784, in update_books_loop
File "calibre_plugins.fanficfare_plugin.fff_plugin" , line 2300, in update_metadata
File "calibre_plugins.fanficfare_plugin.fff_plugin" , line 2194, in set_custom
File "calibre_plugins.fanficfare_plugin.fff_plugin" , line 2183, in raise_exception
Exception: Trying to set entry (numWords) value(2691) to column (#words) failed (SQLError: no such savepoint: _apsw-0)


Since it is a disk I/O error I immediately suspected hard drive issues but two Disk Checks have come up completely clean and I haven't noticed issues in any of the other programs I use. I also did a Check Library that came back with no significant issues.

My machine specs are:
Windows 10 Pro 64-bit
8gb RAM
Calibre 5.23 (64-bit)
595GB free on a 1TB hard drive.

Any help would be greatly appreciated.

kovidgoyal 08-15-2021 11:43 AM

Its an I/O error which means reading/writing to the disk is failing. If itsnt hardware failure then the other thing that can cause it is programs that intefere. You can try running in sfe mode and/or excluding the library directories from all file sync/antivirus and similar programs.

BookJunkieLI 08-15-2021 09:46 PM

Thanks, Kovid.

I restarted in Safe Mode and I suspect the issue is that this is my old work computer that is no longer connected to the network. Once in Safe Mode I couldn't access My Documents because it's a redirected folder that I'm guessing technically lived on the server but was mirrored to the workstation. I'll have to try dropping everything onto an external drive and see if that solves the problem.

ownedbycats 08-16-2021 03:28 AM

Calibre doesn't handle NAS drives very well, and I suspect network drives are the same.

BookJunkieLI 08-16-2021 11:58 AM

Quote:

Originally Posted by ownedbycats (Post 4146778)
Calibre doesn't handle NAS drives very well, and I suspect network drives are the same.

Possibly but I never had any issues when it was connected to the network. Only now that it's been disconnected.

BookJunkieLI 08-16-2021 12:02 PM

I moved the libraries over to an external drive and now I'm getting a new SQL error message and it seems like it won't delete books at all. I'm using Calibre Portable directly on the external drive. I've pretty much always used Calibre Portable so that I could just copy everything to a drive and not lose my settings.

Code:

calibre, version 3.47.1
ERROR: Unhandled exception: <b>SQLError</b>:SQLError: no such module: fts5

calibre 3.47.1 Portable embedded-python: True is64bit: False
Windows-10-10.0.16299-SP0 Windows ('32bit', 'WindowsPE')
32bit process running on 64bit windows
('Windows', '10', '10.0.16299')
Python 2.7.15+
Windows: ('10', '10.0.16299', 'SP0', u'Multiprocessor Free')
Interface language: None
Successfully initialized third party plugins: Favourites Menu (1, 0, 4) && Fantastic Fiction Adults (1, 0, 4) && FictionDB (1, 0, 10) && Find Duplicates (1, 6, 3) && EpubMerge (2, 6, 0) && Quality Check (1, 9, 11) && FanFicFare (3, 13, 0) && SmartEject (2, 2, 0) && Count Pages (1, 9, 0) && Barnes & Noble (1, 2, 15) && View Manager (1, 4, 3) && CalibreSpy (1, 0, 75) && EpubSplit (2, 8, 0) && Manage Series (1, 2, 8) && Ex Libris (1, 0, 19) && Job Spy (1, 0, 169) && Generate Cover (1, 5, 21) && Kindle Collections (1, 7, 24) && Modify ePub (1, 4, 0) && Library Splitter (1, 0, 1) && Reading List (1, 6, 6) && Goodreads (1, 4, 0) && Consolidate All Library Metadata (2, 0, 33) && Fantastic Fiction (1, 2, 0)
Traceback (most recent call last):
  File "site-packages\calibre\gui2\actions\copy_to_library.py", line 393, in choose_library
  File "site-packages\calibre\gui2\actions\copy_to_library.py", line 446, in copy_to_library
  File "site-packages\calibre\gui2\actions\copy_to_library.py", line 512, in do_copy
  File "site-packages\calibre\gui2\library\models.py", line 415, in delete_books_by_id
  File "site-packages\calibre\db\cache.py", line 62, in call_func_with_lock
  File "site-packages\calibre\db\cache.py", line 1647, in remove_books
  File "site-packages\calibre\db\backend.py", line 1676, in remove_books
  File "site-packages\calibre\db\backend.py", line 886, in executemany
  File "c:\t\t\apsw-zu_bhl\apsw-3.27.2-r1\src\cursor.c", line 1136, in APSWCursor_executemany.sqlite3_prepare
  File "c:\t\t\apsw-zu_bhl\apsw-3.27.2-r1\src\statementcache.c", line 386, in sqlite3_prepare
SQLError: SQLError: no such module: fts5


kovidgoyal 08-16-2021 12:07 PM

You are running too old a version of calibre, update to at least 4.23

BookJunkieLI 08-16-2021 12:33 PM

:smack:
And this is why I'm trying to get everything consolidated properly.

That fixed it.

Thank you, Kovid.


All times are GMT -4. The time now is 05:35 PM.

Powered by: vBulletin
Copyright ©2000 - 3.8.5, Jelsoft Enterprises Ltd.
MobileRead.com is a privately owned, operated and funded community.