Changes between Version 1 and Version 2 of Ticket #33882, comment 4
- Timestamp:
- Aug 2, 2022, 2:23:41 AM (2 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #33882, comment 4
v1 v2 10 10 https://forum.djangoproject.com/t/is-it-possible-to-use-transaction-atomic-with-async-functions/8924 11 11 12 When looking through the contextmanager (which is actually a class named Atomic in the same file) I saw that `__enter__` and `__exit__` use simple db operations for starting the transaction.12 When looking through the contextmanager (which is actually a class named Atomic in the same file) I saw that `__enter__` and `__exit__` use simple db operations for starting and commiting the transaction. 13 13 If we use the wrappers like suggested (`__aenter__` and `__aexit__`) then everything should be fine in theory. In praxis I need to test the code (I have not much time so it may be easier if somebody else tries this out) 14 14