jorenn92 / Maintainerr

Looks and smells like Overseerr, does the opposite. Maintenance tool for the Plex ecosystem
https://maintainerr.info
MIT License
754 stars 13 forks source link

Plex - [list] Viewed by (username) returning empty list #1242

Open Bod1985 opened 2 weeks ago

Bod1985 commented 2 weeks ago

Describe the bug Episodes and Movies that have been watched do not reflect that when checking the viewed by list.

To Reproduce Steps to reproduce the behavior:

  1. Create a rule that uses the viewed by username list
  2. Test a collection by finding known watched media
  3. Observe empty list

Worth noting that "Total Views" accurately reflects the count such as 1 or 2.

Expected behavior The list should contain a list of users that have viewed the content.

Device (please complete the following information):

jorenn92 commented 1 week ago

Are the episodes actually watched? Or just marked as watched? Plex doesn’t generate watch records when you mark an item as watched.

Bod1985 commented 1 week ago

Are the episodes actually watched? Or just marked as watched? Plex doesn’t generate watch records when you mark an item as watched.

I was testing with episodes I'd finished completely. I noticed it was working previously for weeks but now I've got lots of episodes left behind that my rule previously was deleting

sameep22 commented 1 week ago

Just to add my two cents, I am also facing a similar issue. I know for a fact that I have seen a season, I can see the entries in Plex history and Tautulli, but on checking the media, Plex doesn't seem to return my username in the list of users that have seen the episodes. Please note, contrary to the OP's problem, I do get some names in the list, but not all. Could this be related to the latest update?

rickzim commented 1 week ago

The same is happening to me. Movies and tv shows that were previously in the collection, are now being removed since my username is no longer in the list.

appiekap653 commented 1 week ago

Same here, maintainerr 2.04 did work but since the last update something broke.

Users that saw all available episodes returns empty Users that watch the show/season/episode returns also empty

Reverting back to 2.0.4 fixes it and adds the shows back to the collection to delete. Going back to 2.1.0 removes the shows from the collection again.

jorenn92 commented 1 week ago

Are you testing this with the server owner by any chance? I’ve tracked the issue down to how Plex manages the owner's account ID. For some reason, the owner’s ID is set to '1' instead of their actual Plex ID. In version 2.1.0, I refactored the code to fetch information from Plex's community API to provide more accurate details for users, including the owner’s correct ID. However, this caused issues because the watchlist still uses '1' for the owner. I’ve now refactored the code again to account for this. After https://github.com/jorenn92/Maintainerr/pull/1252 is merged, it should work as expected.

sameep22 commented 1 week ago

Yes, in my case, it is the server owner's name that is missing from the list returned by Plex. I shall just have to wait for this code to get to the stable release. Many thanks @jorenn92

zenxedo commented 5 days ago

I am still having this issue for the main user using 2.1.1

rickzim commented 5 days ago

I am still having this issue for the main user using 2.1.1

For me the issue remains on movies as well. But it seems to be fixed for TV Shows.

jorenn92 commented 5 days ago

@zenxedo @rickzim, my bad—I may have overlooked the 'Viewed by' rule for movies and only applied the fix for shows. This should now be resolved for movies as well after the merge of this PR.

Would you be able to verify this using the main/develop image? (Should be available in about 10 minutes)

rickzim commented 5 days ago

@jorenn92 Np! Thank you for being on it so quickly. Im currently unable to test it but i'll ask a friend!

zenxedo commented 5 days ago

Thank you for the fast fix and a great app. Tested in develop and it's working now