My logcat code:
http://txt.do/ku68
I tried solutions from other posts, but it is still not working.
[EDIT]
My manifest.xml:
http://txt.do/ku6e
Without posting the Manifest file one solution might be using the full path of your provider in authorities Tag in Manifest file:
<provider android:name=".MessagesForegroundProvider"
android:authorities="com.facebook.wakizashi.provider.MessagesForegroundProvider"
Related
Manifest merger failed: Attribute
provider#com.google.firebase.provider.FirebaseInitProvider#authorities value=(fintnessathome.cardioexcercise.firebaseinitprovider) from AndroidManifest.xml:766:13-86
is also present at [com.google.firebase:firebase-common:19.3.0] AndroidManifest.xml:28:13-72 value=(com.fintnessathome.fintnessathomeapp.firebaseinitprovider).
Suggestion: add 'tools:replace="android:authorities"' to <provider> element at AndroidManifest.xml:764:9-768:39 to override.
I am facing this issue, I got the template from my friend and i want to make some changes in the android app, it's showing this error when I execute this program.
Try adding following Code in your manifest.xml
tools:replace="android:allowBackup"
Try adding the following in the gradle.properties file
android.useAndroidX=true
android.enableJetifier=true
android.enableUnitTestBinaryResources=false
Also, add the following code into your manifest file inside the application tag
tools:replace="android:supportsRtl,android:allowBackup,icon,label"
Strange problem with Manifest Merger, Visual Studio Mac, Xamarin Forms (5.0.0.2125), Android project, SDK 29 to 30. Problem initiated from an extra ">" in the Properties/AndroidManifest.xml file. That generated the error below, indicating the xml structure wasn't closed; line 35, column 11 being was the last line and character of the Properties/AndroidManifest.xml.
/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(3,3): Error AMM0000: Error: org.xml.sax.SAXParseException; lineNumber: 35; columnNumber: 11; XML document structures must start and end within the same entity. (AMM0000)
So, I edited out the extra character, and the obj/debug/AndroidManifest.xml is created and looks right, however, the build error remains the same!
Subsequent complete rewrites and edits of the Properties/AndroidManifest.xml file have only 2 outcomes
Entering an erroneous xml format will generate the appropriate errors describing the error.
Entering a correct xml format, with any combination of entries, lines and characters will generate a correct obj/debug/AndroidManifest.xml file with the the correct Properties/AndroidManifest.xml content. However, the original build errors stay, with the " line 35, column 11 being was the last line and character of the Properties/AndroidManifest.xml." error.
So, something cached, somewhere, but no clue where. Started during an aborted simulator build and has been here ever since.
Have tried quite few things including:
cleaning, rebuilding and many combinations
remove obj and bin
removing/adding declarations in the AndroidManifest.xml
using different AndroidManifest.xml files
deleting AndroidManifest.xml and running
restoring from cloud a different version of solutions
commenting out Activity declaration on MainActivity
reinstall of VS for Mac
I think it is similar to this bug
Xamarin android Manifest being replaced on build. only solution seems to be to repair visual studio
Has anyone seen this type of bug before?
Help much appreciated as have run out of ideas here.
AndroidManifest.xml
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="17" android:versionName="1.17" package="com.mycompany.myapp">
<uses-sdk android:minSdkVersion="29" android:targetSdkVersion="30" />
<application android:label="myapp" android:icon="#mipmap/ic_launcher" android:supportsRtl="true"></application>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
</manifest>
Solved here, github.com/xamarin/xamarin-android/issues/6385. Was a problem in a Nuget Firebase library AndroidManifest.xml file. Unfortunately the error reporting in VS Mac Manifest merging doesn't report which of the 140+ AndroidManifest.xml files has the problem. However, with a bit of sleuthing, there is a way to eventually work it out.
To avoid my API keys from getting committed on source control (git) I have made an XML resource file called api_keys.xml under the values directory. This file is listed under .gitignore.
I access these string resources the usual way by using #string/.. or .getString(R.string...). This approach works everywhere but in the manifest.xml file.
I have fabric set-up and in the manifest file this is how I try to pass the key -
<meta-data
android:name="io.fabric.ApiKey"
android:value="#string/FABRIC_API_KEY" />
But, when I try to build the APK I get the following error -
Error:Execution failed for task ':app:fabricGenerateResourcesDebug'.
Crashlytics Developer Tools error.
This error goes away if I replace #string/FABRIC_API_KEY with the actual key.
Is there a way I can fix this? Or any other approach I can use to prevent my API keys form getting published on the source control.
I am trying to dexguard an application that I run as a system application.
However when I try to push it to the system/app directory, I get the following error from the PackageParser.
W/PackageParser( 1995): /system/app/My.apk (at Binary XML file line #290): <a
ctivity> does not have valid android:name
I have also added the following to the dexguard-project.txt but to no avail.
-keepresourcexmlattributenames
manifest/installLocation,
manifest/versionCode,
manifest/package,
manifest/versionName,
manifest/application/*/intent-filter/*/name,
manifest/application/*/activity/name
Does anyone know how to solve this issue?
UPDATE
Ok from what I see the manifest/application/*/activity/name successfully stopped the android:name attributes from being obfuscated in the manifest (I can see the plain text when I extract the manifest file after the obfuscation).
However strangely enough android:name in the activity tag at line #290 cannot be found in the extracted manifest file. All the other activity names can be seen in plain text.
In my case the package name of the class started with a Capital letter
I found out that this is because the activities that gave this error are in the manifest file but there were no respective java classes.
Removing the entries from manifest file solved the issue.
I have seen a few similar posts to this, but i already have had the ContentProvider registered in my AndroidManifest.
I have a ContentProvider called MyContentProvider.
And MyContentProvider is located in a library project called MyProject. With package location personal.mobile.abc.angry.tiger.MyContentProvider.
My AndroidManifest for this project looks like this (left out info that is not related):
<application
android:label=...
android:icon=...
android:theme=...>
<provider
android:name="personal.mobile.abc.angry.tiger.MyContentProvider"
android:authorities="personal.mobile.abc.angry.tiger">
</provider>
</application>
Lint keeps saying this:
The <provider> personal.mobile.abc.angry.tiger.MyContentProvider is not registered in the manifest.
And Logcat says this when attempting to run the application that includes the library that contains the ContentProvider:
Failed to find provider info for personal.mobile.abc.angry.tiger
What am i doing wrong? What is the issue?
If you need any further information, please let me know.
Thanks!
Your <provider> element needs to be in the application, as it is the one with the ContentProvider. The fact that the Java class implementing that ContentProvider happens to be in an Android library project does not change the fact that the hosting app is the one responsible for that provider.
Eventually -- perhaps as soon as ADT 21 -- your <provider> element in the library project can be automatically added to your application project. Right now, AFAIK, that process is manual.