41 lines
7.5 KiB
Markdown
41 lines
7.5 KiB
Markdown
# Android launch and hazard follow-up — 2026-10-01
|
|
|
|
## Launch diagnosis
|
|
|
|
- Device: Pixel 8 Pro AVD `emulator-5554`, Android API 37, Android user 0.
|
|
- Original installed build: package `app.motorsignal.motorcycle`, versionCode 102 / versionName 1.0.2. APK SHA-256 `279F561D8DB91D01138321EE2666B2029D239BC6008809E802458FF835796AA2`.
|
|
- The APK badging and manifest declare `app.motorsignal.motorcycle.MainActivity` with MAIN/LAUNCHER and exported=true; no activity alias. Gradle applicationId matches. A stale separate `com.motorsignal.app.debug` package was also installed.
|
|
- `cmd package resolve-activity --brief app.motorsignal.motorcycle` resolved `app.motorsignal.motorcycle/.MainActivity`; explicit `am start --user 0 -n app.motorsignal.motorcycle/.MainActivity` and `monkey -p app.motorsignal.motorcycle` launched it. `dumpsys activity` confirmed MainActivity resumed. No packaging defect was established; the prior unresolved launch report did not recur.
|
|
- Existing `motorsignal.sqlite` was backed up before installation. Backup SHA-256 remained `187F574143861CC5BD012FC4A7B0F54EA9EC8628A002615932EF7D4E9B3CE81B`; installs used `adb install -r` and retained the original package/database.
|
|
|
|
## Isolated QA app configuration
|
|
|
|
- Added an Android `qa` flavor with application ID suffix `.qa`; moved the demo Google Services resource from the generic debug source set to `android/app/src/qa/google-services.json`. The checked-in main `android/app/google-services.json` remains configured for `motoapp-d22e0`; QA Dart entry enforces `demo-*`, uses Auth 9299 / Firestore 8288 via `adb reverse`, disables FlutterFire host remapping, and requires R2 worker URL `http://127.0.0.1:1`.
|
|
- QA build command: `flutter build apk --debug --flavor qa --target tools/qa_auth_main.dart --dart-define=R2_WORKER_URL=http://127.0.0.1:1` — exit 0. APK `build/app/outputs/flutter-apk/app-qa-debug.apk`, SHA-256 `1EDB7FC2DF04C6640A3B593D69794071156C2F21A708D3477ED6940E933237E2`, application ID `app.motorsignal.motorcycle.qa`, version 102 / 1.0.2. Installed alongside the original package. Package manager resolved `app.motorsignal.motorcycle.qa/app.motorsignal.motorcycle.MainActivity`; after handling first-run location and notification prompts, `dumpsys activity` confirmed that component resumed. FirebaseInitProvider initialized without duplicate-app exception. QA Auth created anonymous user prefix `P2z7HFWM0`; no credentials recorded.
|
|
- Artifact caveat: the APK currently at that output path now hashes to `724D0C67250F92FE4902337D5C9966C116DF3C104102FE3FEBB427B3C02943B1` (same QA package and version according to `aapt`). This differs from the build-time hash recorded by the device-test owner above. The installed package was not pulled and rehashed after its successful backend test; report the build-time tested hash as owner-captured evidence and do not equate the current ignored workspace APK with the installed tested binary.
|
|
- Added explicit `production` and `qa` flavors and set Flutter's default flavor to `production`. Standard `flutter build apk --debug` now ran `assembleProductionDebug`, exit 0, output `build/app/outputs/flutter-apk/app-production-debug.apk`; `aapt dump badging` confirmed package `app.motorsignal.motorcycle`, launcher `app.motorsignal.motorcycle.MainActivity`, versionCode 102 / versionName 1.0.2. SHA-256 `8FBFC7D55864224D1C387CE013E5395FE853C884A0AF2E1AB3A12D63357B02B4`. This APK was not installed or launched, so no production Firebase request occurred. Main Firebase file remains unchanged.
|
|
|
|
## Hazard runtime evidence
|
|
|
|
- Isolated services were loopback-bound only. Device reverse mappings included guest 9299 -> host 9299 and guest 8288 -> host 8288. Auth/Firestore project: `demo-motorsignal-qa`; no production Firebase request was intentionally made.
|
|
- Successful hazard report from final `.qa` package: Firestore Admin SDK read confirmed one new document, `road_alerts/swarm_1790854134314_1_P2z7H`, category `hazard`, reporter `P2z7HFWM0...`, `reportedAt=1790854134314`, latitude `37.7749`, longitude `-122.4193983`. The coordinates match the injected emulator GPS fix `adb emu geo fix -122.4194 37.7749`. Final QA APK hash is recorded above.
|
|
- Earlier QA-target session against the same source and demo backend: successful report persisted; two rapid taps produced exactly one additional Firestore document. Three prior test docs and the final `.qa` report were observed (four total). These are demo-emulator records only.
|
|
- Evidence screenshots retained in the repo: [QA app launch](android-qa-app-launch.png), [fresh injected GPS fix](android-qa-gps-fix.png), [Firestore-persisted hazard](android-qa-hazard-persisted.png), and [earlier pending state attempt](android-qa-hazard-pending.png). The pending screenshot is not proof of a still-pending request at dismissal.
|
|
- A prior attempt to test dismissal while pending was invalid: the modal had closed before capture and the Firestore write completed; it did not prove dismissal during an active location or submission await. A later bounded reverse-port outage attempt did not establish a backend failure outcome, so it is not counted.
|
|
- **P1 runtime overall: BLOCKED / PARTIAL.** Verified successful isolated persistence, GPS coordinates, launch, and rapid-repeat suppression. Still unverified: dismissal during pending location/submission, repeated-tap behavior on final suffixed package, missing permission/location feedback, deterministic backend failure feedback, and full post-fix scenario matrix. Widget regression tests remain separate evidence in `execution.md`.
|
|
|
|
## Follow-up GPS/provider recheck
|
|
|
|
After the isolated accepting-backend run stopped, the owner relaunched the existing Pixel 8 Pro AVD `emulator-5554` without reinstalling or clearing package data. Package manager still resolved QA package to `app.motorsignal.motorcycle.qa/app.motorsignal.motorcycle.MainActivity`, version 102/1.0.2, Android user 0; fine location was allowed. `adb emu geo fix -122.4194 37.7749 [15]` returned `OK`, but `dumpsys location` retained `last location=null` across provider checks and a clean AVD restart. On the rebooted AVD, ADB remained offline through the captured interval and app/provider checks could not continue. Therefore fresh timestamp delivery is **BLOCKED** on this recheck; the prior successful hazard coordinates remain evidence from its earlier working emulator session. Permission recovery and recording restart evidence remain the separate prior dedicated-AVD evidence in `permission.md`; they were not repeated on this rebooted AVD. Historical ANR cause remains unresolved.
|
|
|
|
## Permission, GPS, and recording recovery
|
|
|
|
- Emulator GPS injection responded successfully; Android location settings were enabled and the captured hazard used the injected coordinates. The dashboard screenshot showed `GPS 3D FIX` at a prior injection checkpoint.
|
|
- This follow-up did not execute denial/revocation/regrant, location-loss recovery, recording persistence/restart, or ANR diagnostics. Those remain **BLOCKED/UNTESTED** here; historical ANR cause stays unresolved as stated in `permission.md`.
|
|
|
|
## Cleanup and remaining checks
|
|
|
|
- No production data/settings, merge, deployment, or destructive operation. Original package remained installed and its backed-up database hash was unchanged. The `.qa` app and demo records are isolated test resources.
|
|
- ADB reverse route was restored, and owner stopped isolated Auth/Firestore services and `emulator-5554` after retaining evidence. Host ports 9299/8288 have no active test listeners. QA APK and report remain.
|
|
- Full repository test/analyze gates are QA-lead-owned and were running at report update.
|