失败:构建失败,并出现异常。
出了什么问题: 无法确定任务':app:preDebugBuild'的依赖关系。
无法解决配置':app:debugRuntimeClasspath'的所有任务依赖关系。 找不到androidx.transition:transition:1.0.0。 在以下位置搜索:
- 文件:/ C:/Users/k7aled/.m2/repository/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/.m2/存储库/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.jar 要求: 项目:app>项目:react-native-reanimated
尝试: 使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获取更多日志输出。与--scan一起运行以获取完整信息 见解。
8秒内失败
错误无法安装该应用程序。确保已设置Android开发环境:https://facebook.github.io/react-native/docs/getting-started.html#android-development-environment。使用--verbose标志运行CLI以获取更多详细信息。 错误:命令失败:gradlew.bat app:installDebug -PreactNativeDevServerPort = 8081
失败:构建失败,并出现异常。
出了什么问题: 无法确定任务':app:preDebugBuild'的依赖关系。
无法解决配置':app:debugRuntimeClasspath'的所有任务依赖关系。 找不到androidx.transition:transition:1.0.0。 在以下位置搜索:
- 文件:/ C:/Users/k7aled/.m2/repository/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/.m2/存储库/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.jar 要求: 项目:app>项目:react-native-reanimated
尝试: 使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获取更多日志输出。与--scan一起运行以获取完整信息 见解。
8秒内失败
at checkExecSyncError (child_process.js:616:11)
at execFileSync (child_process.js:634:15)
at runOnAllDevices (C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\runOnAllDevices.js:74:39)
at buildAndRun (C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\index.js:158:41)
at C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\index.js:125:12
at processTicksAndRejections (internal/process/task_queues.js:89:5)
at async Command.handleAction (C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli\build\cliEntry.js:160:7)
PS C:\ Users \ k7aled \ Desktop \ reactnative \ test2> npx react-native运行Android 信息运行jetifier将库迁移到AndroidX。您可以使用“ --no-jetifier”标志禁用它。 Jetifier发现有928个文件需要正向喷射。使用4名工人... 信息正在启动JS服务器... 信息正在安装应用程序...
失败:构建失败,并出现异常。
出了什么问题: 无法确定任务':app:preDebugBuild'的依赖关系。
无法解决配置':app:debugRuntimeClasspath'的所有任务依赖关系。 找不到androidx.transition:transition:1.0.0。 在以下位置搜索:
- 文件:/ C:/Users/k7aled/.m2/repository/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/.m2/存储库/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.jar 要求: 项目:app>项目:react-native-reanimated
尝试: 使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获取更多日志输出。与--scan一起运行以获取完整信息 见解。
在10秒钟内失败
错误无法安装该应用程序。确保已设置Android开发环境:https://facebook.github.io/react-native/docs/getting-started.html#android-development-environment。使用--verbose标志运行CLI以获取更多详细信息。 错误:命令失败:gradlew.bat app:installDebug -PreactNativeDevServerPort = 8081
失败:构建失败,并出现异常。
出了什么问题: 无法确定任务':app:preDebugBuild'的依赖关系。
无法解决配置':app:debugRuntimeClasspath'的所有任务依赖关系。 找不到androidx.transition:transition:1.0.0。 在以下位置搜索:
- 文件:/ C:/Users/k7aled/.m2/repository/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/.m2/存储库/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/react-native/android/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- 文件:/ C:/用户/k7aled/Desktop/reactnative/test2/node_modules/jsc-android/dist/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://dl.google.com/dl/android/maven2/androidx/transition/transition/1.0.0/transition-1.0.0.jar
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.pom
- https://jcenter.bintray.com/androidx/transition/transition/1.0.0/transition-1.0.0.jar 要求: 项目:app>项目:react-native-reanimated
尝试: 使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获取更多日志输出。与--scan一起运行以获取完整信息 见解。
在10秒钟内失败
at checkExecSyncError (child_process.js:616:11)
at execFileSync (child_process.js:634:15)
at runOnAllDevices (C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\runOnAllDevices.js:74:39)
at buildAndRun (C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\index.js:158:41)
at C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\index.js:125:12
at processTicksAndRejections (internal/process/task_queues.js:89:5)
at async Command.handleAction (C:\Users\k7aled\Desktop\reactnative\test2\node_modules\@react-native-community\cli\build\cliEntry.js:160:7)
PS C:\ Users \ k7aled \ Desktop \ reactnative \ test2>
答案 0 :(得分:0)
首先将这两行添加到您的android / gradle.properties中:
android.useAndroidX = true
android.enableJetifier = true
然后使用终端(cmd)在项目根目录中运行以下两个命令行:
npm我喷射器
npx jetify