Flutter Build Error:Could not determine the dependencies of task ‘:app:compileDebugJavaWithJavac

  android, dart, flutter

Was working fine just before and after rebuilding the process was interrupted with a sudden restart, and after that this is the error showing up, I’ve tried every possible solution found on the internet.

I run v1.22.6 for the project.

FAILURE: Build failed with an exception.

  • What went wrong:
    Could not determine the dependencies of task ‘:app:compileDebugJavaWithJavac’.

Could not resolve all task dependencies for configuration ‘:app:debugCompileClasspath’.
Could not resolve com.google.android.gms:play-services-ads-identifier:[15.0.0, 16.0.99].
Required by:
project :app > com.onesignal:OneSignal:3.15.7
> Failed to list versions for com.google.android.gms:play-services-ads-identifier.
> Unable to load Maven meta-data from https://google.bintray.com/exoplayer/com/google/android/gms/play-services-ads-identifier/maven-metadata.xml.
> Could not get resource ‘https://google.bintray.com/exoplayer/com/google/android/gms/play-services-ads-identifier/maven-metadata.xml’.
> Could not GET ‘https://google.bintray.com/exoplayer/com/google/android/gms/play-services-ads-identifier/maven-metadata.xml’. Received status code 403 from server: Forbidden
Could not resolve com.google.android.gms:play-services-basement:[15.0.1,16.0.0).
Required by:
project :app > com.google.android.gms:play-services-location:15.0.1
project :app > com.google.android.gms:play-services-places-placereport:15.0.1
> Failed to list versions for com.google.android.gms:play-services-basement.
> Unable to load Maven meta-data from https://google.bintray.com/exoplayer/com/google/android/gms/play-services-basement/maven-metadata.xml.
> Could not get resource ‘https://google.bintray.com/exoplayer/com/google/android/gms/play-services-basement/maven-metadata.xml’.
> Could not GET ‘https://google.bintray.com/exoplayer/com/google/android/gms/play-services-basement/maven-metadata.xml’. Received status code 403 from server: Forbidden
Could not resolve com.google.android.gms:play-services-tasks:[15.0.1,16.0.0).
Required by:
project :app > com.google.android.gms:play-services-location:15.0.1
> Failed to list versions for com.google.android.gms:play-services-tasks.
> Unable to load Maven meta-data from https://google.bintray.com/exoplayer/com/google/android/gms/play-services-tasks/maven-metadata.xml.
> Could not get resource ‘https://google.bintray.com/exoplayer/com/google/android/gms/play-services-tasks/maven-metadata.xml’.
> Could not GET ‘https://google.bintray.com/exoplayer/com/google/android/gms/play-services-tasks/maven-metadata.xml’. Received status code 403 from server: Forbidden

  • Try:
    Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output. Run with –scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 1m 0s
Exception: Gradle task assembleDebug failed with exit code 1

Source: Android Questions

LEAVE A COMMENT