3

I am trying to release an Android app for the first time on play.google.com using an app bundle. The app is implemented in Android Studio using Flutter SDK and the bundle is generated using the following command:

flutter build appbundle

When I upload the bundle to Google Play Console, I get the following warning:

This App Bundle contains native code, and you've not uploaded debug symbols.
We recommend you upload a symbol file to make your crashes and ANRs easier to
analyze and debug. This App Bundle contains native code, and you've not uploaded
debug symbols. We recommend you upload a symbol file to make your crashes and 
ANRs easier to analyze and debug.

I observe lots of people raised similar issues, but I'mnot able to figure out the exact reason for this issue and how to solve this.

enter image description here

Update:

By modifying root_app_dir/android/app/build.gradel as follows

buildTypes {
        release {
            signingConfig signingConfigs.release
            ndk {
                debugSymbolLevel 'FULL'
            }
        }
    }

Started giving me the following error:

* What went wrong:                                                      
Execution failed for task ':app:extractReleaseNativeDebugMetadata'.     
> NDK is not installed     
Dipak
  • 6,532
  • 8
  • 63
  • 87
  • Exact duplicate issue: https://stackoverflow.com/questions/62568757/playstore-error-app-bundle-contains-native-code-and-youve-not-uploaded-debug But the solution didn't work for me. Not sure how to resolve the solution provided in this post. – Dipak Apr 25 '21 at 11:30
  • Duplicate: Discussion on git https://github.com/flutter/flutter/issues/60240 this also didn't give a solution for me. – Dipak Apr 25 '21 at 11:31

2 Answers2

1

it is duplicate here go for the answer that says "If talking about Flutter..."

however you don't have to worry about it too much it is just warning and I've uploaded multiple flutter apps with same warning and it works just fine.

Moaid ALRazhy
  • 1,604
  • 1
  • 3
  • 13
  • Hey Thanks, yes it's just a warning. Still would like to solve it. And in the duplicate link it says `So I suggest you return classic Play console and it will let you through :)` what is classic UI? I just started working on the flutter android app a few weeks back just not sure about all these things. – Dipak Apr 25 '21 at 11:38
  • 1
    go for second the answer not first one that says "If talking about Flutter..." – Moaid ALRazhy Apr 25 '21 at 11:43
0

After some trials and errors, I finally managed to get the Flutter build command to include the debug symbols files.

In android\local.properties make sure you add the path to the NDK. Here's mine (for Windows):

sdk.dir=C:\\Users\\Roslan\\AppData\\Local\\Android\\sdk
ndk.dir=C:\\Users\\Roslan\\AppData\\Local\\Android\\sdk\\ndk\\25.1.8937393

In android\app\build.gradle have the following:

buildTypes {
  release {
    signingConfig signingConfigs.release
    ndk {
      debugSymbolLevel 'FULL'
    }
  }
}
Roslan Amir
  • 1,141
  • 8
  • 16