Skip to content

Movie/TV media stuck at UNKNOWN with stale externalServiceId permanently blocks re-requesting (gap in #2757 orphan cleanup) #3576

Closed as not planned

Description

@ccarpinteri

Description

A media row can be left with status = 1 (UNKNOWN) while externalServiceId still points at a Radarr/Sonarr entry that no longer exists. Seerr matches on tmdbId before creating a request, finds that row, and blocks the new request with "Duplicate request for media blocked". The title then cannot be requested again. In the UI the Status column is blank, and there is no way for a user to clear it.

The attached media_request row is also left at status 2 (APPROVED), so the request list shows an approved request that will never progress.

This is a re-file of #3476, which was closed as blocked:template rather than resolved. The underlying problem is still present and has recurred. This report follows the bug template.

The gap is in the orphan cleanup added by #2757. That cleanup correctly resets a stuck PROCESSING media row back to UNKNOWN when Radarr no longer tracks the title, but it does not clear externalServiceId / jellyfinMediaId, and it does not resolve the attached media_request. The row is therefore left in a state that the duplicate check treats as an existing request.

This is the same failure shape as #3276 / #3278 (TV seasons stuck in Processing), which was fixed in #3279, but one level up, for movies and top level media, so that fix does not cover it.

Because the rows are created by a scheduled sync rather than by user action, this accumulates silently. On my install 16 rows are currently in this state, the oldest from April 2025 and the most recent batch created by a single scheduled Radarr sync on 2026-09-26.

Version

3.5.0 (commit e2f24cb)

Steps to Reproduce

  1. Request a movie in Seerr and let it be approved and sent to Radarr.
  2. Remove the movie from Radarr before it completes, so Radarr no longer tracks it.
  3. Wait for the scheduled Radarr sync to run. The orphan cleanup from fix(scanners): reset orphaned processing media from deleted Radarr/Sonarr entries #2757 resets the media row to status = 1 (UNKNOWN) but leaves externalServiceId populated and leaves the media_request at status 2 (APPROVED).
  4. Try to request the same movie again from the Seerr UI.
  5. The request fails. The log records "Duplicate request for media blocked" and the title's Status column in the UI is blank.

Confirm the row state with:

SELECT id, mediaType, tmdbId, status, externalServiceId, jellyfinMediaId, updatedAt
FROM media
WHERE status = 1 AND (externalServiceId IS NOT NULL OR jellyfinMediaId IS NOT NULL);

Logs

Label: Media Request
Severity: WARN
Message: Duplicate request for media blocked
Additional Data:
{
  "is4k": false,
  "mediaType": "movie",
  "tmdbId": 755679
}

Database state for that same title:

id   mediaType  tmdbId  status  status4k  externalServiceId  jellyfinMediaId  updatedAt
835  movie      755679  1       1         654                                 2026-09-26 18:00:54

Its attached request, left approved and unreachable:

id   status  type   mediaId  createdAt
290  2       movie  835      2026-09-26 03:47:46

All rows currently in this state on this install (16 total). Note the five created within four seconds of each other by one scheduled sync:

id   mediaType  tmdbId   status  externalServiceId  updatedAt
831  movie      1283515  1       653                2026-09-26 18:00:54
835  movie      755679   1       654                2026-09-26 18:00:54
832  movie      1003596  1       582                2026-09-26 18:00:50
833  movie      1170608  1       609                2026-09-26 18:00:50
834  movie      1300968  1       611                2026-09-26 18:00:50
830  movie      1423577  1       652                2026-09-25 18:00:54
825  tv         106308   1       40                 2026-09-05 18:30:03
822  movie      1400336  1       647                2026-09-05 18:00:54
823  movie      1384216  1       648                2026-09-05 18:00:54
595  tv         196592   1       28                 2025-07-13 04:30:02
665  movie      1507999  1       562                2025-07-06 12:28:15
592  movie      664413   1       568                2025-04-30 12:58:29
583  tv         70779    1       67                 2025-04-30 12:58:21
567  movie      1120368  1       552                2025-04-30 12:56:59
568  movie      1303553  1       554                2025-04-30 12:56:57
569  movie      1303552  1       553                2025-04-30 12:56:55

Platform

desktop

Database

SQLite (default)

Device

Server: Oracle Cloud VM, x86_64. Accessed from a desktop browser.

Operating System

Ubuntu 22.04.5 LTS, Docker, image ghcr.io/seerr-team/seerr:latest

Browser

Not browser specific. Reproduced through the API and confirmed directly in the database.

Additional Context

The only way to recover a title is to delete the media row by hand, which cascades the media_request, and restart Seerr:

PRAGMA foreign_keys=ON;
DELETE FROM media WHERE status = 1 AND (externalServiceId IS NOT NULL OR jellyfinMediaId IS NOT NULL);

That is not something a normal user can be expected to do, and it has to be repeated every few weeks because the scheduled sync keeps creating new ones.

Suggested fix, in the orphan cleanup path added by #2757: when resetting a media row to UNKNOWN, also clear externalServiceId, externalServiceId4k and jellyfinMediaId, and resolve or remove the attached media_request rather than leaving them APPROVED. Alternatively, make the duplicate check ignore a media row whose status is UNKNOWN, since such a row does not represent an available or in progress item.

Related: #3476 (this report, closed on template grounds), #2757 (the cleanup with the gap), #3276, #3278, #3279 (same shape, fixed for TV seasons).

Search Existing Issues

  • Yes, I have searched existing issues.

Code of Conduct

  • I agree to follow Seerr's Code of Conduct

Activity

  1. github-actions commented on Oct 2, 2026

    @github-actions

    Possible duplicate detected

    This issue may be a duplicate of the following (detected via semantic similarity + LLM review):

    A maintainer will review this. If this is not a duplicate, no action is needed.

  2. fallenbagel commented on Oct 2, 2026

    @fallenbagel
    Member

    Your previous report was closed on template grounds and because the analysis was wrong, and it read as raw AI output, which our policy covers:

    https://github.com/seerr-team/seerr/blob/e9590629b8215676a352ec2413d7c8ee7e6974df/CONTRIBUTING.md#ai-assistance-notice

    File the bug. Don't paste a model's analysis on top of it, because that part is almost always wrong and it adds absolutely no value. This report is the same story again where the bug is real, but the claims around it are not.

    Those rows aren't produced by the #2757 orphan cleanup. That cleanup only looks at titles missing from the scan, and it already declines the attached request. Your rows are produced by the normal scan path. An existing media in PROCESSING is flipped to UNKNOWN whenever the scanner sees the Radarr entry with no file and not monitored:

    if (existing[is4k ? 'status4k' : 'status'] !== MediaStatus.AVAILABLE) {
    const statusField = is4k ? 'status4k' : 'status';
    const previousStatus = existing[statusField];
    existing[statusField] =
    !processing && hasFile
    ? MediaStatus.AVAILABLE
    : !processing &&
    !hasFile &&
    previousStatus === MediaStatus.PROCESSING
    ? MediaStatus.UNKNOWN
    : processing
    ? previousStatus === MediaStatus.DELETED
    ? MediaStatus.DELETED
    : MediaStatus.PROCESSING
    : previousStatus;

    processing is !hasFile && monitored, so an unmonitored movie with no file satisfies both halves of that branch:

    await this.processMovie(radarrMovie.tmdbId, {
    is4k: server4k,
    serviceId: this.currentServer.id,
    externalServiceId: radarrMovie.id,
    externalServiceSlug: radarrMovie.titleSlug,
    title: radarrMovie.title,
    processing: !radarrMovie.hasFile && radarrMovie.monitored,
    hasFile: radarrMovie.hasFile,
    });

    A few lines later the same pass writes externalServiceId from that live Radarr entry, and nothing in the path touches the attached request:

    if (
    externalServiceId !== undefined &&
    existing[is4k ? 'externalServiceId4k' : 'externalServiceId'] !==
    externalServiceId
    ) {
    existing[is4k ? 'externalServiceId4k' : 'externalServiceId'] =
    externalServiceId;
    changedExisting = true;
    }

    processShow does the same per season:

    : !season.is4kOverride &&
    !season.processing &&
    season.episodes === 0 &&
    existingSeason.status === MediaStatus.PROCESSING
    ? MediaStatus.UNKNOWN
    : existingSeason.status;

    So your externalServiceId values are not stale. They are live Radarr ids, which is why the orphan cleanup never fired on these titles as they were in the scan set. Five rows written within four seconds is the library loop, not cleanup. Check GET /api/v3/movie/654 against your Radarr and it will return the movie rather than a 404.

    Two more things are wrong independent of that. The duplicate check never consults media status, so making it ignore UNKNOWN rows would change nothing, and an UNKNOWN row is already flipped back to PENDING on re-request:

    media.status === MediaStatus.DELETED) &&
    !requestBody.is4k
    ) {
    media.status = MediaStatus.PENDING;
    }
    if (
    (media.status4k === MediaStatus.UNKNOWN ||
    media.status4k === MediaStatus.DELETED) &&
    requestBody.is4k
    ) {
    media.status4k = MediaStatus.PENDING;
    }
    }

    What blocks you is purely the surviving APPROVED request:

    if (existing && existing.length > 0) {
    // If there is an existing movie request that isn't declined, don't allow a new one.
    if (
    requestBody.mediaType === MediaType.MOVIE &&
    existing[0].status !== MediaRequestStatus.DECLINED &&
    existing[0].status !== MediaRequestStatus.COMPLETED
    ) {
    logger.warn('Duplicate request for media blocked', {
    tmdbId: tmdbMedia.id,
    mediaType: requestBody.mediaType,
    is4k: requestBody.is4k,
    label: 'Media Request',
    });
    throw new DuplicateMediaRequestError(
    'Request for this media already exists.'
    );
    }

    Closing this. It's the second report filed improperly, so it still carries no type and no triage label, and it's the second one built on an AI diagnosis that points at the wrong file. The policy doesn't care who clicks submit but those are still two violations. Further reports in this shape get closed without technical review.

    The underlying bug is real and I'll track it separately. The fix is to resolve the attached request when that branch resets PROCESSING to UNKNOWN, the way declineOrphanedRequests already does.

    The database dump and the log line were the ONLY useful part here. Next time file a bug report properly in your own words following the contributing guidelines with just those and leave the root cause to us.

  3. fallenbagel commented on Oct 2, 2026

    @fallenbagel
    Member

    This is the second report filed in violation of our contributing guidelines and built on an AI diagnosis that named the wrong file and the wrong fix. Take this as a formal warning.

    The policy clearly states to not dump unreviewed model output, and to write the issue in your own words.

    https://github.com/seerr-team/seerr/blob/e9590629b8215676a352ec2413d7c8ee7e6974df/CONTRIBUTING.md#ai-assistance-notice

    We don't need a middle man relaying a model's output to us. It costs us time rather than saving it, which is exactly what the wrong claims here did. The logs and the database dump were the only useful part of this report, and they would have been enough on their own. If writing it up yourself wasn't worth five minutes of your time, think about why unpicking it should be worth an hour of ours.

    Next report in this shape gets closed without technical review, and per our contributing guidelines repeated unreviewed AI output can result in a ban, whether or not the bug reported is real. There was one real bug here, and it took that hour to find past the hallucinated diagnosis you attached.

    The bug is tracked properly in #3577 with the actual cause. You can subscribe to that issue. Closing this as superseded.

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions