-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Episode multiple versions #8004
base: master
Are you sure you want to change the base?
Episode multiple versions #8004
Conversation
|
One change that could affect current users. Movie versions that include a year as part of the version name need to be placed in brackets. Otherwise they appear as a possible episode and won't merge with other versions. |
|
Related discussion. #7900 |
|
Latest commit adds support for multiversion episodes in mixed folders (like season and series) so this file list is now supported. (Which Emby supports) |
296c01e to
bcedad2
Compare
|
Force pushed to rebase to current master. |
|
Super interested in this pull. Question, in it's current format, would this allow me to have multiple versions of an episode, even if they are stored in different directories? or would they all have to be combined within one folder? What i'm hoping to achieve is to store the majority of my content on one server, while dedicating another to strictly UHD/4k content. Something like this; |
|
Unfortunately no. The episodes would have to be in the same folder to be merged. |
Alas, perhaps some day. Keep up the good work though! |
|
Lots of code would have to be changed to get this to work. |
|
Also, this would probably be helpful in implementing this: https://features.jellyfin.org/posts/284/convert-option-similar-to-plexs-optimise |
|
What is the state of this now(I have a structure like @JaidenW , but I can work around that with a simple overlayfs mount, I don't need it to be writable)? It seems there is a lot of debate about how to best do the parsing and this PR currently seems to have gone dead? Anything preventing me from just rebasing onto master and building from source with this PR applied? |
|
This PR is waiting on reviewers from the JF team. Nothing to stop you merging in your local copy. |
|
So I've been trying this out and have not been able to get it to work no matter what I tried. I use Season folders and a structure like The issue is that all episodes get grouped as versions. I also tried with the same results. I tried making sense of the code itself, but frankly I do not quite understand the its logic. Is there anything I'm doing wrong? Or should this work? |
|
I think you need all versions to have a name. Try this instead and let me know. |
|
Did you merge all the commits in the PR not just the first one? There was an issue with all episodes merging before. If my tip didn't help, can you include a screen shot of the episode all the videos are getting merged into with the version selection drop down open? |
|
Yes, I merged all of them, I can't really test right now, I'll get back to this though. |
|
@SenorSmartyPants I got around to testing it, even with everything named according to |
|
I'll take a look at this today. |
|
@JeWe37 I was able to reproduce this with your Name (2020) example. So I will continue to dig into this. It did work correctly when I used a different example to check if it was related to having the year in the series name. |
|
@JeWe37 Latest commit should fix your issue. Thanks for reporting it! |
|
I'll give it a shot tomorrow, thanks for the quick resolution. |
|
I don't like that a folder is required. We need fewer filesystem rules, not more. |
A folder is no longer required. Other than the folder requirements that already exist, that is a series folder. |
|
Any update on this? This would be big. |
This needs to be reviewed and approved by team JF. Maybe I could get some feedback from @Bond-009 @Shadowghost @crobibero @cvium . I think they are some of the core server people. |
|
Thanks for this. |
|
If it's any help: I've been running a jellyfin instance with this PR merged for a while now and it's been working fine. I have a fairly consistently named library, which is required to really get this feature to work, but I have not seen it interfering anywhere I did not want it to. |
Awesome. Glad someone is getting some use out of it other than myself. |
|
Hello, I updated my fork to the latest 10.10.0 release: master...mammo0:jellyfin:10.10.z-mammo0 All test cases are passing :) I also updated my docker images on: https://hub.docker.com/r/mammo0/jellyfin_multi-episode-versions |
|
This feature would be huge, I can't believe I have to switch to a fork to use it lmao. Thank you so much for making this PR It's been two and a half years 😭 |
I would include cross over episodes like murder she wrote the Andy Griffith show gomer Pyle etc that way it pulls from one file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor coding style detail, otherwise LGTM
|
So far @SenorSmartyPants hasn't implemented them, though it might be best to avoid a new PR so that the approvals aren't needed again. Can one of the maintainers perhaps push those directly? Or the rebased version from @mammo0's fork anyway. |
|
I'm hesitant to put effort into this without some assurances it will actually get merged. It's been a long time and my current energy level for projects is pretty low. Or if a JF team member wants to make alterations to get this merged you have my permission. |
|
@SenorSmartyPants If you want I can continue this PR. Since we have already an approval from @Shadowghost and now a 'LGTM' (after a small change) from @JPVenson, I hope this will get merged soon. @SenorSmartyPants Can you give me write access to your fork (especially the What option is preferred? @JeWe37: I can also open a PR on the |
|
Feel free to open the jellyfin-web PR as you have a rebased version. |
@mammo0 I don't see any easy way to give you access to just one branch on my repo. So instead, could you make a PR to https://github.com/SenorSmartyPants/jellyfin/tree/EpisodeMultipleVersions which I can then merge and that will update this PR? |
Please have a look at SenorSmartyPants#121 :) |
Test for episodes in series folder Turn on multiple versions for episodes Support for multiversion episodes in mixed folders Update 2 failing test cases. These were for passing for unofficially supported filenames. Dashes with no spaces, which is not how JF docs say multiversion files are supposed to be named. Fix possible null fix null take 2 Don't ParseName when calling ResolveVideos<Episode> ParseName drops everything after year in a filename. This results in episode information being dropped if year is present. Update tests to set ParseName=false Additional test with Mixed folder with Year in filename Added case when calculating displayname for versions for mixed folders. Add StringComparison.Ordinal to LastIndexOf Was generating an error in recent build attempts. Clean the episode filename to set the grouper value This allows files like Name (2020) - S01E01 [BluRay-480p x264][AC3 2.0] - [ORIGINAL].mkv Name (2020) - S01E01 [BluRay-1080p x264][AC3 5.1]- [Remaster].mkv to be grouped on 'Name (2020) - S01E01' Fix false positive merging Only do cleanstring or " -" index cleaning, not both. Compatiblity fix when stacking episodes and multiple versions are present Fix linting problems
8f3a4ca to
c91faf9
Compare
ABI Difference |
|
I fixed merge conflicts and tests. I did not include the library option to enable/disable grouping. Let that be a separate PR after this is merged. So this PR does not require any web changes. |
|
I think it’s best to hold off on adding these functions right now. We’re currently in the middle of a major database refactoring, and we need to make sure we have a solid data structure for multi-version videos before we proceed. We don’t want to end up with a bunch of bugs, especially with playlists and collections like the already merged muiltversion movie, which has been a pain to maintain, and I don’t want to see episodes get caught up in the same mess. Let’s wait until things are a bit more stable before we dive into this. |
|
@gnattu Totally reasonable. Do you think after that database migration this can be looked at again? This would be a super useful feature to have in Jellyfin. I really hope it doesn't get abandoned forever. |
|
There are no database changes with this since it only makes it so that episode merging happens automatically rather than manually. While this could exacerbate any possible issues by making merged series more common, even in the worst case of an imperfect database migration in the future, a rescan should deal with any merging-related issues with little hassle. Frankly it is somewhat frustrating to hear that this still cannot move forward. For my part I have been running a fork of jellyfin because of this(and similar issues) for multiple years now and I seem to not be the only one frustrated with the current situation:
This is particularly true with this now being one of the more requested, yet still not available feature requests. |
If writing migrations and doing data schema refactors sounds easy to you can you help us with the current refactor so that we can move to the right direction faster? #12798
I am also frustrated by current multi version implementation as it is causing bugs due to the design flaw. It failed to predict a lot of common use cases and it is hard to fix because the already written data is hard to migrate even if we come up with a better design. I want to have this anticipated feature to land just like everyone in the feature request ticket because I want to implement features based on this. I just want to make sure the design flaws are addressed before we can adding more features like this. |
My point is solely about the fact that merging this will not make the database issues worse. I obviously cannot claim that I were intimately familiar with the issues around multiple versions, though for the past years it has been working essentially fine for me. Now, of course this doesn't mean those issues don't exist, but it does mean this PR can be used productively and, since it does not introduce anything new to the database format, inherently cannot change or complicate anything about the migrations that already have to be written. |
|
whats not that widely known is that the current refactor brought up so many many issues with the codebase that streach into all areas of the code. The database is the core of jellyfin and unfortunatly a lot of bad design choices were made based on the horrific database design. Now we can't just replace the database with better code, that would be far to easy and would have been done many years ago. To make the database somewhat usable, the code needs to still support attrocious design choices, like querying the database 1+n² times just for the next-up query. Sure we can rewrite that but i hope you see where i am going with that. I was so close to rewriting even bigger chunks just to get a somewhat sensible UI structure and the Pr is already +20.000 lines of code. Overall we are currently focusing hard on the EfCore rewrite, because it has to be done some time and that time is now, which on the other hand means that we cannot really bring much else in right now because we just dont have the capacity for it. Please dont underestimate the reach the EfCore PR has, it touches like 60-70% of the codebase and adding even more new stuff to that will make it borderline impossible to debug in the end. |


Changes
Enable multiple versions for episodes. Episode suffixes work or episode may be placed in it's own directory. Will not collapse episodes in series directory. Unit tests included.
JF will show 3 episodes in season 1. 2 episodes in season 2.