def _delete_s3(self, filename, bucket_name):
conn = S3Connection(self.access_key_id, self.access_key_secret)<EOL>bucket = conn.get_bucket(bucket_name)<EOL>if type(filename).__name__ == '<STR_LIT>':<EOL><INDENT>filename = '<STR_LIT:/>' + filename.name<EOL><DEDENT>path = self._get_s3_path(filename)<EOL>k = Key(bucket)<EOL>k.key = path<EOL>try:<EOL><INDENT>bucket.delete_key(k)<EOL><DEDENT>except S3ResponseError:<EOL><INDENT>pass<EOL><DEDENT>
Deletes the specified file from the given S3 bucket.