-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Calibre plugin - books send to devices differ by several bytes #6491
Comments
Books transferred from Calibre via USB have 21,642,803 bytes, there was one instance where book send via calibre wireless plugin had 21,642,804 bytes, which is more than the ones send via USB. |
@Galunid: calibre reports the length in bytes of the file it is going to send. See https://github.com/koreader/koreader/blob/master/plugins/calibre.koplugin/wireless.lua#L500. Please add a few log statements and see it the origin file matches the length that calibre announces. If they match then probably is something in https://github.com/koreader/koreader/blob/master/plugins/calibre.koplugin/wireless.lua#L523-L562. I'm not to bothered to look at it, so please give a try if you wish 👍 |
I took a look and 3 different times calibre reported 3 different sizes, so I guess plugin is ok, but there is something wrong with calibre. |
Calibre updates metadata on-the-fly during the Send process (true for USB, no idea about Wireless). Getting bit-exact files out of it is not going to work, ever, AFAIU. (Except for the Content server, maybe?) |
Mmm, maybe there's a way to do that from calibre itself or using some flag on init but I have no idea. Probably the fastest way to know is asking to u/chaley on mobileread. He solved me quite a few questions in https://www.mobileread.com/forums/showthread.php?t=330205 |
Closing for the moment, feel free to reopen if it is fixable at all! |
@Galunid: I got this thread -> https://www.mobileread.com/forums/showthread.php?t=285916 Maybe disabling "keep a copy of annotations and bookmarks inside the book, to share" in calibre viewer would prevent calibre from modifying the book copy it delivers to the device. ¿? I don't know as I never use the calibre viewer. In the same thread they comment there's also a similar setting to use with "save to disk" feature. |
Thanks, I'll check it out. For now, I send all the books to both devices. I assume the first time I send it, calibre generates the file, the second time it just sends the already generated file. After restarting calibre will have to recreate the file, thus the few bytes of difference. I don't use calibre viewer too, so no clue if it's related to that. I've found the setting so we will see. |
@pazos tested disabling |
Issue
When sending books to two different ereaders, both may come with different filesize. For example book send to my Kobo Clara HD has 21,642,800 bytes, while one send to Libra has 21,642,803 bytes. They differ by 3 bytes, which wouldn't really matter, if it wasn't for different partial hashes. Because of this it's not possible to sync those books between devices. It happens both with
.pdf
and.epub
files, but probably with others too.Steps to reproduce
Connect device1 to calibre server. Send books. Disconnect device. Repeat for device2.
crash.log
(if applicable)crash.log
doesn't contain anything useful in this case.The text was updated successfully, but these errors were encountered: