From: Harmon Date: Fri, 19 Feb 2021 17:17:02 +0000 (-0600) Subject: Stop allowing positional arguments for API.update_profile_banner X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=1ca22be0cbb0a4f3aba00b37263ac92149eceb1c;p=tweepy.git Stop allowing positional arguments for API.update_profile_banner Stop allowing positional arguments besides filename for API.update_profile_banner --- diff --git a/tweepy/api.py b/tweepy/api.py index 7eb16cd..33b506c 100644 --- a/tweepy/api.py +++ b/tweepy/api.py @@ -836,7 +836,7 @@ class API: ), files=files, **kwargs ) - def update_profile_banner(self, filename, *args, file=None, **kwargs): + def update_profile_banner(self, filename, *, file=None, **kwargs): """ :reference: https://developer.twitter.com/en/docs/accounts-and-users/manage-account-settings/api-reference/post-account-update_profile_banner """ if file is not None: @@ -844,8 +844,7 @@ class API: else: files = {'banner': open(filename, 'rb')} return self.request( - 'POST', 'account/update_profile_banner', *args, - endpoint_parameters=( + 'POST', 'account/update_profile_banner', endpoint_parameters=( 'width', 'height', 'offset_left', 'offset_right' ), files=files, **kwargs )