Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sonarr errors pulling shows #546

Closed
bulfinch opened this issue Oct 23, 2023 · 6 comments · Fixed by #548
Closed

Sonarr errors pulling shows #546

bulfinch opened this issue Oct 23, 2023 · 6 comments · Fixed by #548
Assignees
Labels
bug Something isn't working released

Comments

@bulfinch
Copy link

bulfinch commented Oct 23, 2023

Describe the bug
When creating a rule which has a value that pulls information from Sonarr. That interaction with Sonarr returns an error for some shows.
This is seen in the logs as

[Nest] 124 - WARN [SonarrApi] Error retrieving show by tvdb ID
[Nest] 124 - WARN [SonarrApi] Object:
{
"label": "Sonarr",
"errorMessage": "Request failed with status code 400",
"tvdbId": null
}

To Reproduce
Steps to reproduce the behavior:

  1. Create a rule which users Sonarr for a first value.
  2. Here I created Sonarr - tags show, but the problem is with any sonarr rule.
  3. Run Rule

Expected behavior
The error is somewhat obvious, "Error retrieving show" but it doesn't identify which show it is. This prevents an accurate running of the rule.

Screenshots
image

image

Device (please complete the following information):

  • ubuntu 22.04 LTS
  • Maintainer Docker latest tag
  • Sonarr 4.0.0.697develop (docker)

As this rule is run, Maintainerr returns 66 shows, but there are 82 shows that have this tag. "local"

@jorenn92
Copy link
Owner

Hi, thank you for this report!.

When Maintainerr checks a Sonarr / Radarr rule value, it has to first fetch the tmdb / tvdb ID. Mostly, this is available in the Plex response. But for some shows, Plex doesn't have these IDs. When that happens, there are a few fallback mechanisms to still find the tvdbid for the show. We need this ID, because we can't query the Sonarr api without it.

These fallback mechanisms appear to have failed for 16 of your shows.
Could you give me 2 or 3 example shows that failed? These are good cases to toughen this fallback system.

@jorenn92 jorenn92 added the bug Something isn't working label Oct 24, 2023
@jorenn92 jorenn92 self-assigned this Oct 24, 2023
@bulfinch
Copy link
Author

Thanks for the response. Here are some of the shows.

Twisted Metal (2023) https://thetvdb.com/series/twisted-metal
Under the Queen's Umbrella (2023) https://thetvdb.com/series/under-the-queens-umbrella
Halfway Home (2007) https://thetvdb.com/series/halfway-home
Domina (2021) https://thetvdb.com/series/domina
One Piece (2023) https://thetvdb.com/series/one-piece-2022

jorenn92 added a commit that referenced this issue Oct 24, 2023
@jorenn92 jorenn92 linked a pull request Oct 24, 2023 that will close this issue
@jorenn92
Copy link
Owner

jorenn92 commented Oct 24, 2023

Thanks for the response. Here are some of the shows.

Twisted Metal (2023) https://thetvdb.com/series/twisted-metal Under the Queen's Umbrella (2023) https://thetvdb.com/series/under-the-queens-umbrella Halfway Home (2007) https://thetvdb.com/series/halfway-home Domina (2021) https://thetvdb.com/series/domina One Piece (2023) https://thetvdb.com/series/one-piece-2022

Thanks!

I've been trying to replicate this, but unfortunately i don't see the same behavior.
I added both 'Domina' & 'One Piece' to my server, and both got a tvdb ID in the Plex API response when running Maintainerr.

My theory is that Plex servers don't update their metadata that often and will include the data that was available when the show was added. The tvdb ID was probably missing when you added it to your Plex instance. This is just a guess, though, I'm not sure how it works exactly.

I added some extra fallback logic, so hopefully that's enough to catch this case. I also improved the logs a bit, when this happens you should now see the name of the show that failed.

It would be a huge help if you could report the result after the next release. Thanks in advance!

@jorenn92
Copy link
Owner

🎉 This issue has been resolved in version 1.6.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@bulfinch
Copy link
Author

bulfinch commented Nov 2, 2023

Thanks for the response. Here are some of the shows.
Twisted Metal (2023) https://thetvdb.com/series/twisted-metal Under the Queen's Umbrella (2023) https://thetvdb.com/series/under-the-queens-umbrella Halfway Home (2007) https://thetvdb.com/series/halfway-home Domina (2021) https://thetvdb.com/series/domina One Piece (2023) https://thetvdb.com/series/one-piece-2022

Thanks!

I've been trying to replicate this, but unfortunately i don't see the same behavior. I added both 'Domina' & 'One Piece' to my server, and both got a tvdb ID in the Plex API response when running Maintainerr.

My theory is that Plex servers don't update their metadata that often and will include the data that was available when the show was added. The tvdb ID was probably missing when you added it to your Plex instance. This is just a guess, though, I'm not sure how it works exactly.

I added some extra fallback logic, so hopefully that's enough to catch this case. I also improved the logs a bit, when this happens you should now see the name of the show that failed.

It would be a huge help if you could report the result after the next release. Thanks in advance!

Wanted to report back that this looks good. The error returns as tvdb id. The one error i have now was the result of a mismatched show. A show named Anna was a 2022 show in sonarr but a different Anna (2021) in Plex.

@jorenn92
Copy link
Owner

jorenn92 commented Nov 2, 2023

Thanks for the response. Here are some of the shows.
Twisted Metal (2023) https://thetvdb.com/series/twisted-metal Under the Queen's Umbrella (2023) https://thetvdb.com/series/under-the-queens-umbrella Halfway Home (2007) https://thetvdb.com/series/halfway-home Domina (2021) https://thetvdb.com/series/domina One Piece (2023) https://thetvdb.com/series/one-piece-2022

Thanks!
I've been trying to replicate this, but unfortunately i don't see the same behavior. I added both 'Domina' & 'One Piece' to my server, and both got a tvdb ID in the Plex API response when running Maintainerr.
My theory is that Plex servers don't update their metadata that often and will include the data that was available when the show was added. The tvdb ID was probably missing when you added it to your Plex instance. This is just a guess, though, I'm not sure how it works exactly.
I added some extra fallback logic, so hopefully that's enough to catch this case. I also improved the logs a bit, when this happens you should now see the name of the show that failed.
It would be a huge help if you could report the result after the next release. Thanks in advance!

Wanted to report back that this looks good. The error returns as tvdb id. The one error i have now was the result of a mismatched show. A show named Anna was a 2022 show in sonarr but a different Anna (2021) in Plex.

Thanks for the feedback! I’ll close this issue. If you run into anything else, feel free to open a new issue / discussion.

@jorenn92 jorenn92 closed this as completed Nov 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants