-1

I was trying to run my Flutter app and this shows up:

I do flutter clean, I delete pubspec.lock

FAILURE: Build failed with an exception.

  • Where: Script '/Users/mac/development/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 1005

  • What went wrong: Execution failed for task ':app:compileFlutterBuildDebug'.

Process 'command '/Users/mac/development/flutter/bin/flutter'' finished with non-zero exit value 1

  • 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 21s Exception: Gradle task assembleDebug failed with exit code 1

4

1 回答 1

0

运行 flutter clean 后,您似乎错过了运行 pub get。与您遇到的类似的构建任务问题通常可以通过运行flutter clean以清除项目的构建缓存并运行flutter pub get以获取项目的 pubspec.yaml 中配置的项目依赖项来解决

于 2021-10-26T14:59:11.263 回答