0

I use the Android studio 2.0, and configure the project with the official doc , the config of instant run in the setting window of AS has changed from disabled to enabled state. As well the run icon has lightning now,but when i change the code, just add a toast in a function, and click the lightning run, the application will be exit, and log show like below:

11-24 19:59:40.382 20951-20957/com.ss.android.essay.joke I/art: System.exit called, status: 1
11-24 19:59:40.383 20951-20957/com.xxx I/AndroidRuntime: VM exiting with result code 1, cleanup skipped.
11-24 19:59:40.475 4922-14521/? I/WindowState: WIN DEATH: Window{651bd86 u0 com.ss.android.essay.joke/com.xxx.MainActivity}

Edit:The status of bug has updated,crash not happened again with alpha2,but still can't use instant-run, more detail:https://code.google.com/p/android/issues/detail?id=195064

Edit: Android studio 2.1.1 with 2.12 gradle work well now.

dreamtale
  • 2,905
  • 1
  • 26
  • 38

1 Answers1

0

Pretty sure your change is not covered by Instant Run, check out Android tools site for a list of supported hot swap actions: enter image description here

Kai
  • 15,284
  • 6
  • 51
  • 82
  • 1
    why not covered? The code change is just adding a toast in the instance method. As well, it work in the sample project. – dreamtale Nov 25 '15 at 03:33
  • It's still in development, there are still plenty of rooms to grow and bugs to squash. If you believe this is a bug then you can file a bug report: http://tools.android.com/filing-bugs – Kai Nov 25 '15 at 03:35
  • @Kai Why are you assuming his change is not covered by Instant Run? – IgorGanapolsky Dec 21 '15 at 05:24