Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
629f50ecdc | ||
|
|
3e2450b5fd | ||
|
|
0de5e86837 |
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "jellyplex-watched"
|
name = "jellyplex-watched"
|
||||||
version = "8.1.0"
|
version = "8.2.0"
|
||||||
description = "Sync watched between media servers locally"
|
description = "Sync watched between media servers locally"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.12"
|
requires-python = ">=3.12"
|
||||||
|
|||||||
@@ -377,8 +377,24 @@ class JellyfinEmby:
|
|||||||
if not show.get("UserData"):
|
if not show.get("UserData"):
|
||||||
continue
|
continue
|
||||||
|
|
||||||
if show["UserData"].get("PlayedPercentage", 0) > 0:
|
played_percentage = show["UserData"].get("PlayedPercentage")
|
||||||
watched_shows_filtered.append(show)
|
if played_percentage is None:
|
||||||
|
# Emby no longer shows PlayedPercentage
|
||||||
|
total_episodes = show.get("RecursiveItemCount")
|
||||||
|
unplayed_episodes = show["UserData"].get("UnplayedItemCount")
|
||||||
|
|
||||||
|
if total_episodes is None:
|
||||||
|
# Failed to get total count of episodes
|
||||||
|
continue
|
||||||
|
|
||||||
|
if (
|
||||||
|
unplayed_episodes is not None
|
||||||
|
and unplayed_episodes < total_episodes
|
||||||
|
):
|
||||||
|
watched_shows_filtered.append(show)
|
||||||
|
else:
|
||||||
|
if played_percentage > 0:
|
||||||
|
watched_shows_filtered.append(show)
|
||||||
|
|
||||||
# Retrieve the watched/partially watched list of episodes of each watched show
|
# Retrieve the watched/partially watched list of episodes of each watched show
|
||||||
for show in watched_shows_filtered:
|
for show in watched_shows_filtered:
|
||||||
|
|||||||
2
uv.lock
generated
2
uv.lock
generated
@@ -84,7 +84,7 @@ wheels = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "jellyplex-watched"
|
name = "jellyplex-watched"
|
||||||
version = "8.1.0"
|
version = "8.2.0"
|
||||||
source = { virtual = "." }
|
source = { virtual = "." }
|
||||||
dependencies = [
|
dependencies = [
|
||||||
{ name = "loguru" },
|
{ name = "loguru" },
|
||||||
|
|||||||
Reference in New Issue
Block a user