Recent Changes

The following features and bug fixes were recently checked in. For complete details, see the git changelogs at

Android Studio 2.0 Beta 3 Available in Canary Channel

posted by Tor Norbye

We've just pushed Android Studio 2.0 Beta 3 to the canary channel. We've also released 2.0.0-beta3 of the Android Gradle plugin (it's not available on jcenter yet, but it's bundled with the IDE and is used from in-IDE builds.)

This build fixes a number of issues in beta 2.

If all goes according to plan, we hope to roll this out to the beta channel in a few days. Thanks for testing our preview builds, and please continue reporting bugs!  (via Help > Submit Feedback.)

Installation
You can update your current 2.0 Preview installation to 2.0 Beta 3 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Beta via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Beta from the Android Studio 2.0 Beta 3 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.

Android Studio 2.0 Beta 2 Available in Canary Channel

posted Feb 4, 2016, 4:29 PM by Tor Norbye

We've just pushed Android Studio 2.0 Beta 2 to the canary channel.

This fixes an Instant Run related bug we discovered right after rolling beta 1 out. 

Please give beta 2 a try; we believe we've fixed several critical issues that have prevented builds from working for a number of users in earlier previews:
  • Performance regression: Many users reported that the initial build in 2.0 was much slower than in 1.5. Turns out this was related to the way we packaged all dependencies into a single dex file (since those are unlikely to change for Instant Run purposes). However, this actually made dex much slower in some scenarios due to the way dex merging works internally.
  • Dagger2 and other annotation-processor based libraries and plugins: In 2.x we've been using the new "incremental Java compilation" feature in Gradle, but this feature does not work well with annotation processor. In beta2, we automatically turn off incremental compilation if a project appears to be using annotation processors through the "android-apt" plugin. Manually wired processors will still fail (see https://github.com/google/dagger/issues/298).
  • We also fixed a couple of other Instant Run bugs; see in particular the below notice about uninstalling your app once.
  • Finally, there were a couple of bugs in the SDK manager which prevented the IDE from starting if you had add-ons installed with multiple system images.

Please note: You should uninstall your debug app from your device/emulator once, after updating to 2.0 Beta. This will remove some bad application state on the device that can affect Instant Run. We've fixed the bug which wrote the bad state in the first place, but this doesn't retroactively remove it from application state already on the device.

If all goes according to plan, we hope to roll this out to the beta channel in a few days, but we would highly appreciate feedback on this canary channel as soon as possible, in particular for Instant Run, to know whether it's really ready for beta on your real world applications.
Thanks for testing our preview builds, and please continue reporting bugs!  (via Help > Submit Feedback.)

Installation
You can update your current 2.0 Preview installation to 2.0 Beta via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Beta via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Beta from the Android Studio 2.0 Beta 2 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.

Android Studio 2.0 Beta Available in Canary Channel

posted Feb 3, 2016, 1:57 PM by Tor Norbye   [ updated Feb 4, 2016, 4:36 PM ]

[Edited Feb 4th: We've released a new build ("beta 2") which fixes the beta 1 blocking bug. Please see the beta 2 announcement.]

[Edited Feb 3rd: We just discovered a potential blocker in this build. We're pulling the update until we've verified (or fixed) the issue.]

Previous:

We've just pushed Android Studio 2.0 Beta to the canary channel -- along with 2.0.0-beta1 of the Gradle plugin to jcenterIf all goes well, we'll roll it out to the beta channel within a couple of days.

This build contains only critical bug fixes relative to 2.0 Preview 9 from last week.

Thanks for testing our preview builds, and please continue reporting bugs!  (via Help > Submit Feedback.)

Installation
You can update your current 2.0 Preview installation to 2.0 Beta via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Beta via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Beta from the Android Studio 2.0 Beta page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.

Android Studio 2.0 Preview 9 Available

posted Jan 29, 2016, 4:20 PM by Tor Norbye

We've just pushed Android Studio 2.0 Preview 9 to the canary channel -- along with 2.0.0-alpha9 of the Gradle plugin to jcenter (and as part of the bundled offline repository within the IDE).

In this release, we've completely turned off in-memory dexing by default. We've spent the last couple of previews trying to fine-tune it, but there are lingering issues which continues to affect users. This should hopefully make the builds work a lot better for many of you. (If things were already working well, you can continue with in-memory dexing by turning it on with android.dexOptions.dexInProcess=true.)

We've also continued to fix various Instant Run scenarios; in particular, using APK splits on API 23 seems to trigger some platform bugs, so for now we've switched over to using multidex for coldswap for both Lollipop and Marshmallow. 

(Release notes for the Gradle plugin will appear here.)

Thanks for testing our preview builds, and please continue reporting bugs (via Help > Submit Feedback).

Installation
You can update your current 2.0 Preview installation to Preview 9 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview from the Android Studio 2.0 Preview 9 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.

Android Studio 2.0 Preview 8 Available

posted Jan 27, 2016, 8:51 PM by Tor Norbye

We've just pushed Android Studio 2.0 Preview 8 to the canary channel, as well as a new version of the Gradle plugin: 2.0.0-alpha8.  You'll want to update both; instant run in particular is only enabled when using the latest versions of both:
This preview contains a number of important fixes relative to preview 7. In particular, a number of users have reported either really slow build times or failed builds using version 2.x of the Gradle plugin. The likely culprit for this is that in 2.x we've switched to perform dexing inside the build process, instead of running dex in an external process (because this not only makes incremental builds much faster, but also significantly speeds up full builds). However, the dex process had a larger default heap size than the Gradle daemon, which means that unless you've configured Gradle to run with more memory, the builds can be much more memory constrained which can severely slow down builds (or even make them fail running out of memory).

In 2.0.0-alpha8 we've added some automatic diagnostics for this: if the build process is too small, we switch back to out-of-memory dexing and emit a build warning explaining how to bump up the Gradle daemon size. (We're also working on some additional related improvements for the next build after alpha8.)
Preview 8 also continues to fix user reported bugs for Instant Run. Among a number of stability fixes, we've also turned off "cold swap" when running on a pre-Lollipop device; incompatible changes will trigger a normal/full build. "Hot swap" still works on all API levels >= 15.

Thanks to everyone for their patience helping us track down these problems!

Installation
You can update your current 2.0 Preview installation to Preview 8 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview from the Android Studio 2.0 Preview 8 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.


Android Studio 2.0 Preview 7 Available

posted Jan 22, 2016, 6:27 PM by Tor Norbye   [ updated Jan 23, 2016, 7:59 AM ]

We've just pushed Android Studio 2.0 Preview 7 to the canary channel. This contains a number of bug fixes on top of preview 6, particularly in the Instant Run area (there is also a 2.0.0-alpha7 version of the Gradle plugin). This build also incorporates IntelliJ IDEA 15.0.3, which brings a number of critical IDE fixes from JetBrains. The release notes for the various 15.0.3 milestone builds we're incorporating are 1, 2, 3, and 4.

Installation
You can update your current 2.0 Preview installation to Preview 7 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview from the Android Studio 2.0 Preview 7 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.


Android Studio 2.0 Preview 6 Available

posted Jan 20, 2016, 10:04 AM by Tor Norbye

We've just pushed Android Studio 2.0 Preview 6 to the canary channel. This contains a week's worth of bug fixes since Preview 5 last week. 

Installation
You can update your current 2.0 Preview installation to Preview 5 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview from the Android Studio 2.0 Preview 6 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.

Android Studio 2.0 Preview 5 Available

posted Jan 14, 2016, 10:46 AM by Tor Norbye

We've just pushed Android Studio 2.0 Preview 5 to the canary channel. This build contains a large number of fixes relative to Preview 4 from last month, including
  • Instant Run: We've made a huge number of changes in this area. Among the user visible features, we now support "cold swap": if there is an incompatible change that can't be hot swapped, it now builds and deploys incremental changes and restarts the app. We use several different methods for this, depending on the API level of the target device:
    • On Android Marshmallow, we use "APK splits", dividing the codebase up into slices that are packaged as individual APK slices, and install these via adb install-multiple. This means that on M, we don't need to use the class loader tricks that we use on older platforms.
    • On Android Lollipop, we use multidex to split the app code into dex slices, and push those.
    • On Android KitKat and below, we create a single dex file containing the changed classes.
    • In addition to "coldswap", which restarts a running app after applying incompatible changes, we also support "freeze swap" where we support building incrementally even when the app isn't originally running. In that case, we push the changes via adb to an "inbox" directory on the device.
    • Note that Instant Run now requires a new version of the Gradle plugin: 2.0-alpha5 (also released today) - release notes for the plugin
  • Lint
    • There is a new "Remove Unused Resources" refactoring which finds and removes unused resources in the project.
    • The unused resource detector has been rewritten, and now supports flagging "transitive" unused resources (resources that are referenced, but only from other unused resources), supports detecting resource references in raw files such as .html image references, and supports the tools:keep and tools:discard attributes used by the Gradle resource shrinker, it considers inactive source sets (e.g. resources defined in other product flavors and build types), and properly handles static field imports. It now also has a quickfix for removing unused resources.
    • Implicit API checks. Until now, lint has checked that method calls and field references are supported on all platforms targeted by your minSdkVersion. However, there are a number of classes that have started implementing new interfaces, such as Closeable, in later levels - or that have even changed which super class they extend. For example, KeyEvent only has InputEvent as a super class as of API 9. That means that in all the places where you have an implicit or explicit cast, you also have a potential crash. Lint now tracks these API changes and checks all implicit casts:
    • Several new lint checks - one looking for a common pitfall in RecyclerView usage, one looking for a potential crash with Parcelable loading, as well as 8 lint checks ported from bytecode analysis to in-IDE analysis such that they can run in the background in the editor.
    • The @IntDef, @IntRange and @Size inspections are now checked not just for primitive ints, but for int arrays and varargs as well.
    • A number of other miscellaneous improvements, such as lint now running even when there are syntax errors in the current file being edited, exposing lint issue categories in the IDE analysis window, fixes to make third party lint rules (provided from AAR libraries) work better inside the IDE, etc.
  • Data binding: The XML editor now support code completion for data binding expressions.
  • Test Artifacts: The experimental test artifacts feature (where both unit test and instrumentation tests are enabled simultaneously in the IDE) has been improved further and is now enabled by default.
  • Code completion inside style tags should now work better; it looks up the parent styles and suggests eligible items.
  • We've also been working on improving the accessibility support, as well as infrastructure work on the SDK manager and the wizard infrastructure.
  • And as always - a large number of bug fixes. Please let us know if there are new problems, or if the fixes aren't working correctly!

Installation
You can update your current 2.0 Preview installation to Preview 5 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview from the Android Studio 2.0 Preview 5 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.

Android Studio 2.0 Preview 4 Available

posted Dec 17, 2015, 5:00 PM by Tor Norbye   [ updated Dec 17, 2015, 5:00 PM ]

We've just pushed Android Studio 2.0 Preview 4 to the canary channel. This contains a week's worth of bug fixes since Preview 3 last week. The most notable change is an update to IntelliJ 15.0.2 in the base IDE, which picks up a number of fixes from JetBrains:
There are also some changes to support the next emulator preview build.

Installation
You can update your current 2.0 Preview installation to Preview 4 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview e from the Android Studio 2.0 Preview 4 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary

Android Studio 2.0 Preview 3 Available

posted Dec 10, 2015, 1:30 PM by Tor Norbye   [ updated Dec 10, 2015, 6:39 PM by J. Eason ]

We've just pushed Android Studio 2.0 Preview 3 to the canary channel. 

This build contains a large number of bug fixes, along with the following notable changes:
  •  A new lint check which looks at switch statements used in concert with @IntDef integers, and makes sure that all constants from the @IntDef are handled:
    Note that there is a quickfix for adding the missing statements as well, so after adding an empty switch statement this is a quick way to populate the initial set of case statements:
  • A new lint check which flags incorrect attempts to insert version numbers in Gradle file using String interpolation. This will automatically flag this "gotcha"
  • Lint now flags anonymous classes that extend Fragment
  • Two new security lint checks contributed by Michael Peck: One which looks for native code in unsafe locations (such as asset folders), and another which flags Runtime.load() and System.load() calls.
  • The translation editor now supports speed search (and F2 to enter cell editing).
  • We've also tweaked the Instant Run facility such that when changes can't be hotswapped, there's a confirmation dialog before restarting the app. We'll be tweaking this in the next preview build.
  • Various improvements to the AVD Manager to support the new Android Emulator
Installation
You can update your current 2.0 Preview installation to Preview 3 via the built-in patch mechanism (Check for Updates).
You can also update from 1.5 to 2.0 Preview e via the patch mechanism, but you may not want to do that: See our page about how to keep multiple installations simultaneously while Studio is in preview mode.
You can also download a full zip of 2.0 Preview e from the Android Studio 2.0 Preview 3 page.

Problems?
If you run into problems, be sure to check the Known Issues page which we'll update as necessary.


1-10 of 251