android studio 2.3 instant run not working

前端 未结 11 1287
走了就别回头了
走了就别回头了 2020-12-05 17:17

I have updated android studio from 2.2 to 2.3,then I found Instant run not working.

Error while executing: am startservice com.exampl

相关标签:
11条回答
  • 2020-12-05 17:52

    I had same problem by using Android Studio 2.3.2 and solved the issue by adding these codes in gradle file.

    defaultConfig {
        ...
        minSdkVersion 15
        targetSdkVersion 25
        ...
    
        // Enabling multidex support.
        multiDexEnabled true
    }
    
     dependencies {
         compile 'com.android.support:multidex:1.0.0'
     }
    
    0 讨论(0)
  • 2020-12-05 17:59

    In case you are running a device with MIUI, go to Developer Settings > Turn on MIUI optimization and turn it off.

    You will then need to restart your device and recompile the code.

    Instant Run should then work again

    0 讨论(0)
  • 2020-12-05 18:01


    from 2.3 There is new icon.

    see this.

    0 讨论(0)
  • 2020-12-05 18:02

    If you're using an Asus Zenfone, make sure that the Auto Start Manager doesn't block your app from running.

    0 讨论(0)
  • 2020-12-05 18:04

    Instant Run Documentation:

    To start using Instant Run, you also need to change the build variant to a debug version of your app and deploy it to a target device running Android 5.0 (API level 21) or higher. To learn about more techniques that speed up your build, read Optimize Your Build Speed

    so make sure your build variant is set to 'debug'.

    0 讨论(0)
提交回复
热议问题