'Eliminate all invalid entries in the received repository_dependencies dictionary.  An entry
is invalid if the value_list of the key/value pair is empty.  This occurs when an invalid
combination of tool shed, name , owner, changeset_revision is used and a repository_metadata
record is not found.'

def prune_invalid_repository_dependencies(self, repository_dependencies):

    valid_repository_dependencies = {}
    description = repository_dependencies.get('description', None)
    root_key = repository_dependencies.get('root_key', None)
    if (root_key is None):
        return valid_repository_dependencies
    for (key, value) in repository_dependencies.items():
        if (key in ['description', 'root_key']):
            continue
        if value:
            valid_repository_dependencies[key] = value
    if valid_repository_dependencies:
        valid_repository_dependencies['description'] = description
        valid_repository_dependencies['root_key'] = root_key
    return valid_repository_dependencies
