Skip to content

Unable to launch Flutter into genymotion android emulator #490

Closed

Description

@sethladd

Genymotion (https://www.genymotion.com/#!/) looks pretty good (and it's what React Native recommends). I tried to use it with Flutter, but got this error:

~/flutter/green_surf_2198 $ flutter start
warning: Unexpected failure parsing device information from adb output:
192.168.56.101:5555    device product:Genymotion model:PREVIEW___Google_Nexus_5X___6_0_0___API_23___1080x1920 device:vbox86p
Please report a bug at http://flutter.io/
severe: Unable to run application - no connected devices.

Activity

  1. modified the milestone: on Nov 21, 2015
  2. sethladd commented on Jan 8, 2016

    @sethladd
    ContributorAuthor

    It seems like I get a little farther, but still not loading. I never see the app itself start on the emulator.

    ~/flutter/testme $ flutter --verbose start
    ~/flutter/testme $ flutter --very-verbose start
    [  32 ms] fine: Downloading toolchain.
    [  64 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb version
    [ 115 ms] fine: Android Debug Bridge version 1.0.32
    Revision eac51f2bb6a8-android
    [ 116 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb devices -l
    [ 142 ms] fine: List of devices attached
    192.168.56.101:5555    device product:vbox86p model:Google_Nexus_5___5_1_0___API_22___1080x1920 device:vbox86p
    [ 174 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb version
    [ 204 ms] fine: Android Debug Bridge version 1.0.32
    Revision eac51f2bb6a8-android
    [ 206 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 start-server
    [ 237 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 shell echo ready
    [ 281 ms] fine: ready
    [ 282 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 shell getprop ro.build.version.sdk
    [ 323 ms] fine: 22
    [ 329 ms] fine: Running stop command.
    [ 330 ms] fine: Running install command.
    [ 331 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 shell pm path org.domokit.sky.shell
    [ 477 ms] info: TODO(iansf): move this log to the caller. SkyShell.apk is not on the device. Installing now...
    Installing SkyShell.apk on device.
    [ 478 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 install -r /Users/sethladd/Code/flutter/bin/cache/artifacts/sky_engine/90ef9fa39c36f4027b82e62262e5c0c43a0466a1/Release/android-arm/SkyShell.apk
    [2374 ms] fine: pkg: /data/local/tmp/SkyShell.apk
    Failure [INSTALL_FAILED_NO_MATCHING_ABIS]
    [2792 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 shell echo -n 37129f04f775267438cd9049330b2fbc2d2f3217 > /data/local/tmp/sky.org.domokit.sky.shell.sha1
    [2818 ms] fine: Running build command for AndroidDevice 192.168.56.101:5555.
    [2823 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 shell am force-stop org.domokit.sky.shell
    [3175 ms] fine: Building /var/folders/00/0v8ph000h01000cxqpysvccm003d2t/T/flutter_toolsQlYRmr/app.flx
    [3250 ms] info: /Users/sethladd/Code/flutter/bin/cache/artifacts/sky_engine/90ef9fa39c36f4027b82e62262e5c0c43a0466a1/Release/darwin-x64/sky_snapshot /Users/sethladd/flutter/testme/lib/main.dart --package-root=packages --snapshot=/var/folders/00/0v8ph000h01000cxqpysvccm003d2t/T/flutter_toolsQlYRmr/snapshot_blob.bin
    [4279 ms] fine: Starting bundle for AndroidDevice 192.168.56.101:5555.
    [4280 ms] fine: AndroidDevice 192.168.56.101:5555 startBundle
    [4280 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 forward tcp:8181 tcp:8181
    [4310 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 logcat -c
    [4347 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 push /var/folders/00/0v8ph000h01000cxqpysvccm003d2t/T/flutter_toolsQlYRmr/app.flx /data/local/tmp/dev.flx
    [4908 ms] info: /Users/sethladd/homebrew/opt/android-sdk/platform-tools/adb -s 192.168.56.101:5555 shell am start -a android.intent.action.RUN -d /data/local/tmp/dev.flx --ez enable-checked-mode true org.domokit.sky.shell/org.domokit.sky.shell.SkyActivity
    [5252 ms] fine: Starting: Intent { act=android.intent.action.RUN dat=/data/local/tmp/dev.flx cmp=org.domokit.sky.shell/.SkyActivity (has extras) }
    Error type 3
    Error: Activity class {org.domokit.sky.shell/org.domokit.sky.shell.SkyActivity} does not exist.
    [5254 ms] fine: Finished start command.
    
    
  3. sethladd commented on Jan 8, 2016

    @sethladd
    ContributorAuthor

    Related: #1154

  4. abarth commented on Jan 9, 2016

    @abarth
    Contributor

    INSTALL_FAILED_NO_MATCHING_ABIS

    How does genymotion work? Is it an x86 build of Android? We don't currently build for x86 android, but we could.

  5. sethladd commented on Feb 18, 2016

    @sethladd
    ContributorAuthor

    Related: #284

  6. eseidelGoogle commented on Feb 23, 2016

    @eseidelGoogle
    Contributor

    To run on x86 android we need to do the following:

    FYI @jason-simmons

  7. karan commented on Mar 1, 2016

    @karan

    Same issue for me (but not the same error).

    Running on a virtual device on Android 5.1.0 (API 22) using Genymotion.

    $ flutter --verbose start
       0 ms • Using Android SDK at /Users/karan/Documents/sdk.
       7 ms • [/Users/karan/Documents/sdk, SDK version 23, build-tools 23.0.2]
      35 ms • xcode-select --print-path
     133 ms • xcodebuild -version
       5 ms • Xcode 7.0
              Build version 7A220
      37 ms • /Users/karan/Documents/sdk/platform-tools/adb devices -l
      26 ms • List of devices attached
              192.168.59.101:5555    device product:vbox86p model:Google_Nexus_5___5_1_0___API_22___1080x1920 device:vbox86p
      10 ms • idevice_id -h
       7 ms • which idevice_id
       0 ms • /usr/local/bin/idevice_id
      15 ms • /usr/local/bin/idevice_id -l
      67 ms • Downloading toolchain.
      83 ms • /usr/bin/defaults read /Users/karan/Desktop/myapp/ios/Info CFBundleIdentifier
       1 ms • com.yourcompany.myapp
      40 ms • /Users/karan/Documents/sdk/platform-tools/adb devices -l
       7 ms • List of devices attached
              192.168.59.101:5555    device product:vbox86p model:Google_Nexus_5___5_1_0___API_22___1080x1920 device:vbox86p
      10 ms • idevice_id -h
      17 ms • /usr/local/bin/idevice_id -l
       5 ms • Running build command.
       0 ms • APK up to date; skipping build step.
       3 ms • Stopping app 'app.apk' on Google Nexus 5, 5 1 0, API 22, 1080x1920.
       1 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 shell am force-stop com.yourcompany.myapp
       1 ms • Running install command.
      52 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 shell cat /data/local/tmp/sky.com.yourcompany.myapp.sha1
       1 ms • 7f5662d033487d4a3b098b9238f84a0ddcf611ea
       1 ms • Starting lib/main.dart on Google Nexus 5, 5 1 0, API 22, 1080x1920...
      42 ms • /Users/karan/Documents/sdk/platform-tools/adb version
       1 ms • Android Debug Bridge version 1.0.32
              Revision 09a0d98bebce-android
      44 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 start-server
      50 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 shell getprop ro.build.version.sdk
      40 ms • 22
     653 ms • /Users/karan/Documents/flutter/bin/cache/artifacts/engine/darwin-x64/sky_snapshot /Users/karan/Desktop/myapp/lib/main.dart --package-root=packages --snapshot=build/snapshot_blob.bin
       6 ms • Building build/app.flx
      19 ms • which zip
       0 ms • KeyPair from privatekey.der: null.
     112 ms • Encoding zip file to build/app.zip
     152 ms • zip -q /Users/karan/Desktop/myapp/build/app.zip snapshot_blob.bin content/ic_add_white_18dp.png content/1.5x/ic_add_white_18dp.png content/2.0x/ic_add_white_18d…
      26 ms • zip -q -0 /Users/karan/Desktop/myapp/build/app.zip AssetManifest.json
     102 ms • Creating flx at build/app.flx.
       0 ms • Built build/app.flx.
       1 ms • Starting bundle for AndroidDevice 192.168.59.101:5555.
       0 ms • AndroidDevice 192.168.59.101:5555 startBundle
      52 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 forward tcp:8181 tcp:8181
      46 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 -s 192.168.59.101:5555 logcat -c
     735 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 push build/app.flx /data/local/tmp/dev.flx
     359 ms • /Users/karan/Documents/sdk/platform-tools/adb -s 192.168.59.101:5555 shell am start -a android.intent.action.RUN -d /data/local/tmp/dev.flx -f 0x20000000 --ez enable-background-compilation true --ez enable-checked-mode true com.yourcompany.myapp/org.domokit.sky.shell.SkyActivity
       0 ms • Starting: Intent { act=android.intent.action.RUN dat=/data/local/tmp/dev.flx flg=0x20000000 cmp=com.yourcompany.myapp/org.domokit.sky.shell.SkyActivity (has extras) }
              Error type 3
              Error: Activity class {com.yourcompany.myapp/org.domokit.sky.shell.SkyActivity} does not exist.
       0 ms • Starting: Intent { act=android.intent.action.RUN dat=/data/local/tmp/dev.flx flg=0x20000000 cmp=com.yourcompany.myapp/org.domokit.sky.shell.SkyActivity (has extras) }
              Error type 3
              Error: Activity class {com.yourcompany.myapp/org.domokit.sky.shell.SkyActivity} does not exist.
       0 ms • Error starting application on Google Nexus 5, 5 1 0, API 22, 1080x1920.
       0 ms • Unable to run application
       0 ms • 'flutter run' exiting with code 2; elasped time 3030ms.
    
  8. eseidelGoogle commented on Mar 3, 2016

    @eseidelGoogle
    Contributor

    OK, x86 emulator support is blocked by dart-lang/sdk#23478

  9. eseidelGoogle commented on Mar 4, 2016

    @eseidelGoogle
    Contributor
  10. eseidelGoogle commented on Mar 9, 2016

    @eseidelGoogle
    Contributor

    So we now correctly build and upload the artifacts. The difficulty will be in wiring them into the flutter_tools.

    I attempted this just now, and the problem I ran into is that the flutter_tools has no path right now for understanding different architectures of android/ios. Currently we have:

    enum TargetPlatform {
      android,
      iOS,
      iOSSimulator,
      mac,
      linux,
    }
    

    But 'android' means 'android arm 32' and 'ios' means 'ios arm 64' and 'iossimulator' means 'ios x86 64'.

    We also now need to support 'android x86 64'. I could do that by adding a new enum like iOSSimulator did, but then we'll just defer the problem until we need 'android arm 64'.

    @devoncarew I'd be curious as to your thoughts.

  11. devoncarew commented on Mar 9, 2016

    @devoncarew
    Contributor

    I'm less familiar w/ this area of the code base. W/o digging in too deeply:

    • each device already reports the platform for its target env. (TargetPlatform get platform)
    • this code will probably have to evolve a bit as our build system gets more sophisticated
    • we may be able to get by for now with different enums? android_arm_32, android_x86_64, ios_arm_32, ios_arm_64, ios_x86_64, ...

    Or perhaps TargetPlatform changes to a class and it has final fields for platform (android/ios), cpu, and word size?

  12. 3 remaining items

  13. eseidelGoogle commented on Jun 14, 2016

    @eseidelGoogle
    Contributor

    I just used flutter run on a genymotion x86 emulator:
    Running lib/main.dart on Google Nexus 5X, 6 0 0, API 23, 1080x1920...

    I believe this can be closed.

  14. ScottPierce commented on Jun 14, 2016

    @ScottPierce

    I just tried this with the latest flutter version through the flutter tool, and I'm getting a crash:

                    flutter  I  Observatory listening on http://127.0.0.1:38042
                             I  Diagnostic server listening on http://127.0.0.1:53337
                      DEBUG  I  #00 pc 0033517c  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #01 pc 000df6a2  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #02 pc 000deb26  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #03 pc 000dec15  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #04 pc 000de786  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #05 pc 00115afd  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #06 pc 000f672c  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #07 pc 000f7123  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #08 pc 000f771d  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #09 pc 001301b7  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #10 pc 0013032a  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #11 pc 000f6c8f  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #12 pc 000fcce7  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #13 pc 000f5b84  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #14 pc 0010bb52  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #15 pc 0010a6c2  /data/app/com.yourcompany.myapp2-1/lib/x86/libsky_shell.so
                             I  #16 pc 000211d8  /system/lib/libc.so (__pthread_start(void*)+56)
                             I  #17 pc 0001c559  /system/lib/libc.so (__start_thread+25)
                             I  #18 pc 00013126  /system/lib/libc.so (__bionic_clone+70)
    
  15. eseidelGoogle commented on Jun 14, 2016

    @eseidelGoogle
    Contributor

    @spierce7 can you give me more info about your setup? Version of genymotion, flutter doctor output, etc? I'm happy to take a look. Might be best to open a new bug and reference this one since this one is getting somewhat long.

  16. ScottPierce commented on Jun 14, 2016

    @ScottPierce
    [✓] Flutter (on Mac OS, channel alpha)
        • Flutter at /Users/spierce7/frameworks/flutter
        • Framework revision 6d2d495369 (8 days ago), engine revision a943c732d5
    
    [✓] Android toolchain - develop for Android devices (Android SDK 23.0.3)
        • Android SDK at /Users/spierce7/Android/sdk
        • Platform android-N, build-tools 23.0.3
        • Java(TM) SE Runtime Environment (build 1.7.0_80-b15)
    
    [✓] iOS toolchain - develop for iOS devices (Xcode 7.3.1)
        • XCode at /Applications/Xcode.app/Contents/Developer
        • Xcode 7.3.1, Build version 7D1014
    
    [✓] Atom - a lightweight development environment for Flutter
        • flutter plugin version 0.2.2
        • dartlang plugin version 0.6.22
    

    I'm on the latest genymotion version (2.7.2). I just updated after I replied on this ticket. I've confirmed the issue is still present after updating. All I'm doing is running flutter create myapp and then running flutter run inside of the app directory.

  17. eseidelGoogle commented on Jun 16, 2016

    @eseidelGoogle
    Contributor

    Hmm. I just tried and it worked for me:

    eseidel@eseidel-macbookpro /tmp/foo %flutter run                                                                                               [/tmp/foo]
    Building APK in debug mode (android-x86)...              
    Warning: signing the APK using the debug keystore.
    Built build/app.apk (9.8MB).
    Installing app.apk to Google Nexus 5X, 6 0 0, API 23, 1080x1920...
    Running lib/main.dart on Google Nexus 5X, 6 0 0, API 23, 1080x1920...
    Observatory listening on http://127.0.0.1:8100
    Diagnostic server listening on http://127.0.0.1:8101
    eseidel@eseidel-macbookpro /tmp/foo %flutter doctor                                                                                            [/tmp/foo]
    [✓] Flutter (on Mac OS, channel unknown)
        • Flutter at /src/flutter
        • Framework revision 6d2d495369 (10 days ago), engine revision a943c732d5
    
    [✓] Android toolchain - develop for Android devices (Android SDK 23.0.2)
        • Android SDK at /Users/eseidel/Library/Android/sdk
        • Platform android-23, build-tools 23.0.2
        • Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
    
    [✓] iOS toolchain - develop for iOS devices (Xcode 7.3.1)
        • XCode at /Applications/Xcode.app/Contents/Developer
        • Xcode 7.3.1, Build version 7D1014
    
    [✓] Atom - a lightweight development environment for Flutter
        • flutter plugin version 0.2.3
        • dartlang plugin version 0.6.26
    

    I'll figure out how to get a symbolicated version of that stack trace.

  18. eseidelGoogle commented on Jun 17, 2016

    @eseidelGoogle
    Contributor

    Here is the stack @spierce7 is hitting:

    addr2line -e out/android_debug_x86/libsky_shell.so  0033517c 00df6a2 000deb26 000dec15 000de786 00115afd 000f672c 000f7123 000f771d 001301b7 0013032a 000f6c8f 000fcce7 000f5b84 0010bb52 0010a6c2 000211d8 0001c559 00013126
    
    /src/engine/src/out/android_debug_x86/../../third_party/skia/src/gpu/GrContext.cpp:766
    /src/engine/src/out/android_debug_x86/../../sky/shell/gpu/direct/ganesh_canvas.cc:37 (discriminator 1)
    /src/engine/src/out/android_debug_x86/../../sky/shell/gpu/direct/rasterizer_direct.cc:161 (discriminator 1)
    /src/engine/src/out/android_debug_x86/../../sky/shell/gpu/direct/rasterizer_direct.cc:64
    /src/engine/src/out/android_debug_x86/../../base/bind_internal.h:176 (discriminator 5)
    /src/engine/src/out/android_debug_x86/../../base/callback.h:396 (discriminator 1)
    /src/engine/src/out/android_debug_x86/../../base/message_loop/message_loop.cc:481
    /src/engine/src/out/android_debug_x86/../../base/message_loop/message_loop.cc:490
    /src/engine/src/out/android_debug_x86/../../base/message_loop/message_loop.cc:602
    /src/engine/src/out/android_debug_x86/../../mojo/message_pump/message_pump_mojo.cc:162
    /src/engine/src/out/android_debug_x86/../../mojo/message_pump/message_pump_mojo.cc:126
    /src/engine/src/out/android_debug_x86/../../base/message_loop/message_loop.cc:445 (discriminator 1)
    /src/engine/src/out/android_debug_x86/../../base/run_loop.cc:55
    /src/engine/src/out/android_debug_x86/../../base/message_loop/message_loop.cc:288
    /src/engine/src/out/android_debug_x86/../../base/threading/thread.cc:198
    /src/engine/src/out/android_debug_x86/../../base/threading/platform_thread_posix.cc:74
    ??:0
    ??:0
    ??:0
    
  19. eseidelGoogle commented on Jun 17, 2016

    @eseidelGoogle
    Contributor
    void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) {
        ASSERT_SINGLE_OWNER
        fResourceCache->setLimits(maxTextures, maxTextureBytes); // line 766 in google/skia@8cc209111876b7c78b5ec577c9221d8ed5e21024
    }
    
  20. eseidelGoogle commented on Jun 17, 2016

    @eseidelGoogle
    Contributor

    I'm going to move this to a new bug for clarity.

  21. eseidelGoogle commented on Jun 17, 2016

    @eseidelGoogle
    Contributor

    Moving @spierce7's issue to #4611

  22. github-actions commented on Aug 17, 2021

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  23. locked as resolved and limited conversation to collaborators on Aug 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

toolAffects the "flutter" command-line tool. See also t: labels.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions