This package is used in code, but the package was not updated for last 3 years so need to replace package.
if any one Used this package or replace this package pls inform me.
error exactly is :-
Running "flutter pub get" in project...
Resolving dependencies...
The current Dart SDK version is 2.19.0.
Because build_runner >=2.4.0 requires SDK version >=3.0.0-134.0.dev <4.0.0 and no versions of build_runner match >2.3.3 <2.4.0, build_runner >2.3.3 is forbidden.
And because build_runner 2.3.3 depends on crypto ^3.0.0, build_runner >=2.3.3 requires crypto ^3.0.0.
And because every version of powerflutter depends on uuid ^2.0.0 which depends on crypto ^2.0.0, build_runner >=2.3.3 is incompatible with powerflutter.
So, because tacticboard depends on both powerflutter ^0.1.1+1 and build_runner ^2.3.3, version solving failed.
pub get failed
command: "/Users/Develop/flutter/bin/cache/dart-sdk/bin/dart __deprecated_pub --directory . get --example"
pub env: {
"FLUTTER_ROOT": "/Users/Develop/flutter",
"PUB_ENVIRONMENT": "flutter_cli:get",
"PUB_CACHE": "/Users/mac/.pub-cache",
}
exit code: 1
Process finished with exit code
I download the repo of powerflutter from here and tried to customize the repo.
3
Answers
you need to add git in your project,
then run the command line :"flutter upgrade"
Building flutter tool…
Flutter is already up to date on channel stable
Flutter 3.7.3 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 9944297138 (7 days ago) • 2023-02-08 15:46:04 -0800
Engine • revision 248290d6d5
Tools • Dart 2.19.2 • DevTools 2.20.1
I’ve downgraded
build_runner
to^2.3.3
because version2.4.0
relies on the 3.0.0 sdk which is in alpha.You can either change the
environment
sdk
property in pubspec.yaml to target the sdk version that is needed by your packages (although I wouldn’t do so since sdk 3.0.0 is in alpha), either downgrade the dependencies that requires such sdk version.So, summarized:
^2.3.3
since it does not rely on sdk versions greater than 3.0.0flutter pub get
Running following command in terminal fixed the issue for me:
sudo chown -R $(whoami) <path to your local flutter/bin/cache/pkg directory>