You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
SpanProcessor.on_end exceptions escape cleanup and replace application exceptions #5624
The caller receives RuntimeError("processor failed"), with the application’s ValueError in __context__. Replacing the application’s raise with pass also propagates RuntimeError.
Would you like to implement a fix?
--- a/opentelemetry-sdk/src/opentelemetry/sdk/trace/__init__.py+++ b/opentelemetry-sdk/src/opentelemetry/sdk/trace/__init__.py@@ -187,3 +187,6 @@
def on_end(self, span: "ReadableSpan") -> None:
for sp in self._span_processors:
- sp.on_end(span)+ try:+ sp.on_end(span)+ except Exception:+ logger.exception("Exception while calling SpanProcessor.on_end.")
Tip
React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.
Activity
sdk: catch and log unhandled exceptions in MultiSpanProcessor
sdk: catch and log unhandled exceptions in MultiSpanProcessor
sdk: catch and log unhandled exceptions in MultiSpanProcessor
sdk: catch and log unhandled exceptions in MultiSpanProcessor