@receiver(models.signals.pre_save, sender=Article)
def update_date(instance, **kwargs):
    if not instance.status == instance.old_status == Article.PUBLISHED:
        instance.date = now()
This is called from the package entry point.
dataset/ETHPy150Open 2buntu/2buntu-blog/twobuntu/articles/models.py/update_date--crossover with--dataset/ETHPy150Open google/grr/grr/tools/run_tests.py/DistEntry