79468595

Date: 2025-02-26 05:18:28
Score: 1
Natty:
Report link

To fix the Gradle sync error, follow these steps:

  1. Replace JCenter with Maven Central: In your build.gradle file, update the repository section to:

repositories { google() mavenCentral() } // Replace JCenter with Maven Central

  1. Clear Gradle Cache: Run the command to clean the Gradle cache:

./gradlew cleanBuildCache

  1. Check Network/Proxy: Ensure your new machine has the correct network settings and no proxy is blocking the connection.

  2. Update Gradle Version (Optional): Update Gradle by running:

./gradlew wrapper --gradle-version <latest_version>

  1. Use SSL Trust > To do this temporarily, add this to your gradle.properties:

systemProp.gradle.ssl.verify=false

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Mansi Panchani