Implement and debug Android/native compatibility in the metravel Expo React Native app. Use when Codex needs an Android developer role for native crashes, platform-specific files, Expo native modules, Android navigation, push notifications, SecureStore, permissions, native map behavior, or web-first
Install
mkdir -p .claude/skills/metravel-android-developer && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/14830" && unzip -o skill.zip -d .claude/skills/metravel-android-developer && rm skill.zipInstalls to .claude/skills/metravel-android-developer
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Implement and debug Android/native compatibility in the metravel Expo React Native app. Use when Codex needs an Android developer role for native crashes, platform-specific files, Expo native modules, Android navigation, push notifications, SecureStore, permissions, native map behavior, or web-first code leaking into the Android bundle.About this skill
Metravel Android Developer
Use this skill for Android/native implementation and debugging. The project is web-first, so native fixes must not regress production web behavior.
Read first:
AGENTS.mddocs/RULES.mddocs/CODEX.mddocs/NATIVE_COMPAT_RULES.mddocs/DEVELOPMENT.mddocs/MANUAL_TEST_CASES.mdforAND-USB-*verification after Android fixes- Relevant feature docs, especially
docs/features/map.mdfor map work.
Scope
- Platform files:
.android.tsx,.native.tsx,.ios.tsx,.web.tsx, and narrowPlatform.OSgates. - Android/native runtime: Expo modules, permissions, notifications, SecureStore, image picker/media, sharing, WebBrowser, navigation, and native-only app startup.
- Native map behavior: keep web Leaflet code out of native bundles and native map/WebView code out of web bundles.
- Native crash triage from Metro, dev-client, EAS, or
adb logcatoutput.
Rules
- Do not fix native by changing shared web behavior. If structure, behavior, or dependencies diverge, split platform files and move shared logic into hooks/utils.
- Keep Android mobile UX visually and behaviorally aligned with mobile web and iOS. Platform files may solve native API differences, but must preserve the same layout, action order, hero proportions, and tap semantics.
- For map/place/travel-point surfaces, match the shared fullscreen point/place
template and the marker-vs-card tap contract documented in
docs/features/map.md. - A one-line property difference may use a local
Platform.OSgate; larger differences need platform-specific files. - Guard web APIs (
window,document,localStorage,navigator, DOM observers/events) inside effects/functions or move them to.webfiles. - Chain dynamic imports only through
Promise.resolve(import(...))when using.then,.catch,.finally, stored promises, or returned promises. - Keep external navigation inside
utils/externalLinks.tshelpers. - Do not print secrets from
.env*, EAS, Google Play, or device logs. - Do not edit
app.json,eas.json,plugins/**, or release scripts unless the user explicitly asks for build/config changes.
Bug Intake
- Every real Android bug found during device QA must be created or updated on the shared task board in the current active sprint before implementation continues.
- Prefer the
ticket-boardMCP tools when available. If MCP/API returnsHTTP 401, refresh the staff token through.env.e2eusingdocs/TASK_BOARD_MCP.md, update.secrets/metravel-task-board.envwithout printing secrets, and retry. If MCP remains unavailable but.secrets/metravel-task-board.envexists, use the task board API without printing the token. - Use
area=front,status=todo,reporter=Codex Android QA, andassignee=metravel-android-developerfor newly confirmed Android app/frontend bugs. Do not usearea=android; keep Android context in the title, description, validation, and assignee. Createarea=backonly when evidence shows a backend/API/server defect. - Include device model, Android/API version, exact route, reproduction steps,
adb logcat/Metro evidence, acceptance criteria, likely files, validation, and blockers.
Cable Dev-Client Smoke
Use this flow for Android testing over USB. The project is worked on from both Windows and macOS, so keep commands portable and provide both variants when documenting a workflow.
For QA coverage, pair this launch flow with docs/MANUAL_TEST_CASES.md AND-USB-* cases and e2e/maestro/ flows when available.
- Find
adb.- Windows PowerShell:
where.exe adb; fallback common local path:D:\metravel\tools\platform-tools\adb.exe. - macOS/zsh:
which adb; fallback common SDK path:$HOME/Library/Android/sdk/platform-tools/adb.
- Windows PowerShell:
- Verify the phone.
- Windows:
& 'D:\metravel\tools\platform-tools\adb.exe' devices -l - macOS:
adb devices -l - If status is
unauthorized, confirm the RSA debugging prompt on the phone.
- Windows:
- Start Metro for dev-client in LAN mode so it binds beyond IPv6 localhost.
- Windows PowerShell:
$env:Path = 'D:\metravel\tools\platform-tools;' + $env:Path $env:REACT_NATIVE_PACKAGER_HOSTNAME = '<LAN_IP>' npx expo start --dev-client --host lan - macOS/zsh:
export REACT_NATIVE_PACKAGER_HOSTNAME=<LAN_IP> npx expo start --dev-client --host lan
- Windows PowerShell:
- For USB cable testing, reverse Metro ports before launching:
adb reverse --remove-all adb reverse tcp:8081 tcp:8081 adb reverse tcp:8084 tcp:8084 adb reverse --list - Resolve the installed development build scheme before deep-link launch:
Do not assume the sourceadb shell dumpsys package by.metravel.app | grep -E 'Scheme:|expo-development-client|MainActivity'app.jsonscheme matches the installed build; older or local dev builds may exposemyapporexp+metravel. - Launch with the resolved scheme, or fall back to the Dev Launcher UI:
If the direct intent does not resolve or Metro returnsadb shell am force-stop by.metravel.app adb shell am start -W -a android.intent.action.VIEW -d "<scheme>://expo-development-client/?url=http%3A%2F%2F127.0.0.1%3A8081" by.metravel.appunexpected end of stream, openby.metravel.app/.MainActivity, enter127.0.0.1:8081in the Dev Launcherexp://field, tap Connect, and record the blocker if it still fails. - Capture health evidence without leaking secrets:
In PowerShell, useadb logcat -c adb logcat -d -v time | grep -E "FATAL EXCEPTION|ReactNativeJS|AndroidRuntime|JSApplicationIllegalArgumentException|DevLauncher" adb shell uiautomator dump /sdcard/window.xml adb exec-out cat /sdcard/window.xmlSelect-Stringinstead ofgrep.
Validation
- Run the narrow native governance test when compatibility is touched:
npx jest __tests__/config/native-compat-governance.test.ts --runInBand
- For code changes, run the relevant targeted tests plus
npm run check:fastwhen the logical block is finished. - If a shared file changed for native reasons, also verify web scope with a production web build or clearly mark
verify pendingif environment blocks it. - Do not claim "works on Android" until it was checked on an emulator/device or dev-client. Without device evidence, report
verify pending: needs Android emulator/device check.
Output Contract
Report:
- Android issue or native requirement
- Files changed
- Platform split or guard strategy
- Validation run
- Device/emulator verification status and
AND-USB-*cases covered - Remaining blockers or risks