diff --git a/.github/workflows/status_check.yml b/.github/workflows/status_check.yml index da75647..099267f 100644 --- a/.github/workflows/status_check.yml +++ b/.github/workflows/status_check.yml @@ -197,9 +197,12 @@ jobs: # the result; the rest runs only on failure, so a green run is unchanged. # # Each line here is a separate `sh -c` -- the action splits the script on - # newlines -- so the failure handler has to stay on one line. + # newlines -- so the failure handler has to stay on one line. The action does + # not pass ignoreReturnCode, so a non-zero line fails the job outright: the + # probe ends in `|| true` because a grep that matches nothing exits 1, and a + # diagnostic must never be the thing that turns a run red. script: | - adb shell cat /proc/meminfo | grep -E 'MemTotal|MemAvailable|SwapTotal' + adb shell cat /proc/meminfo | grep -E 'MemTotal|MemAvailable|SwapTotal' || true ./gradlew :app:connectedDebugAndroidTest -PabiFilters=x86_64 || { echo "=== guest memory at failure ==="; adb shell cat /proc/meminfo | grep -E 'MemTotal|MemAvailable|SwapTotal'; echo "=== kernel OOM kills ==="; adb shell dmesg | grep -iE 'oom|lowmemory|killed process' | tail -20; echo "=== native crashes ==="; adb logcat -d -b crash | tail -40; exit 1; } - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1