django-transaction-signals
django-transaction-signals copied to clipboard
Savepoints
For post_commit and post_rollback signals, I think savepoints need to be taken into account. pre_rollback signals connected during rolled back savepoints should still be called at commit time, whilst analogously connected post_commit signals should not, potentially ending up with both post_commit and post_rollback signals being called during a transaction.commit() call, but only post_rollback signals during a transaction.rollback() call.
This is a good suggestion - I haven't worked much with savepoints, so they're not accounted for in the current implementation. I'll read up on it and see what I can do (and I'd also welcome a patch if you have have a good idea of what to update).