Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android S explicitly exported manifest components #2076

Closed
laalto opened this issue Feb 22, 2021 · 2 comments
Closed

Android S explicitly exported manifest components #2076

laalto opened this issue Feb 22, 2021 · 2 comments
Milestone

Comments

@laalto
Copy link

laalto commented Feb 22, 2021

Description

Android S requires that manifest components with intent-filters explicitly declare android:exported value for apps targeting S or above.

https://developer.android.com/about/versions/12/behavior-changes-12#exported

At least LeakLauncherActivity seems to have intent-filter and no explicit exported attribute value.

Steps to Reproduce

  1. Project with LeakCanary (2.6)
  2. Change compileSdkVersion to 'android-S' and targetSdkVerrsion to 'S'
  3. Build the project
  4. Attempt to install to a device/emulator with Android S preview

Expected behavior:

App can be installed

Actual behavior:

Execution failed for task ':app:installDebug'.
> java.util.concurrent.ExecutionException: com.android.builder.testing.api.DeviceException: com.android.ddmlib.InstallException: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED: Failed parse during installPackageLI: /data/app/vmdl332506941.tmp/base.apk (at Binary XML file line #510): leakcanary.internal.activity.LeakLauncherActivity: Targeting S+ (version 10000 and above) requires that an explicit value for android:exported be defined when intent filters are present
@mannodermaus
Copy link

This has a pending PR already in #2074. Looking forward to seeing it merged into main!

@pyricau pyricau added this to the 2.7 milestone Feb 27, 2021
@pyricau
Copy link
Member

pyricau commented Feb 27, 2021

Fixed by #2074

@pyricau pyricau closed this as completed Feb 27, 2021
copybara-service bot pushed a commit to androidx/androidx that referenced this issue Sep 30, 2021
Newer version makes it compatible with Android S
square/leakcanary#2076

This also adds a workaround for b/201550163

Test: ./gradlew bOS
Change-Id: Ie1eb71c2d2c3a45c477960f1317e17a7757970f3
soltzen added a commit to getlantern/lantern-client that referenced this issue Dec 11, 2021
Necessary to be able to compile to API 31.
Mainly for this square/leakcanary#2076
soltzen added a commit to getlantern/lantern-client that referenced this issue Dec 13, 2021
Necessary to be able to compile to API 31.
Mainly for this square/leakcanary#2076
soltzen added a commit to getlantern/lantern-client that referenced this issue Dec 14, 2021
Necessary to be able to compile to API 31.
Mainly for this square/leakcanary#2076
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants