【发布时间】:2021-08-27 01:19:24
【问题描述】:
我正在将我的 Flutter 升级到 2.2.1 版,但在构建 ios 包时,--no-sound-null-safety 似乎不再可用。我正在使用此命令构建项目:
~/apps/flutter/bin/flutter build ios --release --no-codesign --no-sound-null-safety
但输出仍然告诉我某些包不支持空安全:
Changing current working directory to: /Users/dolphin/source/cruise-open
Warning: Building for device with codesigning disabled. You will have to manually codesign before deploying to device.
Building com.earth.dolphin for device (ios-release)...
Running Xcode build...
Xcode build done. 36.6s
Failed to build iOS app
Error output from Xcode build:
↳
** BUILD FAILED **
Xcode's output:
↳
2 warnings generated.
2 warnings generated.
Error: Cannot run with sound null safety, because the following dependencies
don't support null safety:
- package:state_notifier
- package:fish_redux
- package:flutter_icons
For solutions, see https://dart.dev/go/unsound-null-safety
Command PhaseScriptExecution failed with a nonzero exit code
note: Using new build system
note: Building targets in parallel
note: Planning build
note: Analyzing workspace
note: Constructing build description
note: Build preparation complete
note: Removed stale file
Encountered error while building for device.
这个问题有什么解决办法吗?我正在从颤振问题中搜索,但没有人确认这个问题(https://github.com/flutter/flutter/issues/84199),它是新版本的错误吗?(因为我使用此命令工作正常,直到我升级到版本 2.2.1)。还有其他方法可以传递no-sound-null-safety 参数吗?我尝试了很多版本,发现有些版本可以正常工作,有些版本不能正常工作。可能是一个颤振错误。
- 颤振 2.0.1 工作
- 颤振 2.0.3 工作
- 颤振 2.0.6 工作
- flutter 2.2.0 不工作
- flutter 2.2.1 不起作用
- flutter 2.2.2 不起作用
- flutter 2.2.3 不起作用
【问题讨论】:
-
我已经阅读了这个问题,仍然无法解决我的问题。我已经在命令中添加了
--no-sound-null-safety参数!!! @ghostdeathrider 顺便说一句,android 的命令工作正常,但 ios 没有工作。
标签: flutter