Fixed
Status Update
Comments
ce...@gmail.com <ce...@gmail.com> #2
Happening the same here. I'm trying to debug the ImageView source and there is no way to do it. I use breakpoints everywhere but they're all wrong whenever the debugger stops. I've been trying to do the same as the guy who opened the issue, in the same order, but I got nothing :(
yu...@google.com <yu...@google.com>
te...@gmail.com <te...@gmail.com> #3
There is simple hack for this, in android-sdk/sources rename android-<target_api> to android-<target_api>_ and android-<device_api> to android-<target_api>. Then Android Studio will be taking sources from fake e.g. android-23 sources folder
vs...@google.com <vs...@google.com>
da...@gmail.com <da...@gmail.com> #6
According to my notes , suggestion #6 did not fix the issue. See my original post here (https://code.google.com/p/android/issues/detail?id=200919#c2 ). It is possible that I made a careless error while in a fit of rage over not being able to set the source code path. I'll try it again the next time this comes up (I spend most of my time in XCode).
vs...@google.com <vs...@google.com> #7
This should be fixed in 2.2. As long as you have the sources downloaded, Studio should pick up the sources at that API level.
vi...@gmail.com <vi...@gmail.com> #9
This doesn't seem to work in Studio 2.2 Preview 3. Is there anything else I need to do apart from ensuring the right sources are installed?
vs...@google.com <vs...@google.com> #10
Please file a new bug and include your idea.log.
na...@gmail.com <na...@gmail.com> #11
It seems that the issue was fixed for debugging, but not fixed for Logcat. When I click on the highlighted lines in Logcat output, Android Studio jumps to the version of SDK source code which is specified for compileSdkVersion.
Description
Android Studio (Beta) 0.8.12
Build #AI-135.1503853, built on October 9, 2014
JRE: 1.7.0_60-ea-b15 amd64
JVM: Java HotSpot(TM) 64-Bit Server VM by Oracle Corporation
Issue:
I've been trying to figure out how to debug through android source code in cases that the device is not running under the target SDK but a lower api level.
Here is an example to clarify the issue:
targetSdkVersion = 19
compileSdkVersion = 19
Device running SDK 16
When I try to debug through the android source code, the attached source code belongs to the target sdk version (in this case 19). As you can imagine the source code does not match the running device sdk level (in this case 16), so it's almost impossible to have a real debugging session.
The same happens when setting up the project to:
targetSdkVersion = 16
compileSdkVersion = 16
In debugging sesion the attached android source code belongs to the api 19
I guess AS always uses the highest api level source code available for debugging session