code: def by_name(cls, session, name):
          
          return cls.first(session, where=(cls.name == name,))
docs: Get a package from a given name.
  
          :param session: SQLAlchemy session
          :type session: :class:`sqlalchemy.Session`
  
          :param name: name of the group
          :type name: `unicode
  
          :return: package instance
          :rtype: :class:`pyshop.models.Group`