summaryrefslogtreecommitdiff
path: root/docs/topics
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2026-01-18 21:26:56 +0100
committerGitHub <noreply@github.com>2026-01-18 21:26:56 +0100
commit6cff02078799b7c683a0d39630d49ab4fe532e7c (patch)
tree9813fc94d952942117b23d61231b9e89a8cab1c2 /docs/topics
parent0d31ca98830542088299d2078402891d08cc3a65 (diff)
Applied Black's 2026 stable style.
https://github.com/psf/black/releases/tag/26.1.0
Diffstat (limited to 'docs/topics')
-rw-r--r--docs/topics/db/sql.txt7
-rw-r--r--docs/topics/tasks.txt2
2 files changed, 3 insertions, 6 deletions
diff --git a/docs/topics/db/sql.txt b/docs/topics/db/sql.txt
index 6aafa2c3b5..bd34df8bb7 100644
--- a/docs/topics/db/sql.txt
+++ b/docs/topics/db/sql.txt
@@ -121,15 +121,14 @@ had ``Person`` data in it, you could easily map it into ``Person`` instances:
.. code-block:: pycon
- >>> Person.objects.raw(
- ... """
+ >>> Person.objects.raw("""
... SELECT first AS first_name,
... last AS last_name,
... bd AS birth_date,
... pk AS id,
... FROM some_other_table
- ... """
- ... )
+ ... """)
+ ...
As long as the names match, the model instances will be created correctly.
diff --git a/docs/topics/tasks.txt b/docs/topics/tasks.txt
index 96deac6dc3..06e83af0bc 100644
--- a/docs/topics/tasks.txt
+++ b/docs/topics/tasks.txt
@@ -207,7 +207,6 @@ To receive the Task context as an argument to your Task function, pass
from django.core.mail import send_mail
from django.tasks import task
-
logger = logging.getLogger(__name__)
@@ -328,7 +327,6 @@ committed to the database, use :func:`transaction.on_commit()
from django.db import transaction
-
with transaction.atomic():
Thing.objects.create(num=1)
transaction.on_commit(partial(my_task.enqueue, thing_num=1))