def trigger_build(project, version=None, record=True, force=False, basic=False):
    '\n    An API to wrap the triggering of a build.\n    '
    from readthedocs.projects.tasks import update_docs
    if project.skip:
        return None
    if (not version):
        version = project.versions.get(slug=LATEST)
    if record:
        build = Build.objects.create(project=project, version=version, type='html', state='triggered', success=True)
        update_docs.delay(pk=project.pk, version_pk=version.pk, record=record, force=force, basic=basic, build_pk=build.pk)
    else:
        build = None
        update_docs.delay(pk=project.pk, version_pk=version.pk, record=record, force=force, basic=basic)
    return build
An API to wrap the triggering of a build.
def trigger_build(project, version=None, record=True, force=False, basic=False):
    '\n    \n    '
    from readthedocs.projects.tasks import update_docs
    if project.skip:
        return None
    if (not version):
        version = project.versions.get(slug=LATEST)
    if record:
        build = Build.objects.create(project=project, version=version, type='html', state='triggered', success=True)
        update_docs.delay(pk=project.pk, version_pk=version.pk, record=record, force=force, basic=basic, build_pk=build.pk)
    else:
        build = None
        update_docs.delay(pk=project.pk, version_pk=version.pk, record=record, force=force, basic=basic)
    return build