Skip to content

feat: add setting to disable Sonarr new season monitoring#2561

Closed
andrew-kennedy wants to merge 1 commit intoseerr-team:developfrom
andrew-kennedy:feat/sonarr-monitor-new-items
Closed

feat: add setting to disable Sonarr new season monitoring#2561
andrew-kennedy wants to merge 1 commit intoseerr-team:developfrom
andrew-kennedy:feat/sonarr-monitor-new-items

Conversation

@andrew-kennedy
Copy link
Copy Markdown
Contributor

@andrew-kennedy andrew-kennedy commented Feb 23, 2026

This PR adds a new setting to the Sonarr configuration that allows users to control the 'Monitor New Seasons' (monitorNewItems) option when adding a new series. Users can now choose between 'All Seasons' (default) and 'No Seasons', providing more granular control over future season monitoring.

This addresses the need to prevent Sonarr from automatically monitoring future seasons for specific instances.

Summary by CodeRabbit

  • New Features
    • Added "Monitor New Seasons" setting for Sonarr configuration, enabling you to choose whether new seasons are automatically monitored (all seasons or no seasons) when adding series.

@andrew-kennedy andrew-kennedy requested a review from a team as a code owner February 23, 2026 11:46
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Feb 23, 2026

📝 Walkthrough

Walkthrough

The changes introduce a new monitorNewItems setting across the Sonarr integration layer, enabling users to configure whether new seasons should be monitored as "all" or "none" when adding series. The setting is threaded from API schema through settings, request handling, and UI form components.

Changes

Cohort / File(s) Summary
API Schema & Type Definitions
seerr-api.yml, server/api/servarr/sonarr.ts
Added monitorNewItems field to SonarrSettings schema (enum: all, none) and extended SonarrSeries types with monitor options and monitorNewItems properties.
Settings Configuration
server/lib/settings/index.ts
Added optional monitorNewItems property to SonarrSettings with values 'all' or 'none'.
Request Handling
server/subscriber/MediaRequestSubscriber.ts
Propagated monitorNewItems setting to both Radarr movie and Sonarr series request options during media creation.
UI Components
src/components/Settings/SonarrModal/index.tsx
Added "Monitor New Seasons" select field with localized options, form state binding, and submission payload integration.

Sequence Diagram(s)

sequenceDiagram
    actor User
    participant SonarrModal as Sonarr Settings UI
    participant SettingsAPI as Settings Service
    participant MediaRequestSubscriber as Request Handler
    participant SonarrAPI as Sonarr API

    User->>SonarrModal: Set monitorNewItems to "all" or "none"
    SonarrModal->>SettingsAPI: Save SonarrSettings with monitorNewItems
    SettingsAPI->>SettingsAPI: Store monitorNewItems in config

    Note over User,SonarrAPI: Later: When adding a new series

    MediaRequestSubscriber->>SettingsAPI: Retrieve SonarrSettings
    SettingsAPI-->>MediaRequestSubscriber: Return settings with monitorNewItems
    MediaRequestSubscriber->>SonarrAPI: Create series with monitorNewItems option
    SonarrAPI->>SonarrAPI: Apply monitoring config based on monitorNewItems
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 A new setting hops into view,
Monitor new items, all seasons or none to choose,
From schema to UI, the field threads through,
Sonarr seasons now dance to a configurable tune! 📺✨

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding a new setting to control Sonarr new season monitoring, which is reflected across all modified files and the UI implementation.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

@0xSysR3ll 0xSysR3ll closed this Feb 23, 2026
@0xSysR3ll
Copy link
Copy Markdown
Contributor

0xSysR3ll commented Feb 23, 2026

As stated here : #2560

There already is a PR for this.

But thanks for your contribution either way 😄

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
server/api/servarr/sonarr.ts (1)

74-105: ⚠️ Potential issue | 🟡 Minor

Narrow monitorNewItems type from string to 'all' | 'none'.

The Sonarr API only accepts "all" (default) or "none" as valid values for the monitorNewItems field at the series root level. The current string type allows any string value, which could result in invalid API requests being silently rejected by Sonarr. Tighten the type in both SonarrSeries (line 80) and AddSeriesOptions (line 104) to the enum union 'all' | 'none'.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@server/api/servarr/sonarr.ts` around lines 74 - 105, The monitorNewItems
field is currently typed as string which permits invalid values; update the
SonarrSeries interface and the AddSeriesOptions interface to narrow
monitorNewItems to the literal union 'all' | 'none' (replace the current
monitorNewItems: string declaration in SonarrSeries and AddSeriesOptions with
monitorNewItems?: 'all' | 'none' where appropriate) so only the two valid API
values are allowed. Ensure you update both the SonarrSeries type and the
AddSeriesOptions type references to use the new union.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@server/api/servarr/sonarr.ts`:
- Around line 74-105: The monitorNewItems field is currently typed as string
which permits invalid values; update the SonarrSeries interface and the
AddSeriesOptions interface to narrow monitorNewItems to the literal union 'all'
| 'none' (replace the current monitorNewItems: string declaration in
SonarrSeries and AddSeriesOptions with monitorNewItems?: 'all' | 'none' where
appropriate) so only the two valid API values are allowed. Ensure you update
both the SonarrSeries type and the AddSeriesOptions type references to use the
new union.

ℹ️ Review info

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3bcb4da and 0a404b8.

📒 Files selected for processing (5)
  • seerr-api.yml
  • server/api/servarr/sonarr.ts
  • server/lib/settings/index.ts
  • server/subscriber/MediaRequestSubscriber.ts
  • src/components/Settings/SonarrModal/index.tsx

@andrew-kennedy
Copy link
Copy Markdown
Contributor Author

Damn, it's really unfortunate that this has languished so long. Can I do anything to help get that other PR merged @0xSysR3ll ? My maintainerr workflows to clean up seasons keep breaking because of how seerr keeps allowing for the adding of seasons that don't have any requests.

@0xSysR3ll
Copy link
Copy Markdown
Contributor

Damn, it's really unfortunate that this has languished so long. Can I do anything to help get that other PR merged @0xSysR3ll ? My maintainerr workflows to clean up seasons keep breaking because of how seerr keeps allowing for the adding of seasons that don't have any requests.

The said PR has been reviewed and is waiting to be merged. We wanted to focus on the first stable release of Seerr before merging feature PRs. It should be available in a future release.

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.

2 participants