This is an automated email from the ASF dual-hosted git repository.
uros-b pushed a commit to branch branch-4.x
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/branch-4.x by this push:
new bc447833febb [MINOR][INFRA] Fix doubled braces in structured logging
style-check hint
bc447833febb is described below
commit bc447833febb0d1cca34b44ecd9116e6323f7aaf
Author: Uros Bojanic <[email protected]>
AuthorDate: Tue Jul 28 10:08:48 2026 +0000
[MINOR][INFRA] Fix doubled braces in structured logging style-check hint
### What changes were proposed in this pull request?
Fixes the developer-facing hint printed by the structured-logging style
check so its MDC example shows single braces `${MDC(TASK_ID, taskId)}` instead
of the doubled `${{...}}`.
### Why are the changes needed?
The example lives in a plain (non-f) string literal, so the doubled braces
were rendered literally, teaching incorrect syntax to anyone who copied the
hint. The real structured-logging API uses single braces.
### Does this PR introduce _any_ user-facing change?
No (developer tooling message only).
### How was this patch tested?
Manual inspection: confirmed the hint is emitted from a plain (non-f)
string literal, so the doubled braces render literally, and that the real
structured-logging API (`Logging.scala`) uses single braces. Reviewer can
re-run `dev/structured_logging_style.py` to see the corrected hint.
### Was this patch authored or co-authored using generative AI tooling?
Generated-by: Claude Code (Opus 4.8)
Closes #57597 from uros-b/devexp-structured-logging-hint-braces.
Lead-authored-by: Uros Bojanic <[email protected]>
Co-authored-by: Uros Bojanic <[email protected]>
Signed-off-by: Uros Bojanic <[email protected]>
(cherry picked from commit e8cbd4840606db3f0ec6cca39f2e2d7dd0f43474)
Signed-off-by: Uros Bojanic <[email protected]>
---
dev/structured_logging_style.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dev/structured_logging_style.py b/dev/structured_logging_style.py
index 43f0e22f1ac3..b0d1b2a76e4a 100755
--- a/dev/structured_logging_style.py
+++ b/dev/structured_logging_style.py
@@ -82,7 +82,7 @@ def main():
print(f"[error] {file_path}:{line_number}:{start_char}",
file=sys.stderr)
print(
"[error]\tPlease use the Structured Logging Framework for
logging messages "
- 'with variables. For example: log"...${{MDC(TASK_ID,
taskId)}}..."'
+ 'with variables. For example: log"...${MDC(TASK_ID,
taskId)}..."'
"\n\tRefer to the guidelines in the file
`internal/Logging.scala`.",
file=sys.stderr,
)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]