You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Taps do nothing on an Android emulator turned on its side while the app stays portrait #42877
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Area
Device panel (Android emulators, serve-emu in expo-device-hub 0.26.1)
Steps to reproduce
Open a Pixel 7 API 34 emulator in the Device panel.
Use Rotate device → Landscape while the home screen (portrait-locked launcher) is showing.
The emulator is now physically landscape (adb emu sensor get acceleration → 9.81:0:0) while Android's display stays portrait (dumpsys display viewport orientation=0). The stream shows the portrait UI turned on its side.
Tap any app icon in the panel.
Expected behavior
The tap lands on the icon under the pointer.
Actual behavior
Nothing happens. With Android's pointer-location overlay on, no touch registers anywhere on screen. This happens with serve-emu's default inputSource: "scrcpy" and with inputSource: "grpc", and with or without a wm size override.
Cause (from reading serve-emu 0.26.1)
serve-emu scales normalized touches by the native touch size it reads from the emulator screenshot (grpc-session.js, nativeTouchSize). In this state that screenshot is landscape (2400x1080). Android expects coordinates in the portrait display space (1080x2400), so a tap at normalized x = 0.6 becomes x = 1449, past the 1080 px display width, and is dropped. The client cannot correct for it because serve-emu rejects normalized values outside 0..1. The fix likely belongs in expo-device-hub's input mapping (map frame coordinates through the emulator's physical rotation), with any T3 Code side follow-up after a hub bump.
Impact
Major degradation or frequent failure: the emulator cannot be used by touch until it is rotated back.
Version or commit
Found while working on fix/simulator-fill-foldable-screen (base c478fde); serve-emu from expo-device-hub 0.26.1.
Environment
macOS, local device host, Android Emulator API 34 (Pixel 7 and Pixel Fold AVDs).
Workaround
Rotate the emulator back to portrait from the Device panel, or open an app that supports landscape.
Confirmed cause: the gRPC frame is the panel turned by the emulator's physical rotation, gRPC sendTouch takes unrotated panel pixels, and scrcpy injects in Android's display pixels. serve-emu treated all three as one. The same bug also breaks gRPC input in any app that rotates with a turned emulator, and scrcpy input after the hub's own POST /api/orientation lock.
T3 Code can't work around it on its side. The client can't send the needed values, because serve-emu rejects coordinates outside 0..1. Switching Rotate to user-rotation lock would only produce the mirror case.
Verified on a Pixel 7 API 34 emulator with both input sources. In all four poses, tapping the Phone icon on the launcher starts the dialer, and swipe traces are correct in both mismatch cases.
T3 follow-up once a hub release includes it: bump the hub. If the wm size touch compensation in SCRCPY_DISPLAY_TOUCH_HUBS has landed by then, keep it for the new version, because expo/expo-device-hub#663 does not change wm size scaling. Recheck its turned-frame touch mapping too.
Activity
ipanasenko commentedon Nov 25, 2026
Note
🤖 Written by Claude Opus 5.5 on behalf of Illia
The fix belongs in the hub: expo/expo-device-hub#663 (draft).
Confirmed cause: the gRPC frame is the panel turned by the emulator's physical rotation, gRPC
sendTouchtakes unrotated panel pixels, and scrcpy injects in Android's display pixels. serve-emu treated all three as one. The same bug also breaks gRPC input in any app that rotates with a turned emulator, and scrcpy input after the hub's ownPOST /api/orientationlock.T3 Code can't work around it on its side. The client can't send the needed values, because serve-emu rejects coordinates outside 0..1. Switching Rotate to
user-rotation lockwould only produce the mirror case.Verified on a Pixel 7 API 34 emulator with both input sources. In all four poses, tapping the Phone icon on the launcher starts the dialer, and swipe traces are correct in both mismatch cases.
T3 follow-up once a hub release includes it: bump the hub. If the
wm sizetouch compensation inSCRCPY_DISPLAY_TOUCH_HUBShas landed by then, keep it for the new version, because expo/expo-device-hub#663 does not changewm sizescaling. Recheck its turned-frame touch mapping too.