'Return a folder hierarchy containing invalid repository dependencies.'

def build_invalid_repository_dependencies_root_folder(self, folder_id, invalid_repository_dependencies_dict):

    label = 'Invalid    repository    dependencies'
    if invalid_repository_dependencies_dict:
        invalid_repository_dependency_id = 0
        folder_id += 1
        invalid_repository_dependencies_root_folder = utility_container_manager.Folder(id=folder_id, key='root', label='root', parent=None)
        folder_id += 1
        invalid_repository_dependencies_folder = utility_container_manager.Folder(id=folder_id, key='invalid_repository_dependencies', label=label, parent=invalid_repository_dependencies_root_folder)
        invalid_repository_dependencies_root_folder.folders.append(invalid_repository_dependencies_folder)
        invalid_repository_dependencies = invalid_repository_dependencies_dict['repository_dependencies']
        for invalid_repository_dependency in invalid_repository_dependencies:
            folder_id += 1
            invalid_repository_dependency_id += 1
            (toolshed, name, owner, changeset_revision, prior_installation_required, only_if_compiling_contained_td, error) = common_util.parse_repository_dependency_tuple(invalid_repository_dependency, contains_error=True)
            key = container_util.generate_repository_dependencies_key_for_repository(toolshed, name, owner, changeset_revision, prior_installation_required, only_if_compiling_contained_td)
            label = ('Repository    <b>%s</b>    revision    <b>%s</b>    owned    by    <b>%s</b>' % (name, changeset_revision, owner))
            folder = utility_container_manager.Folder(id=folder_id, key=key, label=label, parent=invalid_repository_dependencies_folder)
            ird = InvalidRepositoryDependency(id=invalid_repository_dependency_id, toolshed=toolshed, repository_name=name, repository_owner=owner, changeset_revision=changeset_revision, prior_installation_required=util.asbool(prior_installation_required), only_if_compiling_contained_td=util.asbool(only_if_compiling_contained_td), error=error)
            folder.invalid_repository_dependencies.append(ird)
            invalid_repository_dependencies_folder.folders.append(folder)
    else:
        invalid_repository_dependencies_root_folder = None
    return (folder_id, invalid_repository_dependencies_root_folder)
