  
  @python_2_unicode_compatible
  class StumpJoke(models.Model):
      variation = models.CharField(max_length=100)
      most_recently_fooled = models.ForeignKey(Character, limit_choices_to=today_callable_dict, related_name="+")
      has_fooled_today = models.ManyToManyField(Character, limit_choices_to=today_callable_q, related_name="+")
  
      def __str__(self):
          return self.variation
  
 
</s> remove     poet = models.ForeignKey(Poet)
 </s> add     poet = models.ForeignKey(Poet, models.CASCADE) </s> remove     plot = models.OneToOneField(Plot)
 </s> add     plot = models.OneToOneField(Plot, models.CASCADE) </s> remove     poet = models.ForeignKey(Poet)
 </s> add     poet = models.ForeignKey(Poet, models.CASCADE) </s> remove     author = models.ForeignKey(Author)
 </s> add     author = models.ForeignKey(Author, models.CASCADE) </s> remove     department = models.ForeignKey(Department, to_field="code")
 </s> add     department = models.ForeignKey(Department, models.CASCADE, to_field="code")
    most_recently_fooled = models.ForeignKey(
        Character,
        models.CASCADE,
        limit_choices_to=today_callable_dict,
        related_name="+",
    )
  
  @python_2_unicode_compatible
  class StumpJoke(models.Model):
      variation = models.CharField(max_length=100)
    most_recently_fooled = models.ForeignKey(
        Character,
        models.CASCADE,
        limit_choices_to=today_callable_dict,
        related_name="+",
    )
      has_fooled_today = models.ManyToManyField(Character, limit_choices_to=today_callable_q, related_name="+")
  
      def __str__(self):
          return self.variation
  
keep keep keep keep replace keep keep keep keep keep
 Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField 
tests/admin_views/models.py