Skip to content

Commit 1a06599

Browse files
committed
Fix ruff
1 parent 7b274af commit 1a06599

File tree

1 file changed

+4
-2
lines changed
  • instrumentation/opentelemetry-instrumentation-django/src/opentelemetry/instrumentation/django/middleware

1 file changed

+4
-2
lines changed

instrumentation/opentelemetry-instrumentation-django/src/opentelemetry/instrumentation/django/middleware/otel_middleware.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -183,8 +183,10 @@ def format_request_objects_in_headers(attributes):
183183
try:
184184
method = getattr(value, "method", "UNKNOWN")
185185
request_path = getattr(value, "path", "UNKNOWN")
186-
value_list[index] = f"HttpRequest({method} {request_path})"
187-
except Exception: # pylint: disable=broad-exception-caught
186+
value_list[index] = (
187+
f"HttpRequest({method} {request_path})"
188+
)
189+
except Exception: # pylint: disable=broad-exception-caught
188190
value_list[index] = "HttpRequest(...)"
189191
return attributes
190192

0 commit comments

Comments
 (0)