0
votes

This is a part of my pubspec.yaml file

environment:
  sdk: ">=2.7.0 <3.0.0"

dependencies:
  flutter:
    sdk: flutter
  flutter_localizations:
    sdk: flutter

  http: ^0.13.3
  syncfusion_flutter_calendar: ^18.4.47
  flutter_chat_bubble: ^1.0.2
  intl: ^0.17.0
  flutter_local_notifications: ^4.0.1+2
  provider: ^5.0.0
  sqflite_sqlcipher: ^2.0.0
  logging: ^1.0.1
  grouped_list: ^3.5.0
  visibility_detector: ^0.1.5
  smart_select: ^4.3.2
  dropdown_search: ^0.5.0
  synchronized: ^3.0.0
  local_auth: ^1.1.5
  font_awesome_flutter: ^9.0.0
  lite_rolling_switch: ^0.1.1
  flutter_webview_plugin: ^0.3.11
  email_validator: ^1.0.6
  package_info: ^2.0.0
  connectivity: ^3.0.3
  device_info: ^2.0.0
  encrypt: ^5.0.0
  flutter_html: ^1.3.0
  url_launcher: ^6.0.2
  flutter_inappwebview: ^5.3.2
  signalr_core: ^1.1.1

When I try to run the app I get this error

Running "flutter pub get" in mobile_app1... Because no versions of signalr_core match >1.1.1 <2.0.0 and signalr_core 1.1.1 depends on tuple ^2.0.0, signalr_core ^1.1.1 requires tuple ^2.0.0. And because no versions of tuple match >2.0.0 <3.0.0 and tuple 2.0.0 depends on quiver ^3.0.0, signalr_core ^1.1.1 requires quiver ^3.0.0. And because flutter_layout_grid 0.10.5 depends on quiver ^2.0.0 and no versions of flutter_layout_grid match >0.10.5 <0.11.0, signalr_core ^1.1.1 is incompatible with flutter_layout_grid ^0.10.5. And because flutter_html 1.3.0 depends on flutter_layout_grid ^0.10.5 and no versions of flutter_html match >1.3.0 <2.0.0, signalr_core ^1.1.1 is incompatible with flutter_html ^1.3.0. So, because mobile_app1 depends on both flutter_html ^1.3.0 and signalr_core ^1.1.1, version solving failed. pub get failed (1; So, because mobile_app1 depends on both flutter_html ^1.3.0 and signalr_core ^1.1.1, version solving failed.)

I solved this problem by adding this in my pubspec.yaml file

dependency_overrides:
  quiver: ^3.0.0

Is there any better way to resolve this conflict?

1

1 Answers

2
votes

Set them all toany, then run flutter pub get.

Now you can look in the pubspec.lock file and see what versions you got and put them in pubspec.yaml.