Skip to content

Conversation

@Icenova20
Copy link
Contributor

The current logic for calculating the episode keep limit on standard series can be misled by Season 0 (Specials) or future "dummy"
seasons (placeholder seasons with 0-1 episodes often found in Sonarr metadata). This results in the script setting an incorrectly
low keep limit and deleting valid episodes from the actual latest aired season.

This change refines the selection logic to:

  1. Explicitly ignore Season 0.
  2. Filter out placeholder seasons that contain 1 or fewer episodes.
  3. Ensure the episode count is pulled from the most recent season that actually contains aired content.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant