solumclient/common/base.py
def findone(self, **kwargs):
        """Find a single item with attributes matching ``**kwargs``.

        This isn't very efficient: it loads the entire list then filters on
        the Python side.
        """
        matches = self.findall(**kwargs)
        num_matches = len(matches)
        if num_matches == 0:
            msg = "No %s matching %s." % (self.resource_class.__name__, kwargs)
            raise exceptions.NotFound(msg)
        elif num_matches > 1:
            raise exceptions.NoUniqueMatch()
        else:
            return matches[0]
Find a single item with attributes matching ``**kwargs``.

        This isn't very efficient: it loads the entire list then filters on
        the Python side.
        
Find a single item with attributes matching ``**kwargs``.
This isn't very efficient: it loads the entire list then filters on
the Python side.
Find a single item with attributes matching ` ` ** kwargs ` ` . This isn ' t very efficient : it loads the entire list then filters on the Python side .
def findone(self, **kwargs):
        matches = self.findall(**kwargs)
        num_matches = len(matches)
        if num_matches == 0:
            msg = "No %s matching %s." % (self.resource_class.__name__, kwargs)
            raise exceptions.NotFound(msg)
        elif num_matches > 1:
            raise exceptions.NoUniqueMatch()
        else:
            return matches[0]
def findone ( self , ** kwargs ) : matches = self . findall ( ** kwargs ) num_matches = len ( matches ) if num_matches == 0 : msg = "No %s matching %s." % ( self . resource_class . __name__ , kwargs ) raise exceptions . NotFound ( msg ) elif num_matches > 1 : raise exceptions . NoUniqueMatch ( ) else : return matches [ 0 ]
Find a single item with attributes matching ``**kwargs``.
Find a single item with attributes matching ` ` ** kwargs ` ` .
"""Find a single item with attributes matching ``**kwargs``.

        This isn't very efficient: it loads the entire list then filters on
        the Python side.
        """
self