View Single Post
Old 10-06-2016, 04:38 AM   #743
Cex
Enthusiast
Cex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blueCex can differentiate black from dark navy blue
 
Posts: 29
Karma: 13132
Join Date: Jul 2015
Location: Spain
Device: Glo; Glo HD; PW2; Voyage
Quote:
Originally Posted by davidfor View Post
Kobo change the journal mode from "delete" to "wal". This is supported with SQLite 3.7 or later. Obok, the KoboTouch driver and all the other calibre plugins were using sqlite3 to access the database. On Windows, sqlite3 was built with a SQLite 3.6 library. When calibre tried to read the database, it gave an error because sqlite3 could not handle the WAL option. The error suggested the file was either encrypted or not a database. On the other platforms sqlite3, uses 3.7, so there were no problems.

I changed all the KoboTouch driver and other plugins to use apsw as this uses a later SQLite library and is what calibre uses for all of it's own database access. After making the appropriate changes to Obok, the books could be seen, but the DRM could not be removed. It could for a 3.19 database on one of my devices.
Thank you for the tip!

I bought a book from Kobo and the Obok tool raised the error regarding the uncompatible or encrypted database.
I tried to modify OBOK.PY file by changing 'sqlite3' by 'apsw' and 'fetchone' by 'next', but know the plugin complains about the database not containing valid keys...may I need more changes to use APSW? (I asume the keys are there, but the use os 'apsw' makes the script fail, maybe because the returned data when using 'apsw' is not the same as 'sqlite3').

Yes, I know I can install and use ADE, but I would prefer to have the obok plugin fixed.

I would appreciate some guidance on what changes between 'sqlite3' and 'apsw' besides 'next' instead of 'fetchone', and 'Connection' instead of 'connect'.

Thank you!
Cex is offline