RandomNinjaAtk / docker-sonarr-extended

Sonarr (develop) with bash scripts to automate and extend functionality.
GNU General Public License v3.0
66 stars 15 forks source link

Changing the number of episodes kept #37

Closed RogueGhost93 closed 1 year ago

RogueGhost93 commented 1 year ago

If i were to change the number of episodes to lets say 7 would this be all i need to change?

f [ $seriesEpisodeIdsCount -lt 14 ]; then if [ $processId -gt 14 ]; then

those are the only lines in the script that contain number 14 as far as i can tell. Thanks!

EDIT: I tried editing it and every time the sonnar gets restarted and script re-ran the file edits itself back to 14 days.

RandomNinjaAtk commented 1 year ago

There isn't a way to change it.

RandomNinjaAtk commented 1 year ago

Should be resolved with the latest changes. Add this container ENV "maximumDailyEpisodes", see readme.

RogueGhost93 commented 1 year ago

my logs are still generating "Series has not exceeded 14 downloaded episodes (3 files found), skipping.." even though i had put maximumDailyEpisodes=7

Also, im not sure why but out of 8 daily shows that i have only 2 are showing up in logs, 3 of them are not mentioned anywhere. Permissions are correct and they do have only 14 last episodes and the script was working properly up until now. (edit: this made me check little deepeer and i realized a good portion of standard shows are also not showing up in logs as skipped, im assuming around 20%, i have around 430 shows so could it be too many for it or something? could it be that the log file is too large and not complete?

RandomNinjaAtk commented 1 year ago

The 14 is just a bug in the logging, you can see from the latest commit...

As for the log file, it does prevent it from getting too big, but you should get at least one complete run in the log file. However, when the next script run starts. It may purge the log file because it was too big. You might just always be checking the log file mid processing, hence your not seeing the full picture. If you have the log file open in browser. My suggestion is to refresh the page to see it's still printing output...

I have not tested these changes, but everything should be resolved with this issue.

RogueGhost93 commented 1 year ago

Yea but those shows that are missing from logs are still having 14 episodes instead of 7 kept....will see over next few updates i guess

RandomNinjaAtk commented 1 year ago

The script only processes the series when the series imports new episodes. So you have to wait for a new download before it will cleanup the old ones...