Skip to content

Commit 37687dd

Browse files
authored
Build: log all the Celery options passed to the task (#12357)
This will help us when debugging.
1 parent 7308f32 commit 37687dd

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

readthedocs/core/utils/__init__.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -104,10 +104,6 @@ def prepare_build(
104104
options["soft_time_limit"] = time_limit
105105
options["time_limit"] = int(time_limit * 1.2)
106106

107-
structlog.contextvars.bind_contextvars(
108-
time_limit=options["time_limit"], soft_time_limit=options["soft_time_limit"]
109-
)
110-
111107
if commit:
112108
structlog.contextvars.bind_contextvars(commit=commit)
113109

@@ -180,6 +176,9 @@ def prepare_build(
180176
log.info("Disabling ACKS_LATE for this particular build.")
181177
options["acks_late"] = False
182178

179+
# Log all the extra options passed to the task
180+
structlog.contextvars.bind_contextvars(**options)
181+
183182
return (
184183
update_docs_task.signature(
185184
args=(

0 commit comments

Comments
 (0)