Uploading mapping file with command:
./gradlew -PFirebaseServiceAccountFilePath=<path> \
:app:firebaseUploadFreeReleaseProguardMapping
Runs successfully but i cannot see any tasks starting withfirebaseUpload in my app:tasks. Do somebody know why?
We also have encountered this problem.
Solution is to add minifyEnabled in your apps build.gradle like so:
buildTypes {
release {
...
minifyEnabled true
...
}
}
And sync your project, then you will have those tasks created.
#MatBos thanks for the hint. This didn't solve the problem for me.
But I had this cause:
buildTypes {
debug {
minifyEnabled true
useProguard false
}
}
When I change minifyEnabled to false it is working again!
Disabling proguard in debug mode, disabled also the firebase tasks for the production code...
You can upload mapping files manually too.
Go to destination.
app/build/outputs/mapping/debug/mapping.txt
And then upload it.
Related
It can find my device, but without any debuggable process. It's not the first time this problem occurred. But it still worked yesterday, I used profiler to observe my app's memory info. And when I try to debug my app, the process is debuggable. I tried all solutions just like restart Android Studio, none worked. Does anyone know why?
Works for me:
In build.gradle(:app) -> find "buildTypes" -> to "debug" section -> set it to "true" -> done
buildTypes {
release {
debuggable false
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.config
}
debug {
debuggable true
}
}
Mabe you can Close the AndroidStudio.And then restart the adb service.try again.
Keep your application installed is a Debug mode.
if is done,it will be work. I tried.
Since running apps on an emulator is slow, sometimes you may have more than one instance of your app on the emulator which will cause a problem. Just delete the existing emulator and create a new one, or you can instead just wipe the data on an existing emulator:
I am trying to run my android application on other devices, it installed properly but some XML file not working properly. It works as I expected when I installed through USB debugging. I am trying to find solution for many days. I don't get anything related to my issue.
This must be the result of Obfuscation
Add this lines in your build.gradle
buildTypes {
release {
...
debuggable false
shrinkResources false
minifyEnabled false
...
}
}
or you can add your files in pro-gaurd
Debug builds work fine for me. When I choose Active Build Variant = release, and try to run Build -> Generate Bundle(s) / APK(s) -> Build APK, the build runs for a while, then I get the following error:
Unexpected attempt to get register for a value without a register in method java.util.List com.chrynan.chords.parser.AsciiChordParser.parseLineAsString(java.lang.String, int, java.util.Set).
That is referencing an external library I'm pulling in. Source code for that function is available here.
What does that error mean? My searches returned nothing remotely like it.
I solved it! I have no idea why, but I set minifyEnabled = true in my build.gradle (:app):
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
This gave me instant crashing on app start due to this problem, although I think that's unrelated. I fixed that, and now my build works.
I still have no idea why that error came up though.
For some one else having the same problem, I solved it by changing
getDefaultProguardFile( 'proguard-android-optimize.txt') to
getDefaultProguardFile( 'proguard-android.txt') in build.gradle
hi to all flutter developer
my question: when I use flutter google map and when I build final and release app for android the map is not working
how I can fix this problem
please look at below image
Problem resolved, I must enter the SHA-1 when i creating API key
You have to write flutter command screen 'flutter upgrade'. Maybe it help you to solve your issue.
After a very long search and mainly thanks to the help of Ruslanbek0809 I solved this problem at last.
In android/app/build.gradle I added:
shrinkResources false and minifyEnabled false to the buildTypes
buildTypes {
release {
signingConfig signingConfigs.release
shrinkResources false
minifyEnabled false
}
}
And a miracle happened
I recently find my Android Release version can be attached through Android Studio and all logs are available to be seen as well, even though I'm sure that AndroidManifest.xml file doesn't contain "android:debuggable=true" and app's build.gradle file specified that
buildTypes {
...
release {
...
debuggable false
...
}
...
}
Do you guys have any good idea to avoid this?
You can only keep like this code below:
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
hopefully works it.
Logs are nothing to do with debuggable true.
The option debuggale is to making your application debuggable in release mode, so you can attach debugger even on your release build by default it is false.
If you are using Log class and printing any log it will always display until and unless you put the check before logging them.
What you can do is put a check before every log is Build.Debug == true then print the log.
Or you can use open source library for this work like this one which provide the control of logging based on your configuration.
Or you can find a more helpful answer here.