04-01-2019, 03:59 PM | #1 |
Connoisseur
Posts: 56
Karma: 15570
Join Date: Jul 2017
Device: iPad
|
[GUI Plugin] KyBook3 Sync - replaced
The next Update will only be available to those who have donated £1 or more.
If you're using this plugin, please leave a comment to say whether it works for you. Thanks. Does anyone with some Python experience want to help with developing this plugin? If so, I'd be happy to make it available. PM me. Now ONLY syncs those file formats in the comma-separated list in settings. This plugin provides master-slave synchronisation of books and metadata from Calibre to KyBook3 (http://kybook-reader.com). KyBook3 provides support for almost every book and audiobook format and can read metadata from them. However, many files have incorrect metadata and/or cover. Even when KyBook3 downloads metadata and covers from Calibre's Content Server some metadata and cover errors occur. This plugin is an attempt to overcome these shortcomings. Main Features:
Special Notes:
Testimonials:
Debugging: If you have problems with the plugin:
Paypal Donations:
Version History: Spoiler:
Future Development: I plan to add the following features:
Last edited by BetterRed; 04-16-2021 at 06:26 AM. Reason: Plugin Replaced |
04-01-2019, 05:19 PM | #2 |
Connoisseur
Posts: 58
Karma: 13922
Join Date: Jul 2017
Location: Tehran, Iran
Device: iPad mini 3, Kindle PW2
|
Thanks for this plugin, I can successfully sync some books but randomly encounter this error:
calibre, version 3.40.1 (darwin, embedded-python: True) Failed to sync with KyBook3: Failed: Sync 3 books. Did you start KyBook3's Content Server? Starting job: Sync 3 books Sync complete, with 0 failures Job: "Sync 3 books" failed with error: Traceback (most recent call last): File "site-packages/calibre/gui2/threaded_jobs.py", line 84, in start_work File "calibre_plugins.kybook3_sync.jobs", line 109, in sync_threaded EOFError Called with args: ([30455, 30454, 30453], <calibre.db.cache.Cache object at 0x1192c18d0>) {u'log': <calibre.utils.logging.GUILog object at 0x127615b50>, u'abort': <threading._Event object at 0x127615ad0>, u'notifications': <Queue.Queue instance at 0x1220dccf8>} ...and I'm sure Kybook3's content server is on. |
Advert | |
|
04-01-2019, 05:41 PM | #3 |
Connoisseur
Posts: 58
Karma: 13922
Join Date: Jul 2017
Location: Tehran, Iran
Device: iPad mini 3, Kindle PW2
|
I found out that this problem occurs with some of my PDF books, some of PDF files and all of my epub files sync correctly.
Edit: Nope, it happens with epubs too. Last edited by nimapourkarimi; 04-01-2019 at 05:47 PM. |
04-01-2019, 06:33 PM | #4 |
Connoisseur
Posts: 56
Karma: 15570
Join Date: Jul 2017
Device: iPad
|
@nimapourkarimi: Well that wasn't a good start was it? :-(
I've uploaded an amended version. Give that a go and see whether it is any better. |
04-01-2019, 06:48 PM | #5 |
Connoisseur
Posts: 58
Karma: 13922
Join Date: Jul 2017
Location: Tehran, Iran
Device: iPad mini 3, Kindle PW2
|
Well no, it does that again with certain books.
|
Advert | |
|
04-01-2019, 06:55 PM | #6 |
Connoisseur
Posts: 56
Karma: 15570
Join Date: Jul 2017
Device: iPad
|
1. What OS are you using?
2. Are the same books failing each time? 3. Is there any commonality in the books that fail? (Very large, specific format, etc.) |
04-01-2019, 06:59 PM | #7 |
Connoisseur
Posts: 58
Karma: 13922
Join Date: Jul 2017
Location: Tehran, Iran
Device: iPad mini 3, Kindle PW2
|
1. macOS Mojave 10.14.4 running calibre 3.40.1
2. Yes 3. No, I can sync a 250mb PDF file but a certain 2mb pdf file won't sync, that applies to epubs too, the file copies to kybook successfully but the process fails while syncing metadata to kybook. Last edited by nimapourkarimi; 04-01-2019 at 07:02 PM. |
04-01-2019, 07:11 PM | #8 |
Connoisseur
Posts: 56
Karma: 15570
Join Date: Jul 2017
Device: iPad
|
I've uploaded another version, give that a go.
|
04-01-2019, 08:26 PM | #9 |
Connoisseur
Posts: 58
Karma: 13922
Join Date: Jul 2017
Location: Tehran, Iran
Device: iPad mini 3, Kindle PW2
|
There is no error anymore but it gets stuck at metadata sync the moment it reaches those certain books and it remains in that position. I gave it some time but nothing happened and had to kill the job eventually.
|
04-01-2019, 10:03 PM | #10 |
hopeless n00b
Posts: 5,110
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Tried the plugin. Job progress is just stuck at 1%.
Tested KyBook3 content server link is accessible via Chrome.
P.S. Is there a way to disable the mini top menu bar and clock in KyBook3? Last edited by ilovejedd; 04-01-2019 at 10:09 PM. |
04-02-2019, 08:06 AM | #11 |
Connoisseur
Posts: 56
Karma: 15570
Join Date: Jul 2017
Device: iPad
|
@ilovejedd I suspect this was a pathing issue. Unfortunately, I don't have Windows to test it.
I've uploaded a new version that I hope will work. If not, and you're happy to help with some debugging, PM we and I'll try and help you get it working. |
04-02-2019, 11:04 AM | #12 |
hopeless n00b
Posts: 5,110
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Had a look at the source code and am I correct in guessing that you hard coded the "Calibre Library" folder name and that the plugin assumes it's located in the home directory?
I'm not familiar with python nor programming Calibre plugins but I believe there must be a different method of getting the library path(s). Not sure what the relevant pieces of code are but I think this is probably a good example. Job Spy/visualize_metadata_dialog.py Code:
import os,sys,apsw from PyQt5.Qt import (Qt, QDialog, QGridLayout, QVBoxLayout, QHBoxLayout, QFont, QWidget, QSize, QPushButton, QComboBox, QGroupBox, QSplitter ) # for visualizing from PyQt5.Qt import QFileDialog,QObject,QApplication # for exporting a .csv from calibre import isbytestring from calibre.constants import filesystem_encoding, DEBUG from calibre.gui2 import gprefs, question_dialog, info_dialog from calibre_plugins.job_spy.qpainter_charts import Chart, PieChart, ViewerLegend, ViewerPieChart, DataTable from calibre_plugins.job_spy.config import prefs #----------------------------------------------------------------------------------------- def apsw_connect_to_library(self): my_db = self.gui.library_view.model().db path = my_db.library_path if isbytestring(path): path = path.decode(filesystem_encoding) path = path.replace(os.sep, '/') path = os.path.join(path, 'metadata.db') path = path.replace(os.sep, '/') if isbytestring(path): path = path.decode(filesystem_encoding) if path.endswith("/"): path = path[0:-1] try: my_db =apsw.Connection(path) is_valid = True except Exception as e: if DEBUG: print("path to metadata.db is: ", path) if DEBUG: print("error: ", str(e)) is_valid = False return None,None,is_valid my_cursor = my_db.cursor() mysql = "PRAGMA main.busy_timeout = 15000;" #PRAGMA busy_timeout = milliseconds; my_cursor.execute(mysql) return my_db,my_cursor,is_valid P.S. Forgot to mention earlier that I had to repackage the zip in order to load the plugin (got rid of the top level KyBook3 Sync directory). Calibre was complaining about __init__.py not being in the correct location. I'd be happy to help debug but please note I use Calibre Portable and I dunno how to run calibre-debug with that since the paths are all different. Last edited by ilovejedd; 04-02-2019 at 11:07 AM. |
04-03-2019, 12:20 AM | #13 |
hopeless n00b
Posts: 5,110
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Thanks! Tested it and it works great if an entry only has one format. Seems like it only sends thumbnails, though.
Plugin hangs at Metadata Sync when there are multiple formats after the ebooks have been sent to the device. I'll PM you debug logs tomorrow. |
04-07-2019, 02:37 PM | #14 |
Connoisseur
Posts: 56
Karma: 15570
Join Date: Jul 2017
Device: iPad
|
I've added the syncing of ratings and some identifiers (notably isbn, oclc, and asin). If your identifiers turn up in KyBook3 as 'id' or not at all, let me know and I'll amend the code to allow for them.
|
04-08-2019, 04:22 AM | #15 |
Enthusiast
Posts: 36
Karma: 10
Join Date: May 2011
Device: Kindle
|
Hi,
Thanks very much for this plugin. I've been testing it since the first version. I've noticed one issue. I currently use the Calibre content server to transfer a book to Kybook3. When I do this it appears in the download section of the Kybook3 library. When I shut down my iPhone and restart it Kybook3 remembers my place in the book. However, when I use the plugin to transfer the book to my iPhone, it is just in the Library and when I shutdown and restart my iPhone Kybook3 has forgotten my place in the book. Is it possible to fix this issue? Thanks Last edited by theengine; 04-09-2019 at 04:00 AM. |
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] Goodreads Sync | kiwidude | Plugins | 1761 | Yesterday 03:49 AM |
[GUI Plugin] BookFusion Cloud Sync | skillachie | Plugins | 58 | 04-29-2023 02:42 AM |
[GUI Plugin] Save Virtual Libraries To Column (GUI) | chaley | Plugins | 14 | 04-04-2021 05:25 AM |
[Gui Plugin] Cloud Sync | kerimlcr | Plugins | 13 | 03-06-2018 05:13 AM |
[GUI Plugin] Book Sync **Deprecated** | kiwidude | Plugins | 111 | 06-07-2011 07:47 PM |