更新到 Flutter 2.0 时出现 Flutter 版本问题

问题描述

我的所有课程在更新后都出现错误。 我也试过扑干净。当我运行 Flutter pub get 命令时,我收到以下错误

Because no versions of intl_utils match >1.8.0 <1.9.0 and intl_utils ^1.9.0 depends on intl_translation 0.17.10+1,intl_utils >1.8.0 <2.0.0 requires intl_translation 0.17.10+1.
And because intl_utils 1.8.0 depends on intl_translation 0.17.10 which depends on intl >=0.15.3 <0.17.0,intl_utils ^1.8.0 requires intl >=0.15.3 <0.17.0 or intl_translation 0.17.10.
And because intl_translation 0.17.10 depends on intl >=0.15.3 <0.17.0 and every version of Flutter_localizations from sdk depends on intl 0.17.0,intl_utils ^1.8.0 is incompatible with Flutter_localizations from sdk.
So,because markets depends on both Flutter_localizations any from sdk and intl_utils ^1.8.0,version solving Failed.
pub get Failed (1; So,version solving Failed.)

解决方法

是的,尝试降级您的 flutter 版本。我遇到了同样的问题

flutter downgrade 1.22.6