Fixed
Status Update
Comments
ar...@google.com <ar...@google.com> #2
We use build flavours heavily with a lot of common code. The refactoring support in AS is really good but it continually catches us out when it doesn't work across all flavours in a project. It's a big gap for serious product development.
ko...@gmail.com <ko...@gmail.com> #3
We at my company need this same feature. We have a lot of white labels and need refactor the same class across flavours. :(
ko...@gmail.com <ko...@gmail.com> #4
I need this feature too...
ar...@google.com <ar...@google.com> #5
+1, I need this very badly
ko...@gmail.com <ko...@gmail.com> #7
Can we atleast know the status of the issue please? Will it be fixed or is it in low priority. It's been 4 years.
Description
Version used: 25.3.1
Devices/Android versions reproduced on: Marshmallow
- Relevant code to trigger the issue. Create application using 25.3.x support library and try to update previous version from the application using it.
Description: 25.3.x support libraries broke application update as they include meta-data information which merges wrong position in APK AndroidManifest.xml This causes application update to fail in parse error.
from android logcat
PackageParser: Unknown element under <manifest>: meta-data at line 21
looking with aapt tool from created APK
A: android:name(0x01010003)="android.permission.MANAGE_USB" (Raw: "android.permission.MANAGE_USB")
E: meta-data (line=21)
A: android:name(0x01010003)="android.support.VERSION" (Raw: "android.support.VERSION")
A: android:value(0x01010024)="25.3.1" (Raw: "25.3.1")
E: application (line=25)
And if look from android studio app/build/intermediates/manifests/full/release/AndroidManifest.xml
<uses-permission android:name="android.permission.MANAGE_USB" />
<meta-data
android:name="android.support.VERSION"
android:value="25.3.1" />
<application
The i looked from supportlibraries and i.e. appcompat support library has following meta-data information
<manifest package="android.support.v7.appcompat">
<uses-sdk android:minSdkVersion="9" tools:overrideLibrary="android.support.graphics.drawable.animated"/>
<meta-data android:name="android.support.VERSION" android:value="25.3.1"/>
<application/>
</manifest>
So either support libraries has meta-data information in wrong place in manifest file or android manifest merger doesn't merge it correctly in application manifest.