I m experiencing some problems using Gradlew bundleRelease - android

I' m working on this cocos2dx game project, that uses gradle for building for Android in linux.
I can build apks for release of debug without problems using
./gradlew assembleRelease or ./gradlew assebleDebug
But now, I have to build an app bundle in order to upload on google play store.
I tried ./gradlew bundleRelease and it seems the build was ok since I did not get any error message, but a Build Sccessfull message.
Despite that, I was not able to find the aab file that should be generated. I look for the /app/build/outputs/ and there is only the apk folder, not the bundle folder.
Any Ideas ?
Thanks in advance people.

Related

Generated debug APK is not installable after updating Android gradle and plugin version

I'm unable to install debug apk in emulator or any other devices after updating Android gradle version from 6.5 to 7.3.3 and plugin version from 4.1.2 to 7.2.0.
Getting this below error message while installing an apk :
Installation did not succeed.
The application could not be installed: INSTALL_FAILED_INVALID_APK
List of apks:
[0] 'C:\Users\...\Documents\Android\app\build\intermediates\apk\_int\debug\my.....apk'
The APKs are invalid.
Retry
Failed to launch an application on all devices
Could you please help me? How I can resolve this issue? I have seen many SO answers tried some solutions like clean, rebuild, invalid cache and restart but still getting the same issue.
Choose APK After Click on Build and Generate Signed Bundle / APK...
Next Create or choose a Key Store
Then tho most important you create Release and not debug, after you'll be able to install your APK

Flutter: How to create a development APK that can be installed on the phone

I recently started working with flutter. I have been making several test applications. They all work well on emulators.
But now I want to be able to use them on my cell phone.
I took the APK that is generated when I run the application in the emulator, indicated in this route:
But it always fails to install
So far, my applications are simple, Hello world, Add numbers, etc.
Any ideas?
How should I do it correctly?
First: Open your Terminal/Shell/Command Line and open the directory of the Flutter App in there (cd PATH_TO_YOUR_FILE)
You probably want to create a profile-mode apk for testing. This build still helps debugging while having the speed of the --release version:
This creates a single APK which works on all devices (x64, arm64 and arm), it's probably pretty big:
flutter build apk --profile
If the people who install your App know which devices they have, you can use the split-per-abi command which creates three different APKs for all architectures (x64, arm64 and arm)
flutter build apk --profile --split-per-abi
If you want to have a release build, you can use what #Niteesh commented:
flutter build apk --release --split-per-abi
Release-builds can be uploaded to Google-Play (also the internal testing)
Read more: https://flutter.dev/docs/testing/build-modes
the apk that is generated when you run the app is the debug-apk, it contains lots of overheads which helps in flutter hot reload and hot restart. The size of debug apk version is also a lot.
use this command to generate release version of apk
flutter build apk --split-per-abi
After execution of the command, you get the path of the apk, something like this
√ Built build\app\outputs\flutter-apk\app-armeabi-v7a-release.apk (7.0MB).
Then you can install that apk on your phone

debug version of an apk got blocked by play services

I'm trying to build my app for developing purpose, It worked before but when I'm trying to build it on a new computer Google Play Protect blocks my app.
My application is build on Ionic 4, on a new computer (I develop it on another computer).
I tried to build it with debug option but it didn't work.
I did a research and found some answers, this was the most logical: Debug app blocked by play protect
I tried to delete the debug key from the ~/.android/ directory and after it didn't work I tried to delete all cache data from the ~/android/ directory.
I also saw this question installation app blocked by play protect but he had problem with release apk and not with debug apk as I have.
How am I trying to build:
ionic cordova build android --prod --debug
After it didn't work I tried to clean my configuration:
cordova clean
didn't work either.
The error message that I get is that the app developer isn't recognize to google.
Expected result is: be able to install debug application for developing purpose.

Could Not Load App error APK Android React Native

So, I'm stuck with an error after generating APK with React-Native. I tried on multiple computers, 32-bit and 64-bit operating system and had no success.
How I got here
First, I created my app with
create-react-native-app suporteecontrole
Then I started developing my app, installing dependencies, and etc. After making sure that the APP was running without any errors, I ejected with the command line:
npm run eject
I've put my expo credentials and it worked without any errors too. I figured that it was going to work.
Generating APK's
To generate APK, i followed the instructions on this link:
React Native Build Signed APK
1 - I installed the JAVA 8 SDK, and all dependences too.
2 - I generated the Key by following the step one on the link.
3 - I changed all gradle files according to the link
4 - Then I runned this lines on cmd:
cd android
And
gradle assembleRelease
No errors popped up. I made it to the build successfully.
So, It generated some files: app-dev19-release.apk, app-dev-release.apk, app-devRemoteKernel-release.apk, app-prod-release.apk.
I installed app-prod-release.apk on my mobile, and returns an Expo error:
Could not load app
photo_2018-07-24_12-57-51
I searched Google for this, and found nothing.
Can anybody help me with this?
It is frustrating how the create-react-native does expo by default instead of normal react app. But you've already ejected from the expo app, and your code now wont be working on it.
Instead you'll see a new app on your phone with the name and icon you chose. Try to find the App and run it. And to assemble a release, you actually need to sign it too, so I hope you've done the signing right. Take a look at this https://facebook.github.io/react-native/docs/signed-apk-android.html for signing if you face that error.

React Native Android Debug APK installed but unsigned doesn't

when i built the APK with react native in windows with the debug version it worked fine (also in the emulator) and installed in the real device, but when i tried to build with the release version i saw the message ( app not installed ) , the problem is i have no way to trace or debug this problem (probably i don't know ), i tried to fix this problem for about one week ,so i ask for some help here , thanks
gradlew assembleDebug --- installed fine
gradlew assembleRelease --- app not installed
also i added this lines to gradle.properties file in my project
MYAPP_RELEASE_STORE_FILE=my-release-key.keystore
MYAPP_RELEASE_KEY_ALIAS=my-key-alias
MYAPP_RELEASE_STORE_PASSWORD=123456
MYAPP_RELEASE_KEY_PASSWORD=123456
other details
react native version 0.48 ---
my device android version 5.0
windwos version 8.1
the project is AwsomeProject --- the initial projects to test
NOTE : in all situations i see the message "BUILD SUCCESSFUL" and the file generated without any problem or any error message
$ cd android && gradlew assembleRelease creates a signed apk.
(Note: Don't forget to cd out of <MyProject>/android after creating a signed apk back the root of your directory)
$ react-native run-android --variant=release will install the signed apk onto your device
It is all about adding this line in the gradle.properties file
signingConfig signingConfigs.release
hope it help someone
You need to generate some certificates to be able to run your signed APK , in the RN docs that is documented.
Please check this out RN Docs

Categories

Resources