django/django — pull request #642 by dcramer (2013-01-11 22:54:53+00:00)
Title: Send post_delete signals immediately

In a normal relational construct, if you're listening for an event that signals a child was deleted, you dont expect that the parent was deleted already.

This change ensures that post_delete signals are fired immediately after objects are deleted in the graph.

FWIW we need this at Disqus because we use application triggers to do various things.

Our construct is like:

```
User:
profile = ForeignKey(UserProfile)

Comment:
user = ForeignKey(User)

Comment.post_delete -> publish that a message was deleted, by author,
referencing something other than the id of the author.
```

In Django 1.2 this works fine, but in 1.4 the author has already been removed from the database when the Comment post_delete trigger happens.