扑动依赖冲突(版本取决于另一个)
我想在我的应用中添加AVTAR,但由于依赖性冲突/必需的版本错误而无法执行此操作。我还试图超越依赖性,但它仍然无法正常工作。还尝试此命令。
- 扑打干净的
- 扑打酒吧可以得到
,但仍然无法正常工作。
错误: -
Because no versions of random_avatar match >0.0.7 <0.1.0 and random_avatar 0.0.7 depends on flutter_svg ^1.0.3, random_avatar ^0.0.7 requires flutter_svg ^1.0.3.
And because flutter_html >=2.0.0-nullsafety.1 <3.0.0-alpha.1 depends on flutter_svg >=0.22.0 <1.0.0, random_avatar ^0.0.7 is incompatible with flutter_html >=2.0.0-nullsafety.1 <3.0.0-alpha.1.
So, because seedwill_demo depends on both flutter_html ^2.2.1 and random_avatar ^0.0.7, version solving failed.
pub get failed (1; So, because seedwill_demo depends on both flutter_html ^2.2.1 and random_avatar ^0.0.7, version solving failed.)
I want to add avtar in my App but not able to do this because of dependency conflict/ required version error. I also trying to override dependency but its still not working. also trying this commands.
- Flutter clean
- Flutter pub get
But still not working.
ERROR:-
Because no versions of random_avatar match >0.0.7 <0.1.0 and random_avatar 0.0.7 depends on flutter_svg ^1.0.3, random_avatar ^0.0.7 requires flutter_svg ^1.0.3.
And because flutter_html >=2.0.0-nullsafety.1 <3.0.0-alpha.1 depends on flutter_svg >=0.22.0 <1.0.0, random_avatar ^0.0.7 is incompatible with flutter_html >=2.0.0-nullsafety.1 <3.0.0-alpha.1.
So, because seedwill_demo depends on both flutter_html ^2.2.1 and random_avatar ^0.0.7, version solving failed.
pub get failed (1; So, because seedwill_demo depends on both flutter_html ^2.2.1 and random_avatar ^0.0.7, version solving failed.)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我想您在
flutter 2
上工作,但是flutter 3
已发布。在pub
上,某些库默认与flutter 3
兼容。在这种情况下,并非总是最新的库是最佳选择。您必须找到哪个库不兼容。您可以将pubspec.yaml
放在这篇文章中吗?我们需要两个版本的pubspec.yaml。上一(pub get
没有错误)和新库。如果您向他们展示,我会尝试为您找到最佳的库版本。I guess You working on
Flutter 2
, butFlutter 3
is released. Onpub
, some libraries are default compatible withFlutter 3
. In this case, not always newest library is the best option. You must find which library is incompatible. Can You putpubspec.yaml
to this post? We need TWO version of pubspec.yaml. Previous (which have no error withpub get
) and new, with this new library. If You show them, I try find the best version of library for You.我遇到了看起来一样的问题,并且以某种方式设法通过升级颤动零件(更新或重新安装)来消除它们。您是否尝试过关注命令?
I had problems that look alike, and somehow managed to eliminate them by upgrading flutter parts (updating or reinstalling). Have you tried following commands?