whatdaybob / sonarr_youtubedl

A Sonarr companion script to allow the automatic downloading of web series normally not available for Sonarr to search for. Using Youtube-DL it allows you to download your webseries from the list of supported sites.
107 stars 34 forks source link

Update api for Sonarr v4 #46

Closed Yankees4life closed 1 year ago

Yankees4life commented 1 year ago

Updated the api urls for support for v4 as v4 as deprecated the v1 api.

Yankees4life commented 1 year ago

I tested it out and it runs fine.

dotneB commented 1 year ago

I'm getting

2023-01-26 23:26:11,101 - sonarr_youtubedl - DEBUG - Begin call Sonarr to rescan for series_id: 192 2023-01-26 23:26:11,101 - sonarr_youtubedl - ERROR - Failed - Ominous Lectures - Replacement index 1 out of range for positional args tuple

Seems to be comming from these lines from @whatdaybob's commits 0bb9f32ec348769d3f03a4bb8ae1d101f529559f

res = self.request_put(
            "{}/{}/command".format(self.base_url),
            None, 
            self.sonarr_api_version,
            data
        )

should be

res = self.request_put(
            "{}/{}/command".format(self.base_url, self.sonarr_api_version),
            None,
            data
        )
whatdaybob commented 1 year ago

I will fix this as soon as I have some free time unless someone can pull request it and I'll be happy to review.