Sonarr Scan fails
See original GitHub issueThought it was because of the pip install of excludarr, but went with the docker image to make sure it wasn’t a dependency issue.
When I run the job, I get the following error:
|> excludarr <| / #excludarr sonarr exclude -a not-monitored --progress Working… ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100% 0:00:00 Traceback (most recent call last): File “/usr/local/bin/excludarr”, line 33, in <module> sys.exit(load_entry_point(‘excludarr==1.0.6’, ‘console_scripts’, ‘excludarr’)()) File “/usr/local/lib/python3.10/site-packages/excludarr-1.0.6-py3.10.egg/excludarr/main.py”, line 68, in cli File “/usr/local/lib/python3.10/site-packages/typer/main.py”, line 214, in call return get_command(self)(*args, **kwargs) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1128, in call return self.main(*args, **kwargs) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1053, in main rv = self.invoke(ctx) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1395, in invoke return ctx.invoke(self.callback, **ctx.params) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 754, in invoke return __callback(*args, **kwargs) File “/usr/local/lib/python3.10/site-packages/typer/main.py”, line 500, in wrapper return callback(**use_params) # type: ignore File “/usr/local/lib/python3.10/site-packages/excludarr-1.0.6-py3.10.egg/excludarr/commands/sonarr.py”, line 69, in exclude File “/usr/local/lib/python3.10/site-packages/excludarr-1.0.6-py3.10.egg/excludarr/core/sonarr_actions.py”, line 281, in get_series_to_exclude KeyError: ‘statistics’ |> excludarr <| / #
To Reproduce Steps to reproduce the behavior:
-
The exact command that throws an error excludarr sonarr exclude -a not-monitored --progress
-
The name of the movie or serie that is being processed at the time of the error (if applicable) initial scan, so unknown.
-
The settings file used (strip it from sensitive data)
Expected behavior A clear and concise description of what you expected to happen.
I expect it to complete the scan and present a menus
Debug logging
To debug the problem further, we need to know exactly what went wrong. Therefor we ask you to run the command in debug mode. You can achieve this by appending the --debug
flag after the base command excludarr
. e.g. excludarr --debug sonarr exclude -a delete -d -e
.
|> excludarr <| / #excludarr --debug sonarr exclude -a not-monitored --progress [2022-01-25 18:59:13] - Starting Excludarr v1.0.6 [2022-01-25 18:59:13] - Got sonarr as subcommand [2022-01-25 18:59:13] - Reading configuration file [2022-01-25 18:59:13] - Determining which configfile to use [2022-01-25 18:59:13] - Configfile to use: /etc/excludarr/excludarr.yml [2022-01-25 18:59:13] - Reading configfile: /etc/excludarr/excludarr.yml [2022-01-25 18:59:13] - Read the following configuration: {‘general’: {‘fast_search’: True, ‘locale’: ‘en_US’, ‘providers’: [‘netflix’, ‘amazon prime video’]}, ‘radarr’: {‘url’: ‘http://radarr:7878’, ‘api_key’: ‘<REDACTED>’, ‘verify_ssl’: False, ‘exclude’: [‘’]}, ‘sonarr’: {‘url’: ‘http://sonarr:8989’, ‘api_key’: ‘<REDACTED>’, ‘verify_ssl’: False, ‘exclude’: [‘’]}} [2022-01-25 18:59:13] - Got exclude as subcommand [2022-01-25 18:59:13] - Got CLI values for -p, --provider option: [2022-01-25 18:59:13] - Got CLI values for -l, --locale option: None [2022-01-25 18:59:13] - Got CLI values for -a, --action option: not-monitored [2022-01-25 18:59:13] - Got CLI values for -d, --delete option: False [2022-01-25 18:59:13] - Got CLI values for -e, --exclusion option: False [2022-01-25 18:59:13] - Got CLI values for -y, --yes option: False [2022-01-25 18:59:13] - Got CLI values for --progress option: True [2022-01-25 18:59:13] - Initializing PySonarr [2022-01-25 18:59:13] - Initializing JustWatch API with locale: en_US [2022-01-25 18:59:16] - Getting all the series from Sonarr [2022-01-25 18:59:34] - Got the following providers: Netflix, Amazon Prime Video
<lots of show data>Traceback (most recent call last): File “/usr/local/bin/excludarr”, line 33, in <module> sys.exit(load_entry_point(‘excludarr==1.0.6’, ‘console_scripts’, ‘excludarr’)()) File “/usr/local/lib/python3.10/site-packages/excludarr-1.0.6-py3.10.egg/excludarr/main.py”, line 68, in cli File “/usr/local/lib/python3.10/site-packages/typer/main.py”, line 214, in call return get_command(self)(*args, **kwargs) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1128, in call return self.main(*args, **kwargs) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1053, in main rv = self.invoke(ctx) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1659, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 1395, in invoke return ctx.invoke(self.callback, **ctx.params) File “/usr/local/lib/python3.10/site-packages/click/core.py”, line 754, in invoke return __callback(*args, **kwargs) File “/usr/local/lib/python3.10/site-packages/typer/main.py”, line 500, in wrapper return callback(**use_params) # type: ignore File “/usr/local/lib/python3.10/site-packages/excludarr-1.0.6-py3.10.egg/excludarr/commands/sonarr.py”, line 69, in exclude File “/usr/local/lib/python3.10/site-packages/excludarr-1.0.6-py3.10.egg/excludarr/core/sonarr_actions.py”, line 281, in get_series_to_exclude KeyError: ‘statistics’
Issue Analytics
- State:
- Created 2 years ago
- Comments:12 (5 by maintainers)
Great! Fine that it worked out. It seems that Excludarr crashed because Sonarr was not responding properly on getting the information about an episode. This was probably caused by overloading Sonarr with API calls. You said you had a few hundred shows in your library? Maybe that was causing issues with requesting all those information in such short time.
I will try to add a delay between the retries it does when encountering an error requested via the API of Sonarr. This will give Sonarr the time to breathe for a while without causing issues in Excludarr.
Great to hear it all worked out! I will increase the retry delay in the next version!