简体   繁体   中英

Crashlytics Manifest Merge issue with Instant App Architecture

I have a multi-feature instant app setup and when I try to view the merged manifest of the application I see the following:

Error: Attribute provider#com.crashlytics.android.CrashlyticsInitProvider@authorities
value=(com.happyapp.app.crashlyticsinitprovider) from AndroidManifest.xml:14:13-75 is also present
at AndroidManifest.xml:40:87-161 value=(com.happyapp.app.app.crashlyticsinitprovider). Suggestion: add 'tools:replace="android:authorities"' to <provider> element at AndroidManifest.xml:12:9-16:39 to override. app main manifest (this file), line 13

I have looked multiple places and have not found any way to fix this. I can follow the suggestion, but the line that is mentioned to fix doesn't exist in the manifest.

This is the installed app manifest:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.happyapp.app" />

My colleague was able to workaround the issue by adding the following element to the installed apk AndroidManifest.xml

<application>
    <provider
        android:name="com.crashlytics.android.CrashlyticsInitProvider"
        android:authorities="com.happy.happyapp.happyapp.crashlyticsinitprovider"
        tools:replace="android:authorities" />
</application>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM