From 973e042007424d2419ccf7368249c6f2bd97f06e Mon Sep 17 00:00:00 2001 From: Antonis Lilis Date: Mon, 23 Feb 2026 16:20:12 +0100 Subject: [PATCH] fix(ios): print bundler output line-by-line on build failure When a JS syntax or import error causes the Metro bundler to fail, the build output was printed as a single unreadable string, hiding the actual error behind a generic Sentry source maps message. Print the captured output line-by-line (consistent with the success path) and before the Sentry guidance, so the real bundler error is visible in Xcode's Issues navigator. Fixes #5689 Co-Authored-By: Claude Sonnet 4.6 --- packages/core/scripts/sentry-xcode.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/scripts/sentry-xcode.sh b/packages/core/scripts/sentry-xcode.sh index ff6a1800da..2ab36fc1b1 100755 --- a/packages/core/scripts/sentry-xcode.sh +++ b/packages/core/scripts/sentry-xcode.sh @@ -57,11 +57,11 @@ if [ "$SENTRY_DISABLE_AUTO_UPLOAD" != true ]; then echo "$SENTRY_XCODE_COMMAND_OUTPUT" | awk '{print "output: sentry-cli - " $0}' else if [ "$SENTRY_ALLOW_FAILURE" == true ]; then + echo "$SENTRY_XCODE_COMMAND_OUTPUT" | awk '{print "warning: sentry-cli - " $0}' echo "warning: sentry-cli - Source maps upload failed, but continuing build because SENTRY_ALLOW_FAILURE=true" - echo "warning: sentry-cli - $SENTRY_XCODE_COMMAND_OUTPUT" else + echo "$SENTRY_XCODE_COMMAND_OUTPUT" | awk '{print "error: sentry-cli - " $0}' echo "error: sentry-cli - To disable source maps auto upload, set SENTRY_DISABLE_AUTO_UPLOAD=true in your environment variables. Or to allow failing upload, set SENTRY_ALLOW_FAILURE=true" - echo "error: sentry-cli - $SENTRY_XCODE_COMMAND_OUTPUT" exitCode=1 fi fi