gpt4 book ai didi

java - 在最新检查期间无法捕获任务 ':checkDevClasspath' 属性 'compileClasspath' 的输入文件的指纹

转载 作者:塔克拉玛干 更新时间:2023-11-02 23:20:44 25 4
gpt4 key购买 nike

我正在尝试在 Android Studio 中升级到 gradle 3.2.1,但是 gradle 构建失败并出现以下错误。

 FAILURE: Build failed with an exception.

* What went wrong:
Failed to capture the fingerprint of input files for task ':checkDevDebugClasspath' property 'compileClasspath' during the up-to-date check.
> 1

* Try:
Run with --scan to get full insights.

* Exception is:
org.gradle.api.UncheckedIOException: Failed to capture fingerprint of input files for task ':checkDevDebugClasspath' property 'compileClasspath' during up-to-date check.
at org.gradle.api.internal.changedetection.state.CacheBackedTaskHistoryRepository.fingerprintTaskFiles(CacheBackedTaskHistoryRepository.java:360)
at org.gradle.api.internal.changedetection.state.CacheBackedTaskHistoryRepository.createExecution(CacheBackedTaskHistoryRepository.java:163)

不知道发生了什么

最佳答案

我知道这是一个老问题,但我遇到过几次,并以不同的方式解决了它。这可能是由多种原因引起的,但这意味着缺少用于构建项目的资源(模块)。

如果你使用的是纯安卓;我建议清理项目然后按如下方式重建它:

cd android
./gradlew clean assemble

关于 android 的注意事项; 如果您依赖于其他模块,请确保它们存在并正确设置。还要确保您没有任何损坏的符号链接(symbolic link)。

如果您使用的是 react-native,您可以清理 android 和 node_modules 并重建。大多数损坏的依赖项将在 node_modules 中:

rm -rf node_modules
yarn install # Or npm install if you aren't using yarn
cd android
./gradlew clean
cd ..
react-native run-android # Or expo start if you are on expokit

关于 react-native 的注意事项; 确保您使用的是有效版本的 nodejs 并且节点模块已成功安装。对我来说,大多数时候问题是因为我使用了更新的 nodejs 版本并且节点模块没有正确安装。

关于java - 在最新检查期间无法捕获任务 ':checkDevClasspath' 属性 'compileClasspath' 的输入文件的指纹,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54118679/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com