2
\$\begingroup\$

I was trying to upload my andoid app apk build to my play console account and I keep getting this error:

You uploaded a debuggable APK or Android App Bundle. For security reasons you need to disable debugging before it can be published in Google Play.

In accordance with the informations given at

https://developer.android.com/studio/publish/preparing.html#publishing-configure

and

https://answers.unity.com/questions/1653647/you-uploaded-a-debuggable-apk-or-android-app-bundl.html

Here are what I have done so far:

1) I have gone to the root folder of my unity project, searched for AndroidManifest.xml, and I found multiple Manifest files, and changed the value of "android:debuggable" to false for each of these manifest files that were generated by unity(and I did not edit the google generated manifest files).

2) I have scanned every c# file on my project that contains the keyword "Debug" and I have either deleted or commented out the Debug.log lines except on the files generated by google(as a result of the integration of google play services into my game).

And yet, I still have the same problem when I try to upload my apk to play console. What else am I missing? Should I also remove the Debug.log lines from google generated c# script files?

\$\endgroup\$

3 Answers 3

1
\$\begingroup\$

Go to build settings:

  1. Select IL2CPP
  2. Verify the C++ Compiler Configuration is set to Release
  3. Check all Android manifests for android:debuggable.

    It should be <application android:debuggable=false>

\$\endgroup\$
2
  • 1
    \$\begingroup\$ This answer would be even better if it included an explanation of how and why this fixes the problem. \$\endgroup\$
    – DMGregory
    Commented May 20, 2020 at 15:42
  • \$\begingroup\$ When you are releasing it should be in il2cpp as google need 64 bit builds now onwards and that can be made only in il2cpp. \$\endgroup\$ Commented May 21, 2020 at 21:15
1
\$\begingroup\$

1- Firstly you have to disable the development build in your Android Build settings uncheck the development build 2- Second in your code try to find out where you have written debugging=true third look into your android manifest fileenter image description here

\$\endgroup\$
4
  • \$\begingroup\$ I've already done all that and it doesn't work. \$\endgroup\$ Commented Mar 20, 2020 at 8:24
  • \$\begingroup\$ @MetaMax in your project is there any third party plugins if so then dig into them \$\endgroup\$ Commented Mar 24, 2020 at 5:04
  • \$\begingroup\$ I've already done that. \$\endgroup\$ Commented Mar 24, 2020 at 5:04
  • 1
    \$\begingroup\$ @MetaMax then there is problem with your keystore \$\endgroup\$ Commented Apr 9, 2020 at 14:29
0
\$\begingroup\$

I'm not sure of what happened exactly, but I uploaded successfully after disabling "Enable built-in Ads extension" on Unity's Services window to fix the Unity Ad duplicate errors that I was getting in the console after a build.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .