ExpoのアプリがAndroidシミュレータでCommandError No development build for this project is installed. といわれて動作しなかったときの対応メモ

状況 Link to this heading

npx expo run:androidを実行した際に自動で起動するAndroidエミュレータ端末では問題なく動作する。しかし、その後にShift+aを押して別の端末を選ぶと、次のエラーが発生し、アプリが動作しなかった。

√ Select a device/emulator » Pixel_Tablet_API_35 (emulator)
› Opening emulator Pixel_Tablet_API_35
CommandError: No development build (com.name.XXXXXXXXXX) for this project is installed. Please make and install a development build on the device first.
Learn more: https://docs.expo.dev/development/build/

解決策 Link to this heading

まず、すべてのエミュレータを一度終了し、起動したいエミュレータを起動する。たとえば、起動したいエミュレータがPixel_Tablet_API_35である場合、以下のコマンドを実行する。

emulator -avd Pixel_Tablet_API_35

エミュレータが完全に起動したら、以下のコマンドを実行して、エミュレータに直接インストールする。

npx expo run:android --device

デバイス選択のプロンプトが表示されたら、起動したいエミュレータ(e.g. Pixel_Tablet_API_35)を選択する。 これでアプリが動作するようになった。

Licensed under CC BY-NC-SA 4.0
最終更新 2月 24, 2025
Hugo で構築されています。
テーマ StackJimmy によって設計されています。