pubnub / dart

PubNub Dart SDK
Other
27 stars 15 forks source link

transitive dependency problem: xml package #94

Closed panalgin closed 1 year ago

panalgin commented 2 years ago

Some newer flutter 3.0 compatible packages started to use xml ^6.0.1 as a dependency and because pubnub depends on an older version (5.x.x), I'm having version resolving issues when I try to use the latest "flutter_svg" and pubnub packages

see the error message:

Because pubnub >=4.0.0-beta.0 depends on xml ^5.0.2 and flutter_svg >=1.1.0 depends on xml ^6.0.1, pubnub >=4.0.0-beta.0 is incompatible with flutter_svg >=1.1.0.
So, because myproject depends on both flutter_svg ^1.1.0 and pubnub ^4.1.3, version solving failed.
tfrysinger commented 2 years ago

I have run into this exact same problem as well. I am "solving" this currently by including the following override in my pubspec.yaml:

dependencies:
  flutter:
    sdk: flutter
  xml: ^6.0.1
  flutter_webrtc: ^0.8.7
  http: ^0.13.4
  form_field_validator: ^1.1.0
  shared_preferences: ^2.0.15
  pubnub: ^4.1.3
  connectivity_plus: ^2.3.2
  internet_connection_checker: ^0.0.1+4
  uuid: ^3.0.6
  logging: ^1.0.2
  logging_appenders: ^1.0.0
  flutter_svg: ^1.1.0

dependency_overrides:
  # Version required by pubnub
  xml: '5.0.2'

But clearly this is not an optimal solution

panalgin commented 2 years ago

Thanks, I'll try that until PubNub updates the dependencies internally

joknjokn commented 1 year ago

When will this be fixed?

pn-op commented 1 year ago

@panalgin this issue is addressed in v4.2.2