Skip to content

docs: note the screenshot fallback when android layout fails - #33

Merged
jvsena42 merged 1 commit into
mainfrom
docs/journeys-miui-layout-fallback
Jul 27, 2026
Merged

docs: note the screenshot fallback when android layout fails#33
jvsena42 merged 1 commit into
mainfrom
docs/journeys-miui-layout-fallback

Conversation

@jvsena42

Copy link
Copy Markdown
Owner

Summary

android layout is unusable on Xiaomi/MIUI devices — the dump crashes inside MIUI's own resource loading, regardless of which app is under test:

Failed to retrieve UI dump: java.io.FileNotFoundException:
/data/system/theme_config/theme_compatibility.xml: open failed: ENOENT

journeys/README.md recommends android layout --pretty as the way to inspect a screen and offers no alternative, so on these devices the journeys read as unrunnable. They are not — the annotated-screenshot path works fine, and I used it to drive a journey on this hardware while debugging #32.

Documents that fallback so the next person does not have to rediscover it.

Changes

  • Add a "When android layout fails" subsection to journeys/README.md, covering:
    • the MIUI symptom, so the error is recognisable
    • the screen capture --annotate + screen resolve commands that work
    • the flag being --screenshot, not --screen (easy to get wrong; the error message does not make it obvious)
    • the need to re-capture after each interaction, since labels are assigned per screenshot
    • that resource-id test tags are unavailable on this path, so steps fall back to visible text

Test plan

  • Commands in the new section were run against a physical Xiaomi device (Android 15 / MIUI) while evaluating the Gaps flow, and are transcribed from that session rather than written from memory.
  • Documentation only — no code, no build impact.

Checklist

  • ./gradlew detekt passes
  • Tested on Android
  • Tested on iOS
  • Updated documentation (if applicable)

Checklist items are unticked rather than N/A: this changes no code, so detekt and the platform runs have nothing to exercise.

Split out from #32 rather than folded into it — that PR is a Claude API fix and this is unrelated. No dependency between them; either can merge first.

🤖 Generated with Claude Code

`android layout` cannot dump the view tree on Xiaomi/MIUI devices — it
crashes inside MIUI's resource loading on a missing
theme_compatibility.xml, regardless of the app under test. The README
offered no alternative, which makes the journeys look unrunnable there.

Document the annotate/resolve path that does work, including the
--screenshot flag name (not --screen) and the need to re-capture after
each interaction, since labels are per-screenshot.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@jvsena42
jvsena42 enabled auto-merge July 27, 2026 21:57
@jvsena42
jvsena42 merged commit 2f3aec3 into main Jul 27, 2026
1 check passed
@jvsena42
jvsena42 deleted the docs/journeys-miui-layout-fallback branch July 27, 2026 22:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant