Android Studio Instant Run is not enabled?
Asked Answered
O

6

9

Instant Run is a new feature introduced for reduce time for run and debug app. I have all the required configuration for enabling Instant run, but it is not enabled on Android Studio. Here is my configuration below.

1. Android Studio 2.1
2. 'com.android.tools.build:gradle:2.1.0'
3. minSdkVersion 15
4. Settings->Build, Execution, Deployment > Instant Run = "Enable Instant Run..."
5. Run ->device is  Android version 4.4.4

Then Instant Run is NOT enabled. enter image description here

But when I am Run->on device Android Version 5.1.1, Instant Run is enabled.enter image description here

Please suggest, if some other configuration I missed to enable Instant run for Android 4.4.4 device.

Oyster answered 8/5, 2016 at 17:28 Comment(1)
I was keep on exploring and found the reason. When next time I run, I got the message: - Instant Run is disabled: Instant Run does not support deploying build variants with multidex enabled, to a target with API 20 or below. To use Instant Run with a multidex enabled build variant, deploy to a target with API level 21 or higher. And in the above configuration, I missed to mention, multidex is enabled, that's why Instant Run is disabled.Oyster
F
4

When you are running for the first time Instant Run is not required as the apk will be installed for the first time in the selected device. From the second time onward if you choose the same device to deploy your changes then instant run will be automatically enabled from Android studio 2.0 and Gradle version 2.0.

Please Note: You are required to run in debug mode.

For more Clear understanding you may visit this link

Fluxmeter answered 8/5, 2016 at 17:37 Comment(0)
N
0

Instant Run is supported only while deploying a debug build variant, using Android Plugin for Gradle version 2.0.0 or higher, and targeting devices running Android 4.0 (API level 15) and higher.

Nauseous answered 8/5, 2016 at 18:35 Comment(0)
V
0

This answer solved the problem in my case.

you have missed the Fingerprint Certificate Authorization dialog in your phone when you connected it, try to change the USB mode to Media, or another different than the one you have in and then reconnect your device, or go to Developer Options -> Revoke USB Debugging and reconnect, watch for the dialog and click on accept, that should solve your problems.

Otherwise, try this:

set your ANDROID_SDK_HOME again and:

unplug device adb kill-server adb start-server plug device

Voluptuary answered 28/3, 2018 at 5:55 Comment(0)
A
-1

Try to recreate project, but do not use spaces in the fullpathname.

Anjanetteanjela answered 18/10, 2018 at 13:40 Comment(0)
P
-2

Go to sdk manager and select API Level 15 which is Android 4.0.3 (IcecreamSandwich) under SDK Platforms. This fixed my problem.

Pajamas answered 30/6, 2017 at 17:12 Comment(0)
C
-3

For me the problem was the link cable, it seems like it had an unstable connection. I used another one and it worked without a problem.

Cleanshaven answered 21/11, 2017 at 13:37 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.