ankenyr / jellyfin-youtube-metadata-plugin

Youtube Metadata Plugin for Jellyfin
GNU Affero General Public License v3.0
481 stars 31 forks source link

Directory structuring and webp thumbnail issues #90

Closed iarp closed 10 months ago

iarp commented 10 months ago

My personal preference for directory structure is Channel/YEAR/... however attempting to do this setup results in a single video showing for each year and then each video within each year is a "version". I'm OK with changing it to be in the root of Channel/ though. I'm kinda asking if there is a setting I'm missing.

A question about channel ID, should that be in the channel directory name as well? Like Channel [CHANNELID]? I ask because I can only find information about the video file naming structure and nothing about the channels, both here on this project and on the french scripts too.

Lastly, webp thumbnails are not loading correctly. For instance I have about 55 videos and the thumbnail extensions in order are JPG, WEBP, JPG, WEBP, WEBP, WEBP, WEBP...etc. What's happening is the first JPG loads correctly on the video and then that first JPG it encounters becomes the thumbnail for all WEBP's. Short of scripting something to convert webp to jpg, which would be kind of annoying, is there something I can do?

There are no logs beyond [16:32:01] [INF] [49] Emby.Server.Implementations.IO.LibraryMonitor: Watching directory /youtube/Beau Miles

ankenyr commented 10 months ago

I have my setup as Channel/Year/Video/files so each video has a folder containing the video file, thumbnail, json, and other information.

The channel directory should not need the channel ID.


root@openmediavault:/srv/mergerfs/Media/Media/Youtube/Atrocity_Guide# tree
.
├── 2018
│   ├── Atrocity_Guide - 20180926 - Bob_Hickman_God_Entered_My_Body
│   │   ├── Atrocity_Guide - 20180926 - Bob_Hickman_God_Entered_My_Body [n-_BC9dkC0Y].description
│   │   ├── Atrocity_Guide - 20180926 - Bob_Hickman_God_Entered_My_Body [n-_BC9dkC0Y].info.json
│   │   ├── Atrocity_Guide - 20180926 - Bob_Hickman_God_Entered_My_Body [n-_BC9dkC0Y].mkv
│   │   └── Atrocity_Guide - 20180926 - Bob_Hickman_God_Entered_My_Body [n-_BC9dkC0Y].webp
│   ├── Atrocity_Guide - 20180930 - Karin_Catherine_Waldegrave_An_Analysis
│   │   ├── Atrocity_Guide - 20180930 - Karin_Catherine_Waldegrave_An_Analysis [VyHYOn6djlE].description
│   │   ├── Atrocity_Guide - 20180930 - Karin_Catherine_Waldegrave_An_Analysis [VyHYOn6djlE].info.json
│   │   ├── Atrocity_Guide - 20180930 - Karin_Catherine_Waldegrave_An_Analysis [VyHYOn6djlE].mkv
│   │   └── Atrocity_Guide - 20180930 - Karin_Catherine_Waldegrave_An_Analysis [VyHYOn6djlE].webp
│   ├── Atrocity_Guide - 20181001 - Robhgien_Yrgna_Angry_Neighbor_An_Analysis
│   │   ├── Atrocity_Guide - 20181001 - Robhgien_Yrgna_Angry_Neighbor_An_Analysis [2N6WMt2G28w].description
│   │   ├── Atrocity_Guide - 20181001 - Robhgien_Yrgna_Angry_Neighbor_An_Analysis [2N6WMt2G28w].info.json
│   │   ├── Atrocity_Guide - 20181001 - Robhgien_Yrgna_Angry_Neighbor_An_Analysis [2N6WMt2G28w].mkv
│   │   └── Atrocity_Guide - 20181001 - Robhgien_Yrgna_Angry_Neighbor_An_Analysis [2N6WMt2G28w].webp
│   ├── Atrocity_Guide - 20181006 - The_Death_of_Olivia_Mabel_Viral_Marketing
│   │   ├── Atrocity_Guide - 20181006 - The_Death_of_Olivia_Mabel_Viral_Marketing [xSvdKp7FUvE].description
│   │   ├── Atrocity_Guide - 20181006 - The_Death_of_Olivia_Mabel_Viral_Marketing [xSvdKp7FUvE].info.json
│   │   ├── Atrocity_Guide - 20181006 - The_Death_of_Olivia_Mabel_Viral_Marketing [xSvdKp7FUvE].mkv
│   │   └── Atrocity_Guide - 20181006 - The_Death_of_Olivia_Mabel_Viral_Marketing [xSvdKp7FUvE].webp
│   ├── Atrocity_Guide - 20181016 - The_Internet_s_Most_Bizarre_Website_-_Yvette_s_Bridal_Formal
│   │   ├── Atrocity_Guide - 20181016 - The_Internet_s_Most_Bizarre_Website_-_Yvette_s_Bridal_Formal [Rofmr7_xc7A].description
│   │   ├── Atrocity_Guide - 20181016 - The_Internet_s_Most_Bizarre_Website_-_Yvette_s_Bridal_Formal [Rofmr7_xc7A].info.json
│   │   ├── Atrocity_Guide - 20181016 - The_Internet_s_Most_Bizarre_Website_-_Yvette_s_Bridal_Formal [Rofmr7_xc7A].mkv
│   │   └── Atrocity_Guide - 20181016 - The_Internet_s_Most_Bizarre_Website_-_Yvette_s_Bridal_Formal [Rofmr7_xc7A].webp
``
The above is a clipping of one of my directories. It don't believe it would hurt to add the channel ID to the directory names.

I have webp plugins and have never run into this issue. Do you mind turning on debug logging and trying again to see if there is any other messages?
iarp commented 10 months ago

When I reorganize and use your pattern, with each video in its own directory, then it appears in jellyfin correctly. But if I place all videos from a single year in the root of the year directory then they appear as versions of the first video in the year.

I have no webp plugins, I just assumed webp as an image would work. I can mess with debug logs tomorrow.

iarp commented 10 months ago

I went ahead and am sticking with your directory-per-video system. and the thumbnails now automatically convert to jpg as webp was still causing problems and it became easier to just convert them on download.

A secondary issue as come up with some years being picked up as a series and then it gets mapped to random channels and the metadata and thumbnails are all incorrect. Even though the thumbnail and info.json both exist and are both named identically to the video file name.

I'm unsure how to stop it from thinking its a series. I attached a log file. advok 2020.txt

What I did was go into the series, edit the metadata with the correct channels YoutubeMetadata Id: along with correcting the Title. Despite that when i hit refresh on the year it brings it right back to "Canada 2020".

Edit: I'm wondering if my selection of "Mixed Movies and Shows" is causing this to happen? Or if because one of the videos for 2020 has "season 6 episode 10" in the name.

iarp commented 10 months ago

Well. I tried as Movies only but that didn't group the videos by channel/year/video it was just all of the videos in one giant screen. So I re-added it as Shows only and all seems to be well.