Skip to content

Commit 5975458

Browse files
Fix Ruff D203/D213 docstring formatting in celery.py
Add blank lines before class docstrings (D203) and move method docstring summary to second line (D213) to satisfy upstream Ruff config.
1 parent dc6df06 commit 5975458

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

dojo/celery.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313

1414

1515
class DojoAsyncTask(Task):
16+
1617
"""
1718
Base task class that provides dojo_async_task functionality without using a decorator.
1819
@@ -24,7 +25,8 @@ class DojoAsyncTask(Task):
2425
"""
2526

2627
def __call__(self, *args, **kwargs):
27-
"""Restore user context in the celery worker via crum.impersonate.
28+
"""
29+
Restore user context in the celery worker via crum.impersonate.
2830
2931
The apply_async method injects ``async_user`` into kwargs when a task
3032
is dispatched. Here we pop it and set it as the current user in
@@ -73,6 +75,7 @@ def apply_async(self, args=None, kwargs=None, **options):
7375

7476

7577
class PgHistoryTask(DojoAsyncTask):
78+
7679
"""
7780
Custom Celery base task that automatically applies pghistory context.
7881

0 commit comments

Comments
 (0)