Skip to content

Commit

Permalink
[patch] Cleanup on startup
Browse files Browse the repository at this point in the history
  • Loading branch information
Feramance committed Oct 23, 2023
1 parent 5b2a834 commit 6fdb677
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions qBitrr/arss.py
Original file line number Diff line number Diff line change
Expand Up @@ -707,7 +707,7 @@ def _get_ombi_request_count(self) -> int:
elif self.type == "radarr":
extras = "/api/v1/Request/movie/total"
else:
raise UnhandledError("Well you shouldn't have reached here, Arr.type=%s" % self.type)
raise UnhandledError(f"Well you shouldn't have reached here, Arr.type={self.type}")
try:
response = self.session.get(
url=f"{self.ombi_uri}{extras}", headers={"ApiKey": self.ombi_api_key}
Expand All @@ -724,7 +724,7 @@ def _get_ombi_requests(self) -> list[dict]:
elif self.type == "radarr":
extras = "/api/v1/Request/movie"
else:
raise UnhandledError("Well you shouldn't have reached here, Arr.type=%s" % self.type)
raise UnhandledError(f"Well you shouldn't have reached here, Arr.type={self.type}")
try:
response = self.session.get(
url=f"{self.ombi_uri}{extras}", headers={"ApiKey": self.ombi_api_key}
Expand Down
1 change: 1 addition & 0 deletions qBitrr/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ def cleanup():

if __name__ == "__main__":
freeze_support()
cleanup()
run()
delay = os.getenv("RESTART_TIMER", 0)
if delay != 0:
Expand Down

0 comments on commit 6fdb677

Please sign in to comment.