Skip to content

Commit

Permalink
Use logger.exception to get traceback for export exception. (#269)
Browse files Browse the repository at this point in the history
  • Loading branch information
Oberon00 authored Nov 7, 2019
1 parent f510215 commit e95a115
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ def on_end(self, span: Span) -> None:
try:
self.span_exporter.export((span,))
# pylint: disable=broad-except
except Exception as exc:
logger.warning("Exception while exporting data: %s", exc)
except Exception:
logger.exception("Exception while exporting Span.")

def shutdown(self) -> None:
self.span_exporter.shutdown()
Expand Down Expand Up @@ -191,7 +191,7 @@ def export(self) -> None:
) # type: ignore
# pylint: disable=broad-except
except Exception:
logger.exception("Exception while exporting data.")
logger.exception("Exception while exporting Span batch.")

# clean up list
for index in range(idx):
Expand Down

0 comments on commit e95a115

Please sign in to comment.