Kareadita / Kavita

Kavita is a fast, feature rich, cross platform reading server. Built with the goal of being a full solution for all your reading needs. Setup your own server and share your reading collection with your friends and family.
http://www.kavitareader.com
GNU General Public License v3.0
6.53k stars 341 forks source link

2 Books with the same Title only 1 shows up #2485

Closed X-Xadro closed 12 months ago

X-Xadro commented 12 months ago

I use the docker version of Kavita proved by linuxserver.

If you have 2 books (epubs) which have the same Title, in my case , in the content.opf then one of the books do not show up.

I actually found this out because i was going read a book and it had a summary () that did not match said book and when i looked up the epub itself i saw that i never put in a summary and it seems it actually took the summary of the second book which has the same title.

Both books not have the same author, genre, publisher or even filename and aren't even in the same folder on the system, they do are in the same library though, just different subfolders. Neither of them have series either.

They only have matching titles.

Even when i filter by the author/writer of the book that is missing it does not show up. Also other books in the same folder do show up and the filename is not overly long either

When i change the in the content.opf file of the epub and scan the library it shows up. And when i change it back to the previous Title it is still there but the other book has disappeared instead. I guess Kavita picks the book that has the latest modified date or something.

majora2007 commented 12 months ago

Are you sure they aren't stacking within the book within the series?

image

majora2007 commented 12 months ago

Or are they in different folders from the library root? Because if the latter, then yes, it's an invalid configuration and they must be in the same folder. Kavita doesn't support the same series in different folders from library root.

X-Xadro commented 12 months ago

They have no series, the also aren't part of a series. They are in different folder because they are different books of different genre's

majora2007 commented 12 months ago

Series in this context means a dedicated page within Kavita. Kavita groups books or comics into "Series". It's not to be confused with a Series of Books, like series_group in the epub. I'm trying to understand what the issue is.

X-Xadro commented 12 months ago

They both are in the library/main folder called FanFiction.

The first book is in a subfolder called "Short Fics" The second book is in a subfolder called "Crossovers"

They both have the same Title but different authors, nothing of these books match aside from the title.

When i view the only book that shows up and check the Info/Details page only that single book is shown 2023-12-07 22_33_31-Kavita - Raven Details

majora2007 commented 12 months ago

Does your library look something like this (where root/ is the library root):

/root/Harry Potter/FanFics/harry potter.epub
/root/Harry Potter/Short Stories/harry potter.epub

or

/root/FanFics/Harry Potter/harry potter.epub
/root/Short Stories/Harry Potter/harry potter.epub
X-Xadro commented 12 months ago

Like this

\eBook\FanFiction\Harry Potter\Crossovers\Raven - JustBored21 [Harry Potter + Avengers Crossover].epub \eBook\FanFiction\Short Fics\Raven - Short Fics [Short Fics].epub

majora2007 commented 12 months ago

Okay this isn't a supported configuration. As I mentioned, from the library root, a series (or single book that is created into a series) cannot be in 2 parallel folders from the root. So you'd have to do something like change the title of one of them slightly so they don't match exactly on the title.

What is happening is Kavita processes folders at the library root and each time it's doing it in a different order and it's seeing each book as "Harry Potter" and saying this is the series, and deleting the old one because it doesn't see it. It's a shortcoming of the scan loop, but this requirement drives a ton of optimizations and allows for the scan loop to avoid doing extra work each time.