Read Book metadata from .OPF file?

Clay 3 years ago updated by Casey Link 2 years ago 6

It would be tremendous if Ubooquity would display the metadata from the .opf that may exist alongside an epub / mobi / whatever file.

I'd really like to be able to see the series information for a book.


Well, Ubooquity already reads the OPF inside the epub files. ;)

I don't like the idea of an external metadata file, as there are already good metadata mechanism for a lot of common formats (perhaps with the exception of PDF files).

Why not use something like Calibre to edit the metadata of your epub files ?

As for the mobi, the real issue is that this is a closed, undocumented format.

Let's not decline this so soon.

1) as you mentioned, there are numerous file formats that do not support modiying the internal metadata, so the only option for those is to use an side file. The fact that .opf exists at all (as an open spec to boot) indicates that there's a use for it

2) the comicbook community has a sideload format as well, so they see a need for it as well https://wiki.mobileread.com/wiki/CBR_CBZ#ComicBookInfo

3) there are a number of sharing communities in which modifying the original file is verboten - DC++, Torrents, etc - once you have altered the original file, you've essentially become useless. Another community I participate in actually brought this up for managing comics as well


I add another voice for a side file.  In addition to Clay's excellent reasons it's also practical from a data management perspective.  If you want to update the meta of your files, whether it's 1 or 10,000, the side file in each archive will have to be updated.  Which means reading the archive, potentially extracting it to a temporary location, updating the file, then re-archiving the file.  In addition to the time it takes, this will also cause the file to be "new."  So if you back up your files, you'll have to back the whole dang archive up again.  Or if you have the entire file on your device, you would have to redownload the entire file because a single 1K file inside the archive had a minor change.  Updating a smaller sidefile, for instance, will be quicker and won't require a full back-up.


Your arguments are valid, but I still believe they don't outweigh the advantages of embedded metadata.

I created an entry in my backlog to add external OPF support in Ubooquity, but since this is a very specific scenario, it's unlikely to be implemented anytime soon.

Thanks for taking the time to read and reply.  Keep up the great work with Ubooquity!


For what it's worth I'd also like to stress the argument that external metadata is very useful when running ubooquity attached to a network storage (such as a NAS, google drive, etc). To read the metadata of a file, ubooquity has to download the entire file, which causes unnecessary bandwidth load when the metadata.opf file exists.