-
Notifications
You must be signed in to change notification settings - Fork 1
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
[Bug]: wrong interaction between filters #39
Comments
Well it all depends on your Let's use 60 days as my example below and say I watched the movie on the 01/01/2024. The "Any user" option should delete the movie 60 days after the FIRST watch. So in this case, it would be deleted on 1st March 2024. The "Any user (latest playback)" option should delete the movie 60 days after the LAST watch. So if I watch the movie on the 01/01/2024 and then you watch it 30 days later, the movie should delete itself on 31st March 2024. |
@NicolaSmaniotto It's been highlighted to be that this is due to your media library probably being set to "File creation date" as opposed to "Use date scanned into the library". You can find this at the route |
The setting is already "Use date scanned into the library". The metadata is correct. I understand the difference between "Any user" and "Any user (latest playback)", I don't see how it is relevant to this issue. |
@NicolaSmaniotto What Jellyfin shows in "Date added" metadata for "Nosferatu"? |
I'm not saying you don't understand how the logic works, I'm saying how it SHOULD work in-case the plugin doesn't do this already. Helps both us understand how it works and for the dev to understand what functionality we expect. In the future, understand people aren't trying to undermine you. You also haven't provided your metadata to back your point. |
Nevermind, I figured out the problem. Sorry, busy days at work 😅 |
@NicolaSmaniotto Could you please test this build? |
That build freezes Jellyfin when trying to open the plugin settings. It logs:
|
Did you restart Jellyfin after replacing file? |
I did not 😅 Now the log looks good, it is no longer trying to delete Nosferatu. I'll check it better and report if some other unexpected files appear. Thank you! |
I've tried all the combinations of events I could think of:
The last two just confirm that the behavior is the same as before, whether the user sets Also, I tried with "Keep while not played by" set to "Any user", and it seems to work as well:
This build seems to fix my issue 👍 |
Thanks for comprehensive testing! I'll push an update to release. |
Sorry to bother you again, but there is still an issue. Here is an example: I watched the first episode 30+ days ago. If the plugin is set to keep watched items for 30 days and unwatched forever, something like this is logged:
If I then set both "keep played for" and "keep not played for" to 30 days, something like this is logged instead:
So in this way the series will never be removed. Since nobody actually watched it in many days, who started it probably decided not to continue watching it, so the plugin should remove it. Users who for some reason watch the series really slowly can always add it to their favorites to keep it around. |
Yup, that's right. There will be another setting for that case (because I personally use it this way, I don't want to mark all show as favorites 😄 ). |
Makes sense, thank you! |
Fixes shemanaev#39
What happened?
I configured the new " Keep not played for X days" option to 60 days, but I noticed that it would try to delete some movies even when in my opinion it should not.
Here is a specific example:
Nosferatu was added to the server on the 31st of January 2023.
I've watched it recently, the log shows:
[Deb] ItemsAdapter: "Nosferatu" played by "nicola" (01/31/2024 00:20:11)
Since it has been opened in the last 30 days, then the log shows:
[Tra] Filtering.ExpiredFilter: Filtering item "Nosferatu"
[Tra] Filtering.ExpiredFilter: Latest played by "nicola"
[Tra] JunkCollectors.MoviesJunkCollector: "Nosferatu" filtered by Expired
Then when the new filter is applied:
[Tra] Filtering.ExpiredNotPlayedFilter: Filtering item "Nosferatu"
[Tra] Filtering.ExpiredNotPlayedFilter: Not played by anyone since 01/31/2023 00:00:00
And at the bottom:
[Inf] MediaCleanupTask: (Movie) "Nosferatu" will be deleted because no one played it since 01/31/2023 00:00:00
I think this is not intuitive at all (or even wrong). I don't want the plugin to delete something that users are watching, no matter how old the file is.
A solution could be to run the ExpiredNotPlayedFileter first, to collect all the old files, then the ExpiredFilter, overwriting the list if needed. Finally check its most recent play.
Troubleshooting info
The text was updated successfully, but these errors were encountered: