如何解决Flutter中的折旧错误?

af7jpaap  于 2023-02-16  发布在  Flutter
关注(0)|答案(1)|浏览(282)

package用于代码中,但过去3年未更新程序包,因此需要更换程序包。
如果任何人使用这个软件包或更换这个package请通知我。
错误确切地说是:-

Running "flutter pub get" in project...
Resolving dependencies...
The current Dart SDK version is 2.19.0.

Because build_runner >=2.4.0 requires SDK version >=3.0.0-134.0.dev <4.0.0 and no versions of build_runner match >2.3.3 <2.4.0, build_runner >2.3.3 is forbidden.
And because build_runner 2.3.3 depends on crypto ^3.0.0, build_runner >=2.3.3 requires crypto ^3.0.0.
And because every version of powerflutter depends on uuid ^2.0.0 which depends on crypto ^2.0.0, build_runner >=2.3.3 is incompatible with powerflutter.
So, because tacticboard depends on both powerflutter ^0.1.1+1 and build_runner ^2.3.3, version solving failed.
pub get failed
command: "/Users/Develop/flutter/bin/cache/dart-sdk/bin/dart __deprecated_pub --directory . get --example"
pub env: {
  "FLUTTER_ROOT": "/Users/Develop/flutter",
  "PUB_ENVIRONMENT": "flutter_cli:get",
  "PUB_CACHE": "/Users/mac/.pub-cache",
}
exit code: 1

Process finished with exit code

我从here下载了powerflutter的repo,并尝试自定义repo。

ryevplcw

ryevplcw1#

你需要在你的项目中添加git
然后运行命令行:“flutter upgrade”
构建Flutter工具...Flutter已在通道稳定Flutter3.7.3上更新·通道稳定·https://github.com/flutter/flutter.git框架·修订版本9944297138(7天前)· 2023-02-08 15:46:04 - 0800引擎·修订版本248290 d 6d 5工具· Dart 2.19.2 · DevTools 2.20.1

相关问题