[英]I'm facing this problem in android studio.I have downloaded the files mentioned in links, where to put paste those file
Launching lib\main.dart on LS 5016 in debug mode... Running Gradle task 'assembleDebug'...在调试模式下在 LS 5016 上启动 lib\main.dart... 运行 Gradle 任务“assembleDebug”...
FAILURE: Build failed with an exception. FAILURE:构建失败并出现异常。
What went wrong: A problem occurred configuring root project 'android'.出了什么问题:配置根项目“android”时出现问题。
Could not resolve all artifacts for configuration ':classpath'.
无法解析配置“:classpath”的所有工件。 Could not download builder.jar (com.android.tools.build:builder:3.5.0) Could not get resource ' https://dl.google.com/dl/android/maven2/com/android/tools/build/builder/3.5.0/builder-3.5.0.jar '.
无法下载builder.jar(com.android.tools.build:builder:3.5.0)无法获取资源' Z5E056C500A1C4B6A7110B50D807BADE5/build/maven2/android/android/dl/android/dl.com/android/tools/build/maven2/android.com/android builder/3.5.0/builder-3.5.0.jar '。 Premature end of Content-Length delimited message body (expected: 8174407; received: 2359280 Could not download bundletool.jar (com.android.tools.build:bundletool:0.9.0) Could not get resource ' https://dl.google.com/dl/android/maven2/com/android/tools/build/bundletool/0.9.0/bundletool-0.9.0.jar '. Premature end of Content-Length delimited message body (expected: 5248142; received: 4456416
Premature end of Content-Length delimited message body (expected: 8174407; received: 2359280 Could not download bundletool.jar (com.android.tools.build:bundletool:0.9.0) Could not get resource ' https://dl.google .com/dl/android/maven2/com/android/tools/build/bundletool/0.9.0/bundletool-0.9.0.jar '. Content-Length 分隔消息正文的提前结束(预期:5248142;收到:4456416
Try: Run with --stacktrace option to get the stack trace.尝试:使用 --stacktrace 选项运行以获取堆栈跟踪。 Run with --info or --debug option to get more log output.
使用 --info 或 --debug 选项运行以获得更多日志 output。 Run with --scan to get full insights.
运行 --scan 以获得完整的见解。
Get more help at https://help.gradle.org在https://help.gradle.org获得更多帮助
BUILD FAILED in 27m 34s Finished with error: Gradle task assembleDebug failed with exit code 1 BUILD FAILED in 27m 34s Finished with error: Gradle task assembleDebug failed with exit code 1
When I encounter Could not resolve all artifacts for configuration ':classpath'
, I usually invalidate cache, restart, clean and rebuild project.当我遇到
Could not resolve all artifacts for configuration ':classpath'
时,我通常会使缓存无效,重新启动,清理和重建项目。 Strangely, the problem is solved just like that.奇怪的是,问题就这样解决了。
Anyway, if you want to add more dependencies, you can choose File > Project Structure > Dependencies.无论如何,如果你想添加更多的依赖项,你可以选择 File > Project Structure > Dependencies。
Hope it help!希望有帮助!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.