summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Charette <charette.s@gmail.com>2020-04-04 20:28:54 +0200
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2020-04-06 06:17:16 +0200
commit810f18c2df4b268ac1908fdd0b43bbbf07bdea06 (patch)
tree5a2fb9404391b0412b25b9e5ca2744f1b446258c
parent2c3497980f925abcee397a99fbfc535feee5d947 (diff)
[3.0.x] Fixed #31423 -- Clarified nested atomic() example.
Backport of fa5e7e46d875d4143510944f19d79df7b1739bab from master
-rw-r--r--docs/topics/db/transactions.txt8
1 files changed, 4 insertions, 4 deletions
diff --git a/docs/topics/db/transactions.txt b/docs/topics/db/transactions.txt
index 12e695b2f6..cebec3d7d1 100644
--- a/docs/topics/db/transactions.txt
+++ b/docs/topics/db/transactions.txt
@@ -146,10 +146,10 @@ Django provides a single API to control database transactions.
In this example, even if ``generate_relationships()`` causes a database
error by breaking an integrity constraint, you can execute queries in
``add_children()``, and the changes from ``create_parent()`` are still
- there. Note that any operations attempted in ``generate_relationships()``
- will already have been rolled back safely when ``handle_exception()`` is
- called, so the exception handler can also operate on the database if
- necessary.
+ there and bound to the same transaction. Note that any operations attempted
+ in ``generate_relationships()`` will already have been rolled back safely
+ when ``handle_exception()`` is called, so the exception handler can also
+ operate on the database if necessary.
.. admonition:: Avoid catching exceptions inside ``atomic``!