def _close_writable(self):
        """
        Close the object in write mode.
        """
        # Wait parts upload completion
        for part in self._write_futures:
            part['ETag'] = part.pop('response').result()['ETag']

        # Complete multipart upload
        with _handle_client_error():
            try:
                self._client.complete_multipart_upload(
                    MultipartUpload={'Parts': self._write_futures},
                    UploadId=self._upload_args['UploadId'],
                    **self._client_kwargs)
            except _ClientError:
                # Clean up if failure
                self._client.abort_multipart_upload(
                    UploadId=self._upload_args['UploadId'],
                    **self._client_kwargs)
                raise
def _close_writable ( self ) : for part in self . _write_futures : part [ 'ETag' ] = part . pop ( 'response' ) . result ( ) [ 'ETag' ] with _handle_client_error ( ) : try : self . _client . complete_multipart_upload ( MultipartUpload = { 'Parts' : self . _write_futures } , UploadId = self . _upload_args [ 'UploadId' ] , ** self . _client_kwargs ) except _ClientError : self . _client . abort_multipart_upload ( UploadId = self . _upload_args [ 'UploadId' ] , ** self . _client_kwargs ) raise
Close the object in write mode.