[英]Pubspec.yaml throwing inconsistent errors and no conflicts
我看到Dartson和mongo_dart出现了一个奇怪的问题。
我正在运行mongo_dart 0.1.46。 -我需要将其升级到mongo_dart 0.2.4
但是,当我升级mongo_dart时-我收到有关dartson的以下错误
软件包mongo_dart没有与0.2.4匹配的版本,该版本源自:-票证取决于0.2.4版本
使用:
dependencies:
#Server Dependencies
json_object: "1.0.19"
mongo_dart: "0.2.4"
connection_pool: "0.1.0+2"
dartson: "0.2.4"
guinness: "0.1.17"
html: "0.12.2"
shelf: '>=0.6.2 <0.7.0'
shelf_static: "0.2.2"
shelf_route: "0.14.0"
这很奇怪,因为mongo_dart:pub.dartlang上存在“ 0.2.4”,并且可以单独使用https://pub.dartlang.org/packages/mongo_dart
通过测试pubspec.yaml中每个软件包的删除,我能够确定与dartson的冲突。
如果我将dartson移到依赖项列表的顶部,则会得到相反的结果:
dependencies:
#Server Dependencies
dartson: "0.2.4"
json_object: "1.0.19"
mongo_dart: "0.2.4"
connection_pool: "0.1.0+2"
guinness: "0.1.17"
html: "0.12.2"
shelf: '>=0.6.2 <0.7.0'
shelf_static: "0.2.2"
shelf_route: "0.14.0"
软件包dartson没有与以下版本相匹配的0.2.4版本:-票证取决于0.2.4版本
一起删除dartson可使mongo_dart正确安装。
这两个库之间是否存在已知问题? 有没有冲突浮出水面?
问题 :我如何使mongo_dart 0.2.4与Dartson 0.2.4一起运行
我已经在您的pubspec上以详细模式运行pub get,问题似乎与软件包logging
存在不同的依赖关系Dartson依赖于0.9版,而mongo_dart依赖于当前版本0.11。 logging
同时,您可以尝试将dependency_ovverride添加到您的pubspec。 当我将ovverride添加到您的pubspec中时,它对我有用
name: test_pubspec
dependencies:
json_object: "1.0.19"
mongo_dart: "0.2.4"
connection_pool: "0.1.0+2"
dartson: "0.2.4"
guinness: "0.1.17"
html: "0.12.2"
shelf: '>=0.6.2 <0.7.0'
shelf_static: "0.2.2"
shelf_route: "0.14.0"
dependency_overrides:
logging: '^0.11.0'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.