ConnectyCube / connectycube-flutter-sdk-releases

ConnectyCube Flutter SDK Releases
7 stars 1 forks source link

connectycube_sdk intl needs to be upgraded #92

Closed pedrostick3 closed 1 year ago

pedrostick3 commented 1 year ago

Platform (use [x]) [] Android [x] iOS [] macOS [] Windows [] Web

Device info Manufacture: Apple inc. Model: iPhone X OS version: 16.4.1

Describe the bug: Running flutter pub get do not work because connectycube_sdk needs intl: ^0.18.0.

Steps to Reproduce:

  1. Upgrade Flutter to the latest version (3.10.0)
  2. Run flutter pub get
  3. This Error will apear: Because connectycube_sdk >=2.0.0-nullsafety.1 depends on intl ^0.17.0 and planet_agora depends on intl ^0.18.0, connectycube_sdk >=2.0.0-nullsafety.1 is forbidden.

Logs:

[planet_agora] flutter pub get
Resolving dependencies...
Because connectycube_sdk >=2.0.0-nullsafety.1 depends on intl ^0.17.0 and planet_agora depends on intl ^0.18.0, connectycube_sdk >=2.0.0-nullsafety.1 is forbidden.
So, because planet_agora depends on connectycube_sdk ^2.5.3, version solving failed.
exit code 1
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.10.0, on macOS 13.0 22A380 darwin-arm64, locale pt-PT)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 14.3)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2022.2)
[✓] VS Code (version 1.78.2)
[✓] Connected device (3 available)
[✓] Network resources

• No issues found!

Actual result: Can't build APP since I can't load dependencies.

Expected behavior: Build APP normally.

TatankaConCube commented 1 year ago

will review our dependencies and update them to the latest versions if it is possible according to the compatibility with other dependencies

lordlamee commented 1 year ago

I have the same issue. So I'm basically stuck

TatankaConCube commented 1 year ago

@pedrostick3 @lordlamee new version 2.5.4 contains possible updates for dependencies our SDK depends on. Please close the ticket if your issue was resolved.

lordlamee commented 1 year ago

@TatankaConCube thanks for your fast response. This is a pretty weird issue that should ideally be resolved on the sdk. It seems flutter_localization requests to depend on intl: ^0.18.0 as opposed to ^0.18.1 thus the problem persists.

TatankaConCube commented 1 year ago

@lordlamee do you offer to downgrade from ^0.18.1 to ^0.18.0? sorry but we will not do this, try to override this dependency in your project using:

dependency_overrides: 
  intl: ^0.18.0
lordlamee commented 1 year ago

Well I just learned something. Thank you!. That works

pedrostick3 commented 1 year ago

Hello, when i try with intl: 0.18.0 this error appears:

Because connectycube_sdk >=2.5.4 depends on intl ^0.18.1 and "MyProjectName" depends on intl 0.18.0, connectycube_sdk >=2.5.4 is forbidden.
So, because "MyProjectName" depends on connectycube_sdk ^2.5.5, version solving failed.

When i try with intl: ^0.18.0 this error appears:

Because connectycube_sdk >=2.5.4 depends on intl ^0.18.1 and every version of flutter_localizations from sdk depends on intl 0.18.0, connectycube_sdk >=2.5.4 is incompatible with flutter_localizations from sdk.
So, because planet_agora depends on both flutter_localizations from sdk and connectycube_sdk ^2.5.5, version solving failed.

I think that downgrading intl: ^0.18.1 to intl: ^0.18.0 on connectycube_sdk is the best choice since is the only package that appears with this error. And thats great too because Flutter will handle and upgrade the minor version of intl in connectycube_sdk if necessary.

(btw, i'm stuck and i cannot run my app since pubspec dependencies does not load properly just because of this error)

TatankaConCube commented 1 year ago

@pedrostick3 please use the solution from this comment

pedrostick3 commented 1 year ago

Sorry, I missed that override part. Now I've tested and it works. Thanks for that solution. :)