Skip to content

Synchronization Error: AGP 8.7.2 Requires Gradle 8.9 - Update Required #1211

@lojedaa

Description

@lojedaa

Description

The project encountered synchronization errors when attempting to update the Android Gradle Plugin (AGP) version. After modifying the build.gradle file to use AGP 8.7.2, the project failed to sync due to incompatibility between the AGP and the current Gradle version 8.6. The minimum required Gradle version for AGP 8.7.2 is 8.9.

This issue blocks the project from building and prevents updates or releases to be published in Google Play.


To Reproduce

Steps to reproduce the behavior:

  1. Open the project in Android Studio.
  2. Modify the build.gradle file:
    id 'com.android.application' version '8.7.2' apply false
    id 'com.android.library' version '8.7.2' apply false
  3. Attempt to sync the project.
  4. Observe the synchronization error: "Minimum supported Gradle version is 8.9. Current version is 8.6."

Proposed Solution

  1. Update the gradle-wrapper.properties file:

    distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-all.zip
    distributionSha256Sum=9631d53cf3e74bfa726893aee1f8994fee4e060c401335946dba2156f440f24c
  2. Delete any cached Gradle distributions to avoid conflicts:

    rm -rf ~/.gradle/wrapper/dists/gradle-8.9-all
  3. Resynchronize the project in Android Studio:

    • Navigate to File > Sync Project with Gradle Files.

Why It's Important

  • Compatibility: The AGP 8.7.2 requires Gradle 8.9 or higher to function.
  • Security: Ensures that the Gradle distribution matches its official checksum to prevent using a tampered version.
  • Publishing: Without the fix, the project cannot build or release updates to Google Play Console.

Others

  • Device: Development Environment
  • Android Version: Not applicable
  • App Version: Current development version
  • Downloaded From: Development Environment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions