diff --git a/src/EventListener/TracingConsoleListener.php b/src/EventListener/TracingConsoleListener.php index 26beccf3..4d3fdd0d 100644 --- a/src/EventListener/TracingConsoleListener.php +++ b/src/EventListener/TracingConsoleListener.php @@ -93,6 +93,7 @@ public function handleConsoleTerminateEvent(ConsoleTerminateEvent $event): void $span = $this->hub->getSpan(); if (null !== $span) { + $span->setStatus($event->getExitCode() === 0 ? SpanStatus::ok() : SpanStatus::internalError()); $span->finish(); } }