jellyfin / jellyfin-plugin-bookshelf

https://jellyfin.org
MIT License
212 stars 20 forks source link

Plugin doesn't seem to do anything #104

Open deslea opened 4 months ago

deslea commented 4 months ago

Hi, I have installed the plugin, restarted, and to be sure, deleted my prior Audiobooks library and created a new one. The plugin doesn't seem to be doing anything. The library looks exactly like the old pre-plugin-install one did: Shows the folders as created on the drive, no option to show titles or other metadata, no metadata, it just looks like a mixed format folder in folder view with no option to look at it any other way. All the Bookshelf metadata options are visible in the Manage Library page, but nothing is happening and I don't even know where the metadata would appear, since the title is just shown in folder view. My folder structure is [Parent] - Audio Books - [Author Name] - [Book Name] (Year) and contains usually multiple chapters in MP3 and an icon. I have tried mapping to [Parent] and to Audio Books (in different attempts), nothing changes either way. Is it supposed to do something different? Because if all it does is list my folder structure, it isn't useful. I only have it sorted by author because that's how Jellyfin recommends and it mirrors what you would do for Music or in Calibre for ebooks. It's not how I would actually look for something unless we're talking a big name author like Stephen King. I don't know most author names by heart, especially for one-off non-fiction, and I don't really know anyone who does. I want to see a list of titles, browse by pictures like I do with my other Jellyfin content, maybe filter by genre. I'm just not sure what Bookshelf is supposed to be doing, everyone makes it sound like it's the thing that makes Jellyfin work for audiobook but I'm not seeing it do anything at all, so I'm wondering if it's actually functioning.

RitvarsZ commented 2 months ago

Same here. Trying to figure out what is going on. I have a bunch of epubs and my library is configured to prioritize epub metadata. It seems that this priority is being ignored and ComicInfo provider is failing - here is a log:

[2024-07-31 19:31:26.928 +03:00] [INF] [23] Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.ExternalComicInfoProvider: Could not load external xml from "C:\Users\Ritvars\Documents\BOOKS\test\ComicInfo.xml". This could mean there is no separate ComicInfo metadata file for this comic. Maybe the metadata is bundled within the comic
System.IO.FileNotFoundException: Could not find file 'C:\Users\Ritvars\Documents\BOOKS\test\ComicInfo.xml'.
File name: 'C:\Users\Ritvars\Documents\BOOKS\test\ComicInfo.xml'
   at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.Strategies.FileStreamHelpers.ChooseStrategyCore(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean useAsync)
   at System.Xml.XmlDownloadManager.GetStreamAsync(Uri uri, ICredentials credentials, IWebProxy proxy)
   at System.Xml.XmlUrlResolver.GetEntityAsync(Uri absoluteUri, String role, Type ofObjectToReturn)
   at System.Xml.XmlTextReaderImpl.FinishInitUriStringAsync()
   at System.Xml.AsyncHelper.CallBoolTaskFuncWhenFinishCoreAsync[TArg](Task task, Func`2 func, TArg arg)
   at System.Xml.Linq.XDocument.LoadAsyncInternal(XmlReader reader, LoadOptions options, CancellationToken cancellationToken)
   at Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.ExternalComicInfoProvider.LoadXml(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
[2024-07-31 19:31:26.928 +03:00] [INF] [20] Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.ExternalComicInfoProvider: Could not load external xml from "C:\Users\Ritvars\Documents\BOOKS\test\a-azimovs\ComicInfo.xml". This could mean there is no separate ComicInfo metadata file for this comic. Maybe the metadata is bundled within the comic
System.IO.FileNotFoundException: Could not find file 'C:\Users\Ritvars\Documents\BOOKS\test\a-azimovs\ComicInfo.xml'.
File name: 'C:\Users\Ritvars\Documents\BOOKS\test\a-azimovs\ComicInfo.xml'
   at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.Strategies.FileStreamHelpers.ChooseStrategyCore(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean useAsync)
   at System.Xml.XmlDownloadManager.GetStreamAsync(Uri uri, ICredentials credentials, IWebProxy proxy)
   at System.Xml.XmlUrlResolver.GetEntityAsync(Uri absoluteUri, String role, Type ofObjectToReturn)
   at System.Xml.XmlTextReaderImpl.FinishInitUriStringAsync()
   at System.Xml.AsyncHelper.CallBoolTaskFuncWhenFinishCoreAsync[TArg](Task task, Func`2 func, TArg arg)
   at System.Xml.Linq.XDocument.LoadAsyncInternal(XmlReader reader, LoadOptions options, CancellationToken cancellationToken)
   at Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.ExternalComicInfoProvider.LoadXml(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
[2024-07-31 19:31:26.934 +03:00] [INF] [23] Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.ExternalComicInfoProvider: Could not load ComicInfo metadata for "C:\Users\Ritvars\Documents\BOOKS\test\abedi-izabella-cuksti.epub" from XML file
[2024-07-31 19:31:26.937 +03:00] [INF] [20] Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.ExternalComicInfoProvider: Could not load ComicInfo metadata for "C:\Users\Ritvars\Documents\BOOKS\test\a-azimovs\a-azimovs-spogulspele.epub" from XML file
[2024-07-31 19:31:26.941 +03:00] [INF] [23] Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.InternalComicInfoProvider: Could not load ComicInfo metadata for "C:\Users\Ritvars\Documents\BOOKS\test\abedi-izabella-cuksti.epub" from XML file. No internal XML in comic archive
[2024-07-31 19:31:26.941 +03:00] [INF] [20] Jellyfin.Plugin.Bookshelf.Providers.ComicInfo.InternalComicInfoProvider: Could not load ComicInfo metadata for "C:\Users\Ritvars\Documents\BOOKS\test\a-azimovs\a-azimovs-spogulspele.epub" from XML file. No internal XML in comic archive
[2024-07-31 19:31:26.943 +03:00] [ERR] [23] MediaBrowser.Providers.Books.BookMetadataService: Error in "Comic Provider"
System.IO.FileNotFoundException: Could not load file or assembly 'SharpCompress, Version=0.36.0.0, Culture=neutral, PublicKeyToken=afb0a02973931d96'. The system cannot find the file specified.
File name: 'SharpCompress, Version=0.36.0.0, Culture=neutral, PublicKeyToken=afb0a02973931d96'
   at Jellyfin.Plugin.Bookshelf.Providers.ComicBookInfo.ComicBookInfoProvider.ReadMetadata(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine& stateMachine)
   at Jellyfin.Plugin.Bookshelf.Providers.ComicBookInfo.ComicBookInfoProvider.ReadMetadata(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
   at Jellyfin.Plugin.Bookshelf.Providers.ComicFileProvider.GetMetadata(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
   at MediaBrowser.Providers.Manager.MetadataService`2.RefreshWithProviders(MetadataResult`1 metadata, TIdType id, MetadataRefreshOptions options, ICollection`1 providers, ItemImageProvider imageService, Boolean isSavingMetadata, CancellationToken cancellationToken)
[2024-07-31 19:31:26.943 +03:00] [ERR] [20] MediaBrowser.Providers.Books.BookMetadataService: Error in "Comic Provider"
System.IO.FileNotFoundException: Could not load file or assembly 'SharpCompress, Version=0.36.0.0, Culture=neutral, PublicKeyToken=afb0a02973931d96'. The system cannot find the file specified.
File name: 'SharpCompress, Version=0.36.0.0, Culture=neutral, PublicKeyToken=afb0a02973931d96'
   at Jellyfin.Plugin.Bookshelf.Providers.ComicBookInfo.ComicBookInfoProvider.ReadMetadata(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine& stateMachine)
   at Jellyfin.Plugin.Bookshelf.Providers.ComicBookInfo.ComicBookInfoProvider.ReadMetadata(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
   at Jellyfin.Plugin.Bookshelf.Providers.ComicFileProvider.GetMetadata(ItemInfo info, IDirectoryService directoryService, CancellationToken cancellationToken)
   at MediaBrowser.Providers.Manager.MetadataService`2.RefreshWithProviders(MetadataResult`1 metadata, TIdType id, MetadataRefreshOptions options, ICollection`1 providers, ItemImageProvider imageService, Boolean isSavingMetadata, CancellationToken cancellationToken)

In the end, the plugin fails to gather any metadata at all.

Update: after adding some dummy ComicInfo.xml files next to my books errors are gone and metadata from the xml is read. Epub metadata is completely ignored.