MCPcopy Create free account
hub / github.com/aws/aws-cli / PutObjectTask

Class PutObjectTask

awscli/s3transfer/upload.py:787–800  ·  view source on GitHub ↗

Task to do a nonmultipart upload

Source from the content-addressed store, hash-verified

785
786
787class PutObjectTask(Task):
788 """Task to do a nonmultipart upload"""
789
790 def _main(self, client, fileobj, bucket, key, extra_args):
791 """
792 :param client: The client to use when calling PutObject
793 :param fileobj: The file to upload.
794 :param bucket: The name of the bucket to upload to
795 :param key: The name of the key to upload to
796 :param extra_args: A dictionary of any extra arguments that may be
797 used in the upload.
798 """
799 with fileobj as body:
800 client.put_object(Bucket=bucket, Key=key, Body=body, **extra_args)
801
802
803class UploadPartTask(Task):

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected