#NEWLINE# def get_bucket( conn , bucket_id ) : #NEWLINE# #INDENT# '\n    Get a bucket from an s3 connection\n\n    :param conn: The ``boto.s3.connection.S3Connection``\n    :param bucket_id: ID of the bucket to fetch\n    :raises: ``glance_store.exceptions.NotFound`` if bucket is not found.\n    ' #NEWLINE# bucket = conn . get_bucket ( bucket_id ) #NEWLINE# if ( not bucket ) : #NEWLINE# #INDENT# msg = ( _ ( 'Could not find bucket with ID %s' ) % bucket_id ) #NEWLINE# LOG . debug ( conn ) #NEWLINE# raise exceptions . NotFound ( msg ) #NEWLINE# #UNINDENT# return bucket