def write_content()

in src/s3_helper.py [0:0]


    def write_content(self, path: str, content: Union[str, bytes]):
        """
        Write the provided content to the given s3 path.

        :param path: S3 path to write to.
        :param content: content to write
        """
        content_bytes = content if type(content) == bytes else content.encode('utf-8')
        bucket, key = S3Client.bucket_key_from_s3_uri(path)

        self.s3_client.upload_fileobj(io.BytesIO(content_bytes), bucket, key)
        print(f'Uploaded data to {path}')