NULL安全应用程序在Flutter 3.0上不可运行

发布于 2025-01-30 17:42:09 字数 698 浏览 3 评论 0原文

我有一个Flutter应用程序,它在Flutter 3.0上正常运行,但是在迁移到Null安全后,我在尝试运行时收到了此功能:

FAILURE: Build failed with an exception.

* Where:
Script 'C:\apps\flutter\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1156

* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'C:\apps\flutter\flutter\bin\flutter.bat'' 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 29s
Exception: Gradle task assembleDebug failed with exit code 1

I've a Flutter app, that was running properly on Flutter 3.0, but after migrating to Null Safety, I receive this while trying to run:

FAILURE: Build failed with an exception.

* Where:
Script 'C:\apps\flutter\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1156

* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'C:\apps\flutter\flutter\bin\flutter.bat'' 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 29s
Exception: Gradle task assembleDebug failed with exit code 1

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

初与友歌 2025-02-06 17:42:09

转到pubspec.yaml文件,尝试执行软件包获取|酒吧获取,然后再次构建项目。

Go to pubspec.yaml file, try doing Packages get | Pub get, and then build the project again.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文