Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
lojedaa opened this issue Nov 29, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@lojedaa
Copy link

lojedaa commented Nov 29, 2024

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
@lojedaa lojedaa added the bug Something isn't working label Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant