Add 'Tools:Replace="Android:Value"' to <Meta-Data> Element at Androidmanifest

add 'tools:replace=android:label' to application element at AndroidManifest.xml:16:5-39:19 to override

The error message is telling you that in you AndroidManifest.xml your android:label with value flutter_bloc_pattern is already present in the manifest of (library/plugin/project) DynamsoftBarcodeReader.

You could, as the error says, add tools:replace="android:label" to your <application> node in your manifest

<application
tools:replace="android:label"
android:name="io.flutter.app.FlutterApplication"
android:label="flutter_bloc_pattern"
android:icon="@mipmap/ic_launcher">

If you add the tools attribute you need also to add the schema

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="nz.co.plumbingworld.flutterblocpattern">

Manifest Merger error - tools:replace not working

In my case,

removing tools:ignore from the Manifest files and adding tools:replace="allowBackup,supportsRtl" worked for me.

Update:

One more solution looks promising, however I never tried it.

 <application
xmlns:tools="http://schemas.android.com/tools" <-- added tools on application tag
android:name=".ABC"
android:allowBackup="false"
android:fullBackupContent="false"
android:hardwareAccelerated="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="false"
android:theme="@style/Theme"
tools:replace="allowBackup,supportsRtl"
tools:ignore="GoogleAppIndexingWarning,UnusedAttribute">

A required meta data tag in your android manifest does not exist

After you add following meta tag in the manifest file

<meta-data android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version"/>

Make sure
"@integer/google_play_services_version" being defined in a custom value file like this:
In /res/values/strings.xml

<?xml version="1.0" encoding='utf-8' standalone='no'?>

<integer name="google_play_services_version">12451000</integer>

</resources>

If the issue remains, please let me know



Related Topics



Leave a reply



Submit