From 24f479b0ad70823b967884d92feba5dc04ace094 Mon Sep 17 00:00:00 2001 From: Thomas SharedInbox Date: Thu, 21 May 2026 21:21:04 +0200 Subject: [PATCH] Filter Gradle/Dagger noise from Firebase Test Lab CI output Add scripts/run_firebase_test.sh that strips ANSI codes and removes UP-TO-DATE task lines, libsqlite warnings, Gradle deprecation notices and other high-volume noise before it hits the CI log. Co-Authored-By: Claude Sonnet 4.6 --- Taskfile.yml | 2 +- scripts/run_firebase_test.sh | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) create mode 100755 scripts/run_firebase_test.sh diff --git a/Taskfile.yml b/Taskfile.yml index f0eac4e..a9de4d4 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -197,7 +197,7 @@ tasks: - sh: test -n "$FIREBASE_PROJECT_ID" msg: "FIREBASE_PROJECT_ID is not set" cmds: - - dagger call --progress=plain -q -m ci --source=. test-android-firebase --service-account-key env:FIREBASE_TEST_LAB_SERVICE_ACCOUNT_KEY --project-id "$FIREBASE_PROJECT_ID" + - scripts/run_firebase_test.sh ci-graph: desc: Print a Mermaid diagram of the CI pipeline — paste into mermaid.live or any Markdown renderer diff --git a/scripts/run_firebase_test.sh b/scripts/run_firebase_test.sh new file mode 100755 index 0000000..d29b423 --- /dev/null +++ b/scripts/run_firebase_test.sh @@ -0,0 +1,36 @@ +#!/usr/bin/env bash +# Runs the Firebase Test Lab Dagger pipeline with Gradle/Dagger noise filtered out. +set -uo pipefail + +RC_FILE=$(mktemp) +trap 'rm -f "$RC_FILE"' EXIT + +_strip_ansi() { + sed 's/\x1b\[[0-9;]*[mGKHFJ]//g' +} + +_filter_noise() { + grep -vE \ + '> Task :.+(UP-TO-DATE|NO-SOURCE)'\ +'|[0-9]+ files found for path '\''lib/'\ +'|^Inputs:'\ +'|^[[:space:]]+-[[:space:]]/'\ +'|\[Incubating\]'\ +'|Deprecated Gradle features'\ +'|warning-mode all'\ +'|please refer to https://docs\.gradle'\ +'|[0-9]+ actionable tasks'\ +'|^warning: \[options\]'\ +'|^Note: Some input files'\ +'|^\s*[┆│]\s*$' \ + || true +} + +{ + dagger call --progress=plain -q -m ci --source=. test-android-firebase \ + --service-account-key env:FIREBASE_TEST_LAB_SERVICE_ACCOUNT_KEY \ + --project-id "$FIREBASE_PROJECT_ID" + echo $? > "$RC_FILE" +} 2>&1 | _strip_ansi | _filter_noise + +exit "$(cat "$RC_FILE" 2>/dev/null || echo 1)"