Skip to content

Commit 1d7457e

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 9e5adb7 commit 1d7457e

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

src/workflows/services/common_service.py

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -195,15 +195,21 @@ def start_transport(self):
195195
try:
196196
# Configure OTELTracing if configuration is available
197197
otel_config = (
198-
self.config.opentelemetry if self.config and hasattr(self.config, "opentelemetry") else None
198+
self.config.opentelemetry
199+
if self.config and hasattr(self.config, "opentelemetry")
200+
else None
199201
)
200202

201203
if otel_config:
202204
if "endpoint" not in otel_config:
203-
self.log.warning("Missing required OTEL configuration field `endpoint`.")
204-
205+
self.log.warning(
206+
"Missing required OTEL configuration field `endpoint`."
207+
)
208+
205209
if "timeout" not in otel_config:
206-
self.log.warning("Missing optional OTEL configuration field `timout`. Will default to 10 seconds. ")
210+
self.log.warning(
211+
"Missing optional OTEL configuration field `timout`. Will default to 10 seconds. "
212+
)
207213

208214
# Configure OTELTracing
209215
resource = Resource.create(
@@ -232,7 +238,9 @@ def start_transport(self):
232238
self._transport.add_middleware(otel_middleware)
233239
except Exception as e:
234240
# Continue without tracing if configuration fails
235-
self.log.warning("Failed to configure OpenTelemetry tracing: %s", str(e))
241+
self.log.warning(
242+
"Failed to configure OpenTelemetry tracing: %s", str(e)
243+
)
236244

237245
metrics = self._environment.get("metrics")
238246
if metrics:

0 commit comments

Comments
 (0)