Your Instant App APKs do not declare a valid - android

Am having a bad time with android in order to create new release
i have created a Signed APK with two option
then i zipped the .apk file,after trying to upload it to google console am getting the below error
Your Instant App APKs do not declare a valid 'android:targetSandboxVersion' attribute in their AndroidManifest. Using the 'com.android.feature' Gradle plugin to build your Instant App would add this attribute automatically.
Note : the file zipped and all the solutions asking to zip the file, no luck :(

You need to be clear if you are producing an Instant App or a normal Android app. I think this is what is confusing you, or maybe you just aren't being clear in the question.
Android Instant Apps are special Android apps that launch from a web page, and don't need a user to install them. To build them you need the Instant Apps SDK, and to follow the development instructions here. Android Studio will produce a zip for you, you don't need to do it manually
For normal Android apps, you don't need to zip your APKs. Just upload the APK itself to the Play Console.
I think you are probably making a normal Android app, but because you are zipping it, the Play console thinks you are uploading an instant app. So stopping Zipping your APK, and just upload it to the Play Console as a ".apk" file.
While you are at it, I'd recommend using APK V2 signing - it gives much faster installation on modern devices.

Related

Failed archiving Xamarin.Forms Android app, no keystone file

I am not really a mobile developer but this project was on the board and I was interested so I took it. I made several changes to this Xamarin.forms app and published the changes to the Apple App Store successfully but I am having an issue deploying to Google Play. I may very well not understand this process so bare with me.
I have access to a developer account, our store page, and an admin user account. On the apps console page on the production tab I am editing the current release. "Releases are signed by Google Play".
In Visual Studio for Mac 2022 v17.3 the project.mobile.droid package builds successfully every time with no errors (release is selected here). The android packaging format is set to tab, which is what I want. But when I try to archive for publishing I get the error:
/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(2,2): Error XA4310: `$(AndroidSigningKeyStore)` file `C:/Users/tortis1/AppData/Local/Xamarin/Mono for Android/Keystore/prodensity/prodensity.keystore` could not be found. (XA4310) (Density.Mobile.Droid)
First thing I notice is Users/tortis1/AppData. Maybe I'm unaware of something but there is no tortis1 in my Users folder so I have no idea how to track this down. I have looked for a keystore file in the project and I could find these in the Debug folder: android_debug_keystore.flag, android_debug_keystore.flag, and debug.keystore.
I have not set up any kind of singning rules or credentials in VS for Mac. Have I skipped some step or am I missing something? If you need any further information please let me know.
I have tried working through similar questions like this: How do I generate Google Play Console upload key using Xamarin Forms? , but I can't get it to archive at all.

Appcenter can't find APK file

I have this weird error, I've been using appcenter for a long time, but never experienced this.
I setup a build with appcenter which fetches from azure devops repo. The application is a Xamarin.Android native application. Once I run the build, everything goes well. Untill the signin step. When the step is about to start, I get this error:
##[error]No matching files were found with search pattern: /Users/runner/work/1/s/**/*.apk
Looks like the APK was not found, though the build runs successfully without error.
Please I need your help to figure out a solution to this issue.
In your csproj file for the Android Application project. Check whether <AndroidPackageFormat>apk</AndroidPackageFormat> is set to apk or aab. If it is aab then you need to change the search pattern to search for /**/*.aab instead. Otherwise, it will be looking for stuff that wasn't produced during the build.
To change the search path of appcenter, go to your build configurations and toggle the switch with label: “Build android app bundle”.
the change <AndroidPackageFormat>aab</AndroidPackageFormat> for <AndroidPackageFormat>apk</AndroidPackageFormat> works for me
If you are developing Android Apps and publishing them through Play Store, starting August 2021, new apps are required to target API level 30 (Android 11) and use the Android App Bundle publishing format. (aab)
If you want to know more about the Android App Bundle publishing format, here you have more information. As Cheesebaron is mentioning, if you are using AppCenter for building and packaging your Apps, just use the flag "Build App Bundle" in the Build configuration

Firebass App Disitrbution upload apk with gradle

My app consists of two dynamic modules and instant app. I'm using app bundle to upload my production builds to the Play Store.
When I'm trying to upload apk to the Firebase App Distribution, I use command:
./gradlew assembleVariantRelease appDistributionUploadVariantRelease
Unfortunately, app uploaded in this way results in a crash, and the stacktrace tells me that there are some classes from dynamic modules, that are missing.
The solution I found was to use bundletool and extract universal.apk from it. It turns out, the apk extracted works great, has all the classes included for the app to work.
When I was using Fabric Beta to distribute app, I just needed to provide apk to /projectPath/app/build/outputs/apk/variant/release and run ./gradlew crashlyticsUploadDistributionVariantRelease for it to work. It uploaded working apk file as expected.
When I tried to do the same with Firebase App Distribution (providing the universal apk to the right folder then running ./gradlew appDistributionUploadVariantRelease without adding assembleVariantRelease first), it seems that the command not only uploads apk to the Firebase, but also overwrites my previous apk file by building a new one.
When I upload universal.apk to Firebase manually (via web console), it also works fine.
My question is: Is there a gradle command for Firebase App Distribution to only upload apk from specific folder without triggering a build of a new apk file?
Was just working on this, current firebase documentation is not improved yet so I decided to move to CLI, where you can point out apk path. In midway through, my friend asked about this in firebase-community slack and turns out you can point out apk by adding apkPath to app distribtuion block in gradle.
P.S.: You can join community slack from here -> https://firebase.community/

Can't publish Xamarin.Forms App's APK file on Google Play Store

I want to publish my Xamarin.Forms App to Google Play Store. But when I upload the APK it gives me warning and disables roll-out option. It says we need to use Android App Bundle (.aab) format so that APK can be optimized for size and resources.
Currently, Visual Studio 2019 Archive option does not support the Android App Bundle. I have taken latest update of Visual Studio 2019 but still above format is not supported.
I googled and found some link to do this from the command prompt by modifying some settings in the Project file. But the build returns errors after couple of minutes with exit code 1.
This is frustrating as I can't publish it to Google Play Store. I have already published the iOS version of App.
Any help here will be very much appreciated.
Me and my team are currently releasing to Google Play with no problems our app as APK.
The App Boundle is a nice way to release smaller applications by delivering just what the device that downloads your application needs. The Xamarin Show published recently a video on this topic, that could be of interest for you:
https://www.youtube.com/watch?v=_IOZ0SUKZq4
Through the following images i show how we upload/publish our APK:
First, in the image below you see that APKs are still supported:
APK uploads correctly:
Then we are able to save and review the APK:
APK is uploaded with warning:
The warning states:
For now we just ignore the warning and go on to roll out:
In case that after following those steps your Start Rollout option is not yet enabled, it might be the case that you still have some other Listing Sections for your Application. After you introduce all the information required by Google, the Start Rollout option must be available.

Issue Importing .APK into Eclipse

I created a .apk outside of eclipse using tiggr mobile (http://gotiggr.com)
i have the downloaded .apk and need to sign it - so i thought about running it through eclipse then signing it that way
im having the worse trouble importing it into eclipse.
does anyone have any other suggestions on signing this? i keep getting this message when uploading:
Market does not accept apks signed with the debug certificate. Create a new certificate that is valid for at least 50 years.
Market requires that the certificate used to sign the apk be valid until at least October 22, 2033. Create a new certificate.
Market requires the minSdkVersion to be set to a positive 32-bit integer in AndroidManifest.xml.
thanks for your help!
It would be faster to get the source code into eclipse via retyping it than to try and unsign and explode the apk, edit the manifest, fool the tools and sign the package. The tools can be run at the command line anyways and eclipse would just make it harder.
One problem you have is that there are problems in your manifest. The market requires some attributes set in it that you did not need while doing developer builds. You can open up the apk with anything that will open a zip file. You can edit text files with notepad. You package them up with ant by recreating the build.xml by hand. The instructions for signing things is here:
Android Dev-Guide: Signing your Applications
But what a LOT of work... and I am guessing you will need to do this multiple times just for one release to get the manifest right. Then what do you do when you need to update your program?
Will the service not let you export the code in an easy to use way (because... wow... talk about evil)? Failing that cut and paste will save you time but you will almost certainly want to have it in eclipse or some IDE ready to make changes for your market release and build, package and to sign it.
That's not your issue. I suppose you compiled your app and now you're trying to publish it in the market. To do that, you need a private key whick in turn requires you to have a android market developer account.
Normally you can develop your app and install it into most devices but you can't submit apps to android market without a developer account.
If what you really want is only to import your app to eclipse, I suggest you to create a brand new android project and copy everything into it. It's easier and faster than adjusting everything!

Categories

Resources