This is an automated email from the ASF dual-hosted git repository.

tcunning pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-spring-boot.git

commit b4e993c0de2029deb4b71ade3813e83dbc4a0b2b
Author: Tom Cunningham <[email protected]>
AuthorDate: Tue Apr 14 15:10:06 2026 -0400

    Improve parse_errors.sh debugging output
    
    Add clear START/END banners with timestamps and visual indicators to make
    it easier to trace parse_errors.sh execution in CI logs.
    
    Changes:
    - Add timestamp banners at start and end of script execution
    - Replace [DEBUG] prefix with cleaner [parse_errors.sh] prefix
    - Add visual indicators: ✓ ✗ ⊘ ⚠ for status
    - Use box-drawing characters for failure sections
    - Always show exit 0 with timestamp at end
    
    Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
---
 .github/actions/incremental-build/parse_errors.sh | 70 +++++++++++------------
 1 file changed, 35 insertions(+), 35 deletions(-)

diff --git a/.github/actions/incremental-build/parse_errors.sh 
b/.github/actions/incremental-build/parse_errors.sh
index 24e904fd078..a1d7a70749b 100755
--- a/.github/actions/incremental-build/parse_errors.sh
+++ b/.github/actions/incremental-build/parse_errors.sh
@@ -21,65 +21,67 @@ set +e
 
 LOG_FILE=$1
 
-echo "[DEBUG parse_errors.sh] Processing: $LOG_FILE" >&2
+echo "============================================================" >&2
+echo "[parse_errors.sh START] $(date '+%Y-%m-%d %H:%M:%S')" >&2
+echo "[parse_errors.sh] Processing: $LOG_FILE" >&2
+echo "============================================================" >&2
 
 # Extract module path from log file path
 # e.g., 
./components-starter/camel-slack-starter/target/surefire-reports/foo.txt -> 
components-starter/camel-slack-starter
 MODULE_PATH=$(echo "$LOG_FILE" | sed 's|^\./||' | sed 's|/target/.*||')
-echo "[DEBUG parse_errors.sh] Module path: $MODULE_PATH" >&2
+echo "[parse_errors.sh] Module: $MODULE_PATH" >&2
 
 # Skip if file doesn't exist or is not readable
 if [[ ! -f "$LOG_FILE" ]]; then
-  echo "[DEBUG parse_errors.sh] File does not exist: $LOG_FILE" >&2
+  echo "[parse_errors.sh] ⊘ File does not exist, skipping" >&2
+  echo "[parse_errors.sh END] $(date '+%Y-%m-%d %H:%M:%S') - exit 0" >&2
+  echo "============================================================" >&2
   exit 0
 fi
 
 if [[ ! -r "$LOG_FILE" ]]; then
-  echo "[DEBUG parse_errors.sh] File is not readable: $LOG_FILE" >&2
+  echo "[parse_errors.sh] ⊘ File not readable, skipping" >&2
+  echo "[parse_errors.sh END] $(date '+%Y-%m-%d %H:%M:%S') - exit 0" >&2
+  echo "============================================================" >&2
   exit 0
 fi
 
-echo "[DEBUG parse_errors.sh] File exists and is readable, size: $(wc -c < 
"$LOG_FILE") bytes" >&2
+echo "[parse_errors.sh] File size: $(wc -c < "$LOG_FILE") bytes" >&2
 
 # Extract failures/errors
-echo "[DEBUG parse_errors.sh] Searching for FAILURE|ERROR patterns..." >&2
+echo "[parse_errors.sh] Searching for FAILURE|ERROR patterns..." >&2
 raw_failures=$(cat "$LOG_FILE" | egrep "FAILURE|ERROR" 2>/dev/null || true)
 if [[ -z "$raw_failures" ]]; then
-  echo "[DEBUG parse_errors.sh] No FAILURE or ERROR patterns found in file" >&2
+  echo "[parse_errors.sh] ✓ No failures found" >&2
+  echo "[parse_errors.sh END] $(date '+%Y-%m-%d %H:%M:%S') - exit 0" >&2
+  echo "============================================================" >&2
   exit 0
 fi
 
-echo "[DEBUG parse_errors.sh] Found FAILURE/ERROR entries (count: $(echo 
"$raw_failures" | wc -l))" >&2
-echo "[DEBUG parse_errors.sh] First few lines of raw_failures:" >&2
+echo "[parse_errors.sh] ✗ Found FAILURE/ERROR entries: $(echo "$raw_failures" 
| wc -l)" >&2
+echo "[parse_errors.sh] First 5 lines:" >&2
 echo "$raw_failures" | head -5 >&2
 
 # Look for "Time elapsed" entries and extract org.* test names
-echo "[DEBUG parse_errors.sh] Searching for 'Time elapsed' entries..." >&2
 time_elapsed_entries=$(echo "$raw_failures" | grep "Time elapsed" 2>/dev/null 
|| true)
-echo "[DEBUG parse_errors.sh] Time elapsed entries found: $(echo 
"$time_elapsed_entries" | wc -l)" >&2
+echo "[parse_errors.sh] Time elapsed entries: $(echo "$time_elapsed_entries" | 
wc -l)" >&2
 
-echo "[DEBUG parse_errors.sh] Searching for org.* entries..." >&2
 org_entries=$(echo "$time_elapsed_entries" | egrep "^org" 2>/dev/null || true)
-echo "[DEBUG parse_errors.sh] org.* entries found: $(echo "$org_entries" | wc 
-l)" >&2
+echo "[parse_errors.sh] org.* test entries: $(echo "$org_entries" | wc -l)" >&2
 
 if [[ -n "$org_entries" ]]; then
-  echo "[DEBUG parse_errors.sh] Processing org_entries:" >&2
+  echo "[parse_errors.sh] Processing failures:" >&2
   echo "$org_entries" >&2
 
   # Generate summary with module path included in test name
   # Format: | Module::TestClass | Duration | Type |
-  echo "[DEBUG parse_errors.sh] Generating failed_summary..." >&2
   failed_summary=$(echo "$org_entries" | sed 's/\!//g' | awk -v 
mod="$MODULE_PATH" -F ' ' '{printf "| **%s**::%s | %s%s | %s |\n", mod, 
$1,$5,$6, $8}' 2>/dev/null || true)
-  echo "[DEBUG parse_errors.sh] failed_summary generated (length: 
${#failed_summary})" >&2
 
   if [[ -n "$failed_summary" ]]; then
-    echo "[DEBUG parse_errors.sh] failed_summary is not empty" >&2
-
     if [[ -n "${GITHUB_STEP_SUMMARY:-}" ]]; then
-      echo "[DEBUG parse_errors.sh] GITHUB_STEP_SUMMARY is set to: 
$GITHUB_STEP_SUMMARY" >&2
+      echo "[parse_errors.sh] Writing to GITHUB_STEP_SUMMARY" >&2
 
       # Add to GitHub step summary
-      echo "[DEBUG parse_errors.sh] Writing summary to GITHUB_STEP_SUMMARY..." 
>&2
       echo "$failed_summary" >> "$GITHUB_STEP_SUMMARY" 2>/dev/null || true
 
       # Add detailed error output
@@ -91,40 +93,38 @@ if [[ -n "$org_entries" ]]; then
       echo "\`\`\`" >> "$GITHUB_STEP_SUMMARY" 2>/dev/null || true
       echo "</details>" >> "$GITHUB_STEP_SUMMARY" 2>/dev/null || true
       echo "" >> "$GITHUB_STEP_SUMMARY" 2>/dev/null || true
-      echo "[DEBUG parse_errors.sh] Summary written to GITHUB_STEP_SUMMARY" >&2
     else
-      echo "[DEBUG parse_errors.sh] GITHUB_STEP_SUMMARY is not set, skipping 
summary output" >&2
+      echo "[parse_errors.sh] ⚠ GITHUB_STEP_SUMMARY not set, cannot write 
summary" >&2
     fi
-  else
-    echo "[DEBUG parse_errors.sh] failed_summary is empty, skipping summary 
generation" >&2
   fi
 
   # Output to stderr for CI logs
   echo "" >&2
-  echo "=============================================" >&2
-  echo "FAILURE in module: $MODULE_PATH" >&2
-  echo "=============================================" >&2
+  echo "╔═════════════════════════════════════════════╗" >&2
+  echo "║  FAILURE in module: $MODULE_PATH" >&2
+  echo "╚═════════════════════════════════════════════╝" >&2
   echo "$org_entries" >&2
   echo "" >&2
   echo "Full error details:" >&2
   cat "$LOG_FILE" | egrep -A 10 "FAILURE|ERROR" | head -50 >&2
-  echo "=============================================" >&2
+  echo "╚═════════════════════════════════════════════╝" >&2
   echo "" >&2
 else
-  echo "[DEBUG parse_errors.sh] No org.* entries found, but raw_failures 
exist" >&2
-  echo "[DEBUG parse_errors.sh] Outputting raw_failures to help debug:" >&2
+  echo "[parse_errors.sh] ⚠ No org.* pattern match (unusual format)" >&2
   echo "" >&2
-  echo "=============================================" >&2
-  echo "FAILURE/ERROR in module: $MODULE_PATH (no org.* pattern match)" >&2
-  echo "=============================================" >&2
+  echo "╔═════════════════════════════════════════════╗" >&2
+  echo "║  ERROR in module: $MODULE_PATH (unusual format)" >&2
+  echo "╚═════════════════════════════════════════════╝" >&2
   echo "Raw failures found:" >&2
   echo "$raw_failures" | head -20 >&2
   echo "" >&2
   echo "Full log file content (first 100 lines):" >&2
   head -100 "$LOG_FILE" >&2
-  echo "=============================================" >&2
+  echo "╚═════════════════════════════════════════════╝" >&2
   echo "" >&2
 fi
 
-echo "[DEBUG parse_errors.sh] Finished processing $LOG_FILE" >&2
+echo "============================================================" >&2
+echo "[parse_errors.sh END] $(date '+%Y-%m-%d %H:%M:%S') - exit 0" >&2
+echo "============================================================" >&2
 exit 0

Reply via email to