From: Harmon Date: Fri, 19 Feb 2021 16:46:17 +0000 (-0600) Subject: Stop allowing positional arguments for API.chunked_upload X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=cf3f513c6617927a9511a9d1aa5f9eef44e51bb5;p=tweepy.git Stop allowing positional arguments for API.chunked_upload Stop allowing positional arguments besides filename for API.chunked_upload --- diff --git a/tweepy/api.py b/tweepy/api.py index 801b5ad..d18c331 100644 --- a/tweepy/api.py +++ b/tweepy/api.py @@ -349,7 +349,7 @@ class API: file_type = mimetypes.guess_type(filename)[0] if chunked or file_type.startswith('video/'): - return self.chunked_upload(filename, *args, file=file, + return self.chunked_upload(filename, file=file, file_type=file_type, **kwargs) else: return self.simple_upload(filename, file=file, **kwargs) @@ -375,7 +375,7 @@ class API: upload_api=True, **kwargs ) - def chunked_upload(self, filename, *args, file=None, file_type=None, + def chunked_upload(self, filename, *, file=None, file_type=None, media_category=None, additional_owners=None, **kwargs): """ :reference https://developer.twitter.com/en/docs/media/upload-media/uploading-media/chunked-media-upload """