From acc943e988a9c1f5a24f03e00998ce080f059275 Mon Sep 17 00:00:00 2001 From: Maarten de Keizer Date: Mon, 20 Nov 2023 13:49:57 +0100 Subject: [PATCH] Display error information --- src/Command/BackupCommand.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Command/BackupCommand.php b/src/Command/BackupCommand.php index 08e2a07..cf1edee 100644 --- a/src/Command/BackupCommand.php +++ b/src/Command/BackupCommand.php @@ -100,7 +100,12 @@ protected function execute(InputInterface $input, OutputInterface $output): int $this->sendNotifications($profileLogger, $profile, $runId, AbstractNotification::ON_SUCCESS, $metaData); $profileLogger->info('Notifications send', []); } catch (\Exception $e) { - $profileLogger->info('Profile failed, start sending notifications', []); + $profileLogger->info('Profile failed, start sending notifications', [ + 'e' => get_class($e), + 'msg' => $e->getMessage(), + 'file' => $e->getFile() . ':' . $e->getLine(), + 'trace' => $e->getTraceAsString() + ]); $this->sendNotifications($baseLogger, $profile, $runId, AbstractNotification::ON_FAILURE, [ 'e' => get_class($e), 'msg' => $e->getMessage(),