Pub get failed, [1] Resolving dependencies… Incompatible version constraints on code_transformers

左心房为你撑大大i 提交于 2019-12-11 02:23:38

问题


Below is my pubspec.yaml file

name: MyApp
description: A sample command-line application
dependencies:
  csv_sheet: any
  redstone: any
  shelf_static: any
  browser: any
  angular: ">=0.14.0 <0.15.0"
  polymer: ">=0.13.0"
  core_elements: ">=0.2.0+1"
  paper_elements: ">=0.1.1+2"

I am getting the follow error

Pub get failed, [1] Resolving dependencies...
Incompatible version constraints on code_transformers:
- angular 0.14.0 depends on version >=0.1.4+2 <0.2.0
- polymer 0.13.0 depends on version >=0.2.0 <0.3.0

So angular and polymer are using different version of code_transformers.

Is there a combination of angular and polymer version constraint that will make my pubspec.yaml work?


回答1:


You can add

dependency_overrides:
  code_transformers: '>=0.2.0 <0.3.0'

to your pubspec.yaml file.

This is at your own risk as Angular is not tested with this code_transformers version.
As alternative you can use an older version of Polymer or wait for the next Angular release.



来源:https://stackoverflow.com/questions/25691686/pub-get-failed-1-resolving-dependencies-incompatible-version-constraints-o

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!