Question

App must target Android 14 (API level 34) or higher is showing even after update to API level 34

I updated the target API level (targetsdkversion) of the project from 33 to 34. The build process was successful.My build was successful then upload the app bundle.

Warning Message Image The error message is still showing after updates in inbox: Warning message

Error Message in inbox: Error message

Another thing I found there is a bundle which was my first build showing Active,is it creating problem?: Is this creating issues

 7  8076  7
1 Jan 1970

Solution

 7

I got the same warning which buzzled me because I too have set targetSdk to 34, but after viewing the details of the warning and clicking view app bundles apparently it was the internal testing track that was affected not the production track, the latest release in there targeted api 33 !! So I just created a new release in the internal testing track using add from library

2024-07-12
yazan sayed

Solution

 5

You need to update the compileSdkVersion to 34 and the targetSdkVersion to 34 like this:

In your android/app/build.gradle

targetSdkVersion 34

compileSdkVersion 34
2024-07-11
Sachin Advait

Solution

 2

First I have updated my to

targetSdkVersion 34

compileSdkVersion 34

then still got the same error then i checked my (open testing,closed,and internal testing ) track .Then I discovered a app bundle with targetsdk 33 in Internal testing , I replaced it with latest one then after 24 hours I got a Inbox message and it solved .Thanks

2024-07-17
SAMIUL BASIR

Solution

 2

First I have updated my targetSdkVersion and compileSdkVersion to

targetSdkVersion 34

compileSdkVersion 34

But my issue was not solved then i've updated my minSdkVersion to 34 and now it is solved

2024-07-18
Mahnoor Waheed

Solution

 1

please check any testing track is live in release (open testing,closed,and internal testing )

2024-07-13
Gnanesh023

Solution

 0

with flutter update local.properties file like below

sdk.dir=/Users/macbook/Library/Android/sdk
flutter.sdk=/Users/macbook/development/flutter
flutter.buildMode=release
flutter.versionName=1.0.8
flutter.versionCode=49
flutter.compileSdkVersion = 34
flutter.targetSdkVersion = 34
2024-07-13
Tushar Kshirsagar

Solution

 0

First update the android/build.gradle

compileSdkVersion = 34
targetSdkVersion = 34

if your code work file then ok In my case my app crash after these changes so I reslved app crash my changes these

MainApplication.java

 // Add imports
   import android.content.BroadcastReceiver;
   import android.content.Intent;
   import android.content.IntentFilter;
   import android.os.Build;
   import org.jetbrains.annotations.Nullable;


   // ...
   // Put this above  "public void onCreate()":
  @Override
  public Intent registerReceiver(@Nullable BroadcastReceiver receiver, IntentFilter filter) {
    if (Build.VERSION.SDK_INT >= 34 && getApplicationInfo().targetSdkVersion >= 34) {
      return super.registerReceiver(receiver, filter, Context.RECEIVER_EXPORTED);
    } else {
      return super.registerReceiver(receiver, filter);
    }
  }
// ....

app/build.gradle

 dependencies {
     //  ...
    implementation 'org.jetbrains:annotations:16.0.2'
    // ...
}
2024-07-15
Subtain Ali