Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The lower bound of "sdk: '>=2.1.0 <3.0.0'" must be 2.12.0 or higher to enable null safety. #39

Open
eansharma opened this issue Aug 26, 2024 · 1 comment

Comments

@eansharma
Copy link

flutter pub add flutter_styled_toast
Note: intl is pinned to version 0.19.0 by flutter_localizations from the flutter SDK.
See https://dart.dev/go/sdk-version-pinning for details.

The current Dart SDK version is 3.5.1.

Because flutter_styled_toast <2.0.0 doesn't support null safety and flutter_styled_toast >=2.0.0 depends on flutter_localizations from sdk, every version of flutter_styled_toast requires flutter_localizations from sdk.
And because every version of flutter_localizations from sdk depends on intl 0.19.0, every version of flutter_styled_toast requires intl 0.19.0.
So, because hrms depends on both intl ^0.17.0 and flutter_styled_toast any, version solving failed.

The lower bound of "sdk: '>=2.1.0 <3.0.0'" must be 2.12.0 or higher to enable null safety.
For details, see https://dart.dev/null-safety

@egonbeermat
Copy link

egonbeermat commented Aug 27, 2024

Assuming 'hrms' is your app, make sure you have:

intl: 0.19.0

in your pubspec.yaml under dependencies. I always find that error message moderately confusing, but it seems like 'hrms' has a reference to intl: ^0.17.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants