From 2edca436ee154eb2af1ab4cebc30cc003ec242ee Mon Sep 17 00:00:00 2001 From: DIYgod Date: Fri, 2 Oct 2026 23:53:22 +0800 Subject: [PATCH] docs(skills): boot the release QA emulator with real resources The AVD recipe copied Medium_Phone's config.ini, which asks for 1 core, 2 GB and gpu auto. A command-line launch then renders with lavapipe on the CPU, so the 0.5.11 checks hit System UI ANRs and stalled animations that looked like app bugs. Ask for 4 cores, 4 GB and the host GPU. Boot with -no-snapshot instead of -no-snapshot-save: forceFastBoot otherwise restores the quickboot snapshot, which still held 0.5.10 and silently rolled back the installed APK. Keep audio on, since without it TTS falls back to the downloaded file and ExoPlayer fails, and check the installed version after every boot. Co-Authored-By: Claude Opus 5.5 --- .../references/verify-android-build.md | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/.agents/skills/mobile-release/references/verify-android-build.md b/.agents/skills/mobile-release/references/verify-android-build.md index d670ae02d..cdaecac8c 100644 --- a/.agents/skills/mobile-release/references/verify-android-build.md +++ b/.agents/skills/mobile-release/references/verify-android-build.md @@ -34,25 +34,34 @@ NAME=Folo_Verify_$(date +%H%M%S) # or Folo_Release_QA for the persistent QA e AVD="$HOME/.android/avd" mkdir -p "$AVD/$NAME.avd" cp "$AVD/Medium_Phone.avd/config.ini" "$AVD/$NAME.avd/config.ini" -sed -i '' -e "s/^AvdId = .*/AvdId = $NAME/" -e "s/^avd.ini.displayname = .*/avd.ini.displayname = $NAME/" "$AVD/$NAME.avd/config.ini" +sed -i '' -e "s/^AvdId = .*/AvdId = $NAME/" -e "s/^avd.ini.displayname = .*/avd.ini.displayname = $NAME/" \ + -e "s/^hw\.cpu\.ncore = .*/hw.cpu.ncore = 4/" -e "s/^hw\.ramSize = .*/hw.ramSize = 4096/" \ + -e "s/^hw\.gpu\.mode = .*/hw.gpu.mode = host/" "$AVD/$NAME.avd/config.ini" printf 'avd.ini.encoding=UTF-8\npath=%s\npath.rel=avd/%s.avd\ntarget=android-36\n' "$AVD/$NAME.avd" "$NAME" > "$AVD/$NAME.ini" ``` +`Medium_Phone.avd/config.ini` only asks for 1 core, 2 GB and `hw.gpu.mode = auto`. Android Studio overrides that when it launches the AVD, but a command-line launch takes the file as is, and `auto` falls back to lavapipe, which renders on the CPU. That emulator shows "System UI isn't responding", drops taps and stalls Reanimated animations, which looks like app bugs (a player bar that never hides, a see-through header). Before booting any AVD, including `Folo_Release_QA`, check that its `config.ini` asks for 4 cores, 4096 MB and `host`. + Boot a new AVD once with `-wipe-data` to create fresh user data; never pass `-wipe-data` to `Folo_Release_QA` after that, it erases the signed-in session. On that first boot Android may show "System UI isn't responding"; tap Wait (`android:id/aerr_wait`). Deleting an AVD means removing `$AVD/$NAME.avd` and `$AVD/$NAME.ini` after `adb -s emu kill`. Creating `Folo_Release_QA` once: create it as above, boot it, install the current GitHub release APK (`gh release download mobile/v -p build.apk`), and sign in to the demo account; an agent that may not type passwords asks the user to do that sign-in. Do the same if the emulator lost its session. -Boot and install (a booted copy of this config reports `sys.boot_completed` after about 15 seconds): +Boot and install (a cold boot with this config reports `sys.boot_completed` after about 15 seconds): ```bash PORT=5560; SERIAL="emulator-$PORT" # pick a port pair nothing listens on -(emulator @"$NAME" -port $PORT -no-snapshot-save -no-boot-anim -no-audio > "$SCRATCH/emulator.log" 2>&1 &) +(emulator @"$NAME" -port $PORT -no-snapshot -no-boot-anim > "$SCRATCH/emulator.log" 2>&1 &) adb -s "$SERIAL" wait-for-device until [ "$(adb -s "$SERIAL" shell getprop sys.boot_completed | tr -d '\r')" = 1 ]; do sleep 3; done adb -s "$SERIAL" install -r -d "$APK" +adb -s "$SERIAL" shell dumpsys package is.follow | grep -E 'versionName|lastUpdateTime' # the new version adb -s "$SERIAL" shell monkey -p is.follow -c android.intent.category.LAUNCHER 1 ``` +- Always boot with `-no-snapshot`. The AVD config has `fastboot.forceFastBoot = yes`, so any other boot restores the quickboot snapshot and rolls the data partition back to the moment it was saved: an APK installed before a reboot is gone, and `Folo_Release_QA`'s snapshot still holds mobile 0.5.10. A cold boot keeps the data partition as the last session left it, including the demo session. Check the installed version after every boot or reinstall, and Settings → About before trusting a result. +- Keep the audio on (no `-no-audio`). Without an audio device the TTS WebView stream never starts, the 15-second timeout falls back to downloading the whole file, and ExoPlayer then fails with `MediaCodecAudioRenderer error`, so none of the TTS checks mean anything. TTS plays through the Mac's speakers during those checks. +- For long TTS checks pick an entry whose feed carries the full text (designboom does); the Aeon feed only has a one-line description, so its TTS ends after about 14 seconds by design. + ## 3. Drive the app and check - Read the screen with `adb -s "$SERIAL" exec-out uiautomator dump /dev/tty`; builds after 0.5.10 expose testIDs as `resource-id` (for example `timeline-entry-first`, `entry-item-`, `floating-player-bar`, `player-stop`). Under react-native-screens modals the dump can be stale; `adb shell dumpsys activity top` shows the real tree.