From fa4c79c8de2ac677e1f5efdd68bc8bcdb2b111fc Mon Sep 17 00:00:00 2001 From: Wei Huang Date: Wed, 2 Oct 2024 22:41:39 +0200 Subject: [PATCH] Log remote status when push release task failed Similar to what's been done in PR #685 for release task. --- .../pl/allegro/tech/build/axion/release/PushReleaseTask.groovy | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/groovy/pl/allegro/tech/build/axion/release/PushReleaseTask.groovy b/src/main/groovy/pl/allegro/tech/build/axion/release/PushReleaseTask.groovy index 4098e9e4..ea1eb637 100644 --- a/src/main/groovy/pl/allegro/tech/build/axion/release/PushReleaseTask.groovy +++ b/src/main/groovy/pl/allegro/tech/build/axion/release/PushReleaseTask.groovy @@ -16,7 +16,9 @@ abstract class PushReleaseTask extends BaseAxionTask { ScmPushResult result = releaser.pushRelease() if (result.outcome === ScmPushResultOutcome.FAILED) { + def status = result.failureStatus def message = result.remoteMessage.orElse("Unknown error during push") + logger.error("remote status: ${status}") logger.error("remote message: ${message}") throw new ReleaseFailedException(message) }