from django.db.models.signals import post_save
from django.dispatch import receiver
from mrbelvedereci.build.tasks import check_queued_build

@receiver(post_save, sender=Build)
def queue_build(sender, **kwargs):
    build = kwargs['instance']
    created = kwargs['created']
    if not created:
        return

    check_queued_build(build.id)

from django.db.models.signals import post_save
from django.dispatch import receiver
from mrbelvedereci.build.models import Build
from mrbelvedereci.build.tasks import check_queued_build

@receiver(post_save, sender=Build)
def queue_build(sender, **kwargs):
    build = kwargs['instance']
    created = kwargs['created']
    if not created:
        return

    check_queued_build(build.id)

Fix import