Skip to content

Add qualityProfiles, tags, seasonSelection, delete command, configTextIdentifiers, admin option for sonarr/radarr, allowlist and minor fixes#110

Merged
Waterboy1602 merged 15 commits intoWaterboy1602:masterfrom
anast20sm:add_New_Options_and_Change_Flow
Feb 26, 2022
Merged

Conversation

@anast20sm
Copy link
Contributor

@anast20sm anast20sm commented Feb 20, 2022

Changes:

  • Changed messages flow. Once something is selected it is replaced with the new selection. (I found it chaotic how many messages were left after adding a single movie/series)
  • Added delete command
  • Added the capability to select quality profiles by name on Sonarr and Radarr (and possibility to exclude some of them)
  • Added the capability to select which seasons to add on Sonarr
  • Added the capability to define default tags and default language by name on config
  • Changed config integer identifiers to string identifiers
  • Added option to restrict series/movies list and delete to admin
  • Allowlist option to define an allowlist by usernames/ids (more secure, but take in mind that is very restrictive)
  • Other minor fixes

All modifications were done following the already written code format.

These changes should fix the following open issues:
#16
#35
#49
#75
#85
#87
#92
#105

@anast20sm anast20sm changed the title Add qualityProfiles, tags, seasonSelection, configTextIdentifiers, listOnlyAdmins, Allowlist and minor fixes Add qualityProfiles, tags, seasonSelection, delete command, configTextIdentifiers, admin option for sonarr/radarr, allowlist and minor fixes Feb 20, 2022
@Waterboy1602
Copy link
Owner

Thank you a lot for all the new features! I'm testing the new code, but found a bug when trying to add a TV show that already exists. I get this error:

 File "[...]\addarr\addarr.py", line 640, in addSerieMovie
    selectedSeasons = [int(s) for s in context.user_data["seasons"] if int(s) >= int(try_fromSeason)]
KeyError: 'seasons'

I haven't yet found how to fix this bug, but I think it's best to first fix this bug before merging.

@anast20sm
Copy link
Contributor Author

Hi @Waterboy1602 , I'm not able to reproduce the bug. Could you please let me know which series were you adding? I tried with 1 season series, 1+specials series and 21 season series and they worked.

@Waterboy1602
Copy link
Owner

I've found the bug that created KeyError: 'seasons'. I've also found another bug that prevented to select Execute a new search command when you were at the step of Is this a movie or a series? and fixed it with my latest commit.

Now after some extra digging into all the commands, I've experienced some problems with the commands /Movie and /Series. They give the following error when executed:

addarr\addarr.py", line 404, in searchSerieMovie
    message_id=context.user_data["update_msg"],
KeyError: 'update_msg'

When I find some extra time, I'll look into fixing this.

@anast20sm
Copy link
Contributor Author

Fixed, it was a gap on the new flow. It used the messageId of choiceMovieSeries's message for future messages, but when using /series or /movie this message was skipped and then didn't find the messageId to edit. Thanks for advising!

@Waterboy1602
Copy link
Owner

I felt like the /delete commando needed an extra confirmation before effectively deleting the movie/series. So I've added this with my latest commit to this PR.

Now I feel like this PR is ready to be merged. Thank you for all your effort and work! I'll make a new tag (V0.6) when I've cleaned up the code and added some new features that I'm developing at the moment.

@Waterboy1602 Waterboy1602 merged commit 39282b0 into Waterboy1602:master Feb 26, 2022
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