Could not determine the dependencies of task ':app:preDebugBuild'. In React Native - android

What went wrong:
Could not determine the dependencies of task ':app:preDebugBuild'.
Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
Could not resolve com.facebook.android:facebook-core:[5.0,6.0[.
Required by:
project :app > project :react-native-fbsdk
> Skipped due to earlier error
Could not resolve com.facebook.android:facebook-login:[5.0,6.0[.
Required by:
project :app > project :react-native-fbsdk
> Skipped due to earlier error
Could not resolve com.facebook.android:facebook-share:[5.0,6.0[.
Required by:
project :app > project :react-native-fbsdk
> Skipped due to earlier error
Could not resolve org.greenrobot:eventbus:3.+.
Required by:
project :app > project :react-native-inappbrowser-reborn
> Skipped due to earlier error
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 44s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
PS C:\Users\karan\Desktop\react-grocery-customer-master>
I am facing this issue

Related

Nativescript Angular project Build failed

i just crate a simple Nativescript-angular project by:
ns create example-app --ng
and when i run that by:
ns run android
i get this error:
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'core'.
> Could not resolve all files for configuration ':classpath'.
> Could not resolve com.android.tools.build:gradle:7.1.2.
Required by:
project :
> Could not resolve com.android.tools.build:gradle:7.1.2.
> Could not get resource 'https://jcenter.bintray.com/com/android/tools/build/gradle/7.1.2/gradle-7.1.2.pom'.
> Could not GET 'https://jcenter.bintray.com/com/android/tools/build/gradle/7.1.2/gradle-7.1.2.pom'. Received status code 403 from server: Forbidden
> Could not resolve org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.0.
Required by:
project :
> Could not resolve org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.0.
> Could not get resource 'https://jcenter.bintray.com/org/jetbrains/kotlin/kotlin-gradle-plugin/1.6.0/kotlin-gradle-plugin-1.6.0.pom'.
> Could not GET 'https://jcenter.bintray.com/org/jetbrains/kotlin/kotlin-gradle-plugin/1.6.0/kotlin-gradle-plugin-1.6.0.pom'. 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 2s
Failed to build plugin #nativescript/core :
Error: Command gradlew.bat failed with exit code 1
how can i solve this?
regards'
finally, I find the reason.
google and gradle put some countries to ban list, so some of files and packages from they can't download without VPN.
I solve this issue just by buying a VPN account.

Gradle is throwing an error while downloading the artifacts

Running Gradle task 'assembleDebug'...
Warning: Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns
FAILURE: Build failed with an exception.
What went wrong:
Could not determine the dependencies of task ':app:processDebugResources'.
Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
Could not resolve net.minidev:json-smart:[1.3.1,2.3].
Required by:
project :app > project :stripe_payment > com.stripe:stripe-android:10.4.6 > com.stripe:stripe-3ds2-android:1.2.2 > com.nimbusds:nimbus-jose-jwt:7.8
Failed to list versions for net.minidev:json-smart.
Unable to load Maven meta-data from https://google.bintray.com/exoplayer/net/minidev/json-smart/maven-metadata.xml.
Could not get resource 'https://google.bintray.com/exoplayer/net/minidev/json-smart/maven-metadata.xml'.
Could not GET 'https://google.bintray.com/exoplayer/net/minidev/json-smart/maven-metadata.xml'. Received status code 502 from server: Bad Gateway
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 13s
[!] Gradle threw an error while downloading artifacts from the network. Retrying to download...
Exception: Gradle task assembleDebug failed with exit code 1
The gradle is not building properly and as a result the program crashes. I have tried all the methods below
deleting gradle wrapper jar file
updating the gradle version (Distribution url )
maven central replacing

Could not resolve com.google.android.gms:play-services-ads-identifier:12.0.1

* 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:12.0.1.
Required by:
project :app
> Skipped due to earlier error
> Could not resolve com.google.android.gms:play-services-ads-identifier:12.0.1.
Required by:
project :app > com.onesignal:OneSignal:3.15.3
> Skipped due to earlier error
* 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 3m 7s
Exception: Gradle task assembleDebug failed with exit code 1
Exited (sigterm)
I face this error 1 week please help me everyone my project was build from flutter 1.2.3
and I need to upgrade it because currently it's not working the problem is onesignal and firebase version not fit. Please give me any answer I need to complete this for my company I just in flutter internship

flutter build apk fails - Could not determine the dependencies of task ':app:processDebugResources'

here is the complete output :
I tried switching to stable channel and ran these commands already.
flutter channel stable
flutter upgrade
flutter run
Even on stable channel the error doesn't go !
C:\Users\Rudr\Documents\GitHub\Flutter-Facial-Attendance-App\facatte>flutter run
Launching lib\main.dart on SM M315F in debug mode...
Plugin project :firebase_core_web not found. Please update settings.gradle.
FAILURE: Build failed with an exception.
* What went wrong:
Could not determine the dependencies of task ':app:processDebugResources'.
> Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
> Could not resolve io.flutter:flutter_embedding_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
Required by:
project :app
project :app > project :firebase_core
project :app > project :firebase_ml_vision
project :app > project :flutter_plugin_android_lifecycle
project :app > project :google_maps_flutter
project :app > project :image_picker
project :app > project :path_provider
project :app > project :geocoder
project :app > project :cloud_firestore
project :app > project :firebase_analytics
project :app > project :firebase_auth
project :app > project :geolocator
> Could not resolve io.flutter:flutter_embedding_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
> Could not get resource 'https://jcenter.bintray.com/io/flutter/flutter_embedding_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/flutter_embedding_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'.
> Could not GET 'https://jcenter.bintray.com/io/flutter/flutter_embedding_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/flutter_embedding_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'. Received status code 502 from server: Bad Gateway
> Could not resolve io.flutter:arm64_v8a_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
Required by:
project :app
> Could not resolve io.flutter:arm64_v8a_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
> Could not get resource 'https://jcenter.bintray.com/io/flutter/arm64_v8a_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/arm64_v8a_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'.
> Could not GET 'https://jcenter.bintray.com/io/flutter/arm64_v8a_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/arm64_v8a_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'. Received status code 502 from server: Bad Gateway
> Could not resolve io.flutter:x86_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
Required by:
project :app
> Could not resolve io.flutter:x86_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
> Could not get resource 'https://jcenter.bintray.com/io/flutter/x86_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/x86_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'.
> Could not GET 'https://jcenter.bintray.com/io/flutter/x86_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/x86_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'. Received status code 502 from server: Bad Gateway
> Could not resolve io.flutter:x86_64_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
Required by:
project :app
> Could not resolve io.flutter:x86_64_debug:1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.
> Could not get resource 'https://jcenter.bintray.com/io/flutter/x86_64_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/x86_64_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'.
> Could not GET 'https://jcenter.bintray.com/io/flutter/x86_64_debug/1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4/x86_64_debug-1.0.0-ae90085a8437c0ae94d6b5ad2741739ebc742cb4.pom'. Received status code 502 from server: Bad Gateway
* 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 9s
Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 69.8s
Exception: Gradle task assembleDebug failed with exit code 1
The download is under maintenance.
subscribe to https://status.bintray.com/ to get the latest updates.

cordova don'd build to android

I'm new at Cordova and I'm trying to solve this for two days.
When I hit the command: Cordova run android --device this shows up:
C:\Users\Arthur\nameoftheapp>cordova run android --device
ANDROID_HOME=C:\Users\Arthur\Downloads\Aprender\adt-bundle-windows-x86_64-201407
02\adt-bundle-windows-x86_64-20140702\sdk
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_172
Subproject Path: CordovaLib
Incremental java compilation is an incubating feature.
BUILD FAILED
Total time: 7.354 secs
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring root project 'android'.
Could not resolve all dependencies for configuration ':_debugApkCopy'.
Could not find com.android.support:appcompat-v7:27.0.0.
Required by:
:android:unspecified
Could not find com.android.support:support-v4:27.0.0.
Required by:
:android:unspecified
Could not find com.android.support:support-v4:27.0.0.
Required by:
:android:unspecified > com.google.android.gms:play-services-gcm:9.8.0 >
com.google.android.gms:play-services-basement:9.8.0
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.
Error: cmd: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring root project 'android'.
Could not resolve all dependencies for configuration ':_debugApkCopy'.
Could not find com.android.support:appcompat-v7:27.0.0.
Required by:
:android:unspecified
Could not find com.android.support:support-v4:27.0.0.
Required by:
:android:unspecified
Could not find com.android.support:support-v4:27.0.0.
Required by:
:android:unspecified > com.google.android.gms:play-services-gcm:9.8.0 >
com.google.android.gms:play-services-basement:9.8.0
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.
I tried to change the version in the build.gradle to another but when I compile, it changes back.
Do you used many cordova plugin with you'r application ?
if yes you can handle this with this plugin : https://github.com/dpa99c/cordova-android-support-gradle-release

Categories

Resources