Add OPDS sync feature#13946
Conversation
|
I'm working on refactoring because as it stands it won't ask to connect to wifi if not already connect. It just fails. So I'm working on that and will submit a fix for these issues with that |
|
Alright. 👍 |
|
Can it be used with other servers than calibre-web? What will happen if a user tries to sync a public OPDS catalog? I'm not sure doing |
|
Good point, I was tired and hadn't thought of that. |
|
Thanks again for all the help and input. Very appreciated! And I'll look to address the future work in near future |
|
Thank you. Awaiting for users' feedback and unavoidable bugs to be fixed. |
|
Going to ask a potentially silly question: Do I need to make a new fork to make new PRs? Or can I just update my fork to master and make new changes and open new PR? I don't want to accidentally re-open this one with new commits |
|
The way most of us work is to leave the master branch alone and to make changes in a feature branch. But it doesn't much matter what you do as long as it works for you. Deleting the fork and starting a new one can be perfectly valid, but it might be difficult to work on more than one thing at a time. |
|
Great. Yeah, it hadn't occured to me to make a branch on my forked branch. I'll do that. Thanks! |
|
Woop woop, looking forward to the nightly build 🙂 |
|
@JohannesBe Let me know if you want the calibre-web patch to support the per-page sorting by new. Otherwise, there is an alternative work-around but I think it's kind of annoying lol |
|
I've also added sync content to the opds support wiki page if you guys want to provide any feedback. If we like it, I can suggest this or similar be included in the user guide |
|
Actually there is no detailed info about plugins in the Guide, I think it would be enough if @offset-torque just add a link to the OPDS wiki page. |
|
I just realized (in using this to do a full sync of my library) that the list gets imported in inverse order sorting by modification time. My thought should be newest at the front but not sure if you agree. If so I'll make a new PR to implement this. |
|
By the way, if there are 10 new books to sync, and the max number is set to 5, which five books are downloaded: 1...5 or 6...10? |
|
Linked OPDS wiki page is clear and informative Volterxien. I will add an OPDS section to the library management chapter of the guide and add a link to this wiki page. I see that wiki is edited 47 times. If it needs frequent updates like this, it is better to leave it as a wiki page for quicker changes since our guide has a slower update cycle. |
The newest ones only. Hence I think the list should be front filled. I'll fix this today |
@offset-torque The last update to the wiki page before me was a year ago. That said, I have no issue with it just being linked! |
|
I'm thinking about this more and I think maybe it should just grab the newest ones?
That said, I think the change to have the newest stuff appear at the front of the list is very important for doing a larger sync so still a worthwhile change |
|
All this is up to you. |
|
Sure. Let's wait before doing any more changes then! |
I see, if it is stable surely I can add it to the guide. We have more formatting options in the guide, so it is more user friendly to read a topic there. I see that discussion is still ongoing here. Please update the wiki accordingly after all the changes are done and ping me so I can write the guide section based on that. |
|
The new OPDS sync works great – thank you @Volterxien! I do have a another feature request, though. Is it possible to add the ability to set up multiple sync folders, so that you may add a sync folder for each catalog? For example, I have Vinland Saga (manga) set up as a OPDS catalog, and it would be neat to have it automatically add new volumes directly to that subfolder in /manga/Vinland Saga file structure within KOReader. |
|
I'll see what we can do. The current catalog settings page is pretty cramped. We discussed adding a per catalog file extension setting as well. Thanks for the feedback! Wondering if this opens up a reason to add a "sync settings" tab in the catalog settings widget to add the per catalog file type and move the sync checkbox. |
|
Is there a user manual somewhere for this feature? https://github.com/koreader/koreader/wiki/OPDS-support does not go into detail. I've set up a Kavita server and added its “Recently Updated” catalog to KOReader, but when I press “Sync” or “Force sync”, KOReader just says “Up to date” — and the configured sync folder remains empty. I can navigate into the catalog manually, and it shows all of my books and lets me download them one by one, but the suggested download location is not the configured “sync folder”. I've also tried restarting the app in case the sync happens on startup only, but no luck. |
|
@IlyaBizyaev thanks for pointing out the lack of clarity. You must edit the catalog and check the sync box to enable the syncing features! I'll make sure to update the wiki page to better reflect that. |
|
I have checked “Sync catalog”, yes. I currently have two OPDS catalogs configured, following the Wiki page:
Also note:
But I guess I'm missing something else? |


Aims to fill #8494.
Expects new OPDS entries to be added to the front of the list (sorted by new). -- I've added a patch to calibre-web to support OPDS browsing shelves by new.
Allows up to 1 duplicate title in the event you want 2 copies that have different URL.
Will not currently restore deleted files. You need to either grab them manually or do a force sync which will overwrite everything.
To enable, check the "Sync catalog" button on a given catalog.
Potential future work:
Optionally do a full sync and restore missing files without overwriting.
Configure sync to be done optionally done in background
This change is