Changes between Initial Version and Version 1 of Ticket #36318, comment 4
- Timestamp:
- Apr 11, 2025, 10:24:13 AM (5 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #36318, comment 4
initial v1 5 5 > **Avoid catching exceptions inside atomic! 6 6 > 7 > When exiting an `atomic` block, Django looks at whether it’s exited normally or with an exception to determine whether to commit or roll back. If you catch and handle exceptions inside an atomicblock, you may hide from Django the fact that a problem has happened. **This can result in unexpected behavior.**7 > When exiting an `atomic` block, Django looks at whether it’s exited normally or with an exception to determine whether to commit or roll back. If you catch and handle exceptions inside an `atomic` block, you may hide from Django the fact that a problem has happened. **This can result in unexpected behavior.** 8 8 9 9 I'm pretty confident we'll be able to avoid surfacing the previous exception message as the source of the `TransactionManagementError` with