from django.db.models.signals import pre_save
from django.dispatch import receiver
from polls.models import Question

from polls.signals.senders import custom_signal

@receiver(pre_save, sender=Question)
def my_handler(sender, **kwargs):
  print("pre_save handler called")

@receiver(custom_signal)
def my_custom_handler(sender, **kwargs):
  print("custom_handler called")
21bfbe259d8f5bd948493d35a1de4781dff9120b
<mask token>

<mask token>


@receiver(custom_signal)
def my_custom_handler(sender, **kwargs):
    print('custom_handler called')

<mask token>


@receiver(pre_save, sender=Question)
def my_handler(sender, **kwargs):
    print('pre_save handler called')


@receiver(custom_signal)
def my_custom_handler(sender, **kwargs):
    print('custom_handler called')

from django.db.models.signals import pre_save
from django.dispatch import receiver
from polls.models import Question
from polls.signals.senders import custom_signal


@receiver(pre_save, sender=Question)
def my_handler(sender, **kwargs):
    print('pre_save handler called')


@receiver(custom_signal)
def my_custom_handler(sender, **kwargs):
    print('custom_handler called')

from django.db.models.signals import pre_save
from django.dispatch import receiver
from polls.models import Question

from polls.signals.senders import custom_signal

@receiver(pre_save, sender=Question)
def my_handler(sender, **kwargs):
  print("pre_save handler called")

@receiver(custom_signal)
def my_custom_handler(sender, **kwargs):
  print("custom_handler called")