Because analyzer >=2.0.0 depends on meta ^1.7.0 ... (because myP depends on both flutter_test any from sdk and analyzer 2.0.0, version solving failed) - flutter

Is there any other way to resolve this issue other than going on the dev channel (or than using analyzer <2.0.0)? I once made a poor, time consuming experience with the dev channel which is why I would prefer sticking with stable. And I need 2.0.0 for a bug fix of another package.
Because analyzer >=2.0.0 depends on meta ^1.7.0 and every version of
flutter_test from sdk depends on meta 1.3.0, analyzer >=2.0.0 is
incompatible with flutter_test from sdk. So, because denkschule
depends on both flutter_test any from sdk and analyzer 2.0.0, version
solving failed. pub get failed (1; So, because myP depends on both
flutter_test any from sdk and analyzer 2.0.0, version solving failed.)

In this case, since version 1.7.0 of package:meta is probably backward compatible with version 1.3.0, I think that it would be safe to add a dependency override to your pubspec.yaml file to force using the newer version:
dependency_overrides:
meta: ^1.7.0
(package:meta in particular should be safe since that package just provides annotations for static analysis and shouldn't affect runtime behavior.)

Related

Because every version of flutter_test from sdk depends on path 1.8.2 other package depends on path ^1.8.3,

(I already tried this: Because every version of flutter_test from sdk depends on path 1.8.1 openfoodfact: any)
I want to add a package ("openfoodfacts") to my pubspec file.
When I do it via Terminal: flutter pub add openfoodfacts it added the version openfoodfacts: ^0.0.8 which is old. Current version is 2.2.1.
When I try to upgrade, I receive this error:
Because every version of flutter_test from sdk depends on path 1.8.2 and openfoodfacts >=2.0.0 depends on path ^1.8.3, flutter_test from sdk is incompatible with openfoodfacts >=2.0.0.
So, because meatcheat depends on both openfoodfacts ^2.2.1 and flutter_test from sdk, version solving failed.
Anybody a clue what is wrong, or who can i upgrade flutter test to path 1.8.3?
I don't really not what flutter does, but I even reinstalled flutter, and they still install an outdated version of path.
use this command:
flutter update-packages --force-upgrade
and everything works fine.

integration_test Depends on Old Version of test_api (0.4.3) - How Can I Upgrade?

I'm trying to keep all my dependencies up to date, but integration_test and flutter_test seem to depend on test_api 0.4.3, and won't accept versions higher than this. I've had this problem for several months. I've watched several Flutter versions roll by. Each time, I think it will be fixed, and the problem remains. I currently have installed
Flutter 2.8.1 • channel stable
The current version of test is 1.20.1 but if I try to use the latest package, I get this error when I do a flutter pub get
Because test >=1.20.0 depends on test_api 0.4.9 and every version of integration_test from sdk depends on test_api 0.4.3, test >=1.20.0 is incompatible with
integration_test from sdk.
So, because assets_app depends on both integration_test from sdk and test ^1.20.1, version solving failed.
I checked out the package on GitHub for integration_test and as you can see, it points to 0.4.9 of test_api. So, the only thing I can think of is that the current Flutter SDK points to an older version of integration_test.
It looks as though test is generally outdated because if I try to upgrade analyzer, I get this:
Because every version of flutter_test from sdk depends on test_api 0.4.3 and test >=1.20.0 depends on test_api 0.4.9, flutter_test from sdk is incompatible with test >=1.20.0.
And because test >=1.17.10 <1.20.0 depends on analyzer >=1.0.0 <3.0.0 and test >=1.16.6 <1.17.10 depends on analyzer ^1.0.0, if flutter_test from sdk and test >=1.16.6 then analyzer >=1.0.0 <3.0.0.
And because test >=1.16.1 <1.16.6 depends on analyzer >=0.39.5 <2.0.0 and test >=1.16.0-nullsafety.10 <1.16.1 depends on analyzer >=0.36.0 <0.42.0, if flutter_test from sdk and test >=1.16.0-nullsafety.10 then analyzer >=0.36.0 <3.0.0.
And because test >=1.16.0-nullsafety <1.16.0-nullsafety.8 requires SDK version >=2.10.0-0 <2.12.0 and test <1.3.0 requires SDK version >=1.8.0 <2.0.0-∞, if flutter_test from sdk and test <1.3.0-∞ or >=1.16.0-nullsafety <1.16.0-nullsafety.8 or >=1.16.0-nullsafety.10 then analyzer >=0.36.0 <3.0.0.
And because test >=1.3.0 <1.16.0-nullsafety depends on yaml ^2.0.0 and test >=1.16.0-nullsafety.8 <1.16.0-nullsafety.12 depends on yaml ^2.0.0, if flutter_test from sdk and test any then analyzer >=0.36.0 <3.0.0 or yaml ^2.0.0.
And because assets_app depends on analyzer ^3.2.0 which depends on yaml ^3.0.0, flutter_test from sdk is incompatible with test.
So, because assets_app depends on both flutter_test from sdk and test any, version solving failed.
How can we upgrade integration_test so that we can also use test_api 0.4.9, and test 1.20.1 ?
Flutter pins it's dependencies. That's it. You have two options.
Wait for the next flutter release that has a version pin that you want
add a dependency override to get the latest version
In my case the problem was with the integration_test package
Accessing the flutter eintegration test package via cli , you can update the dependencies.
pubspec.yaml in integration_test contains this in every package you can update.
archive: 3.3.0 # THIS LINE IS AUTOGENERATED - TO UPDATE USE "flutter update-packages --force-upgrade"
So I ran "flutter update-packages --force-upgrade"
He updated the conflict and I had no more problems.

flutter HERE Maps SDK - dependency on ffi: 1.0.0 - conflicting with another plugin

running into the following issue where Here SDK is conflicting with another plugin (file_picker)...
Because every version of here_sdk from path depends on ffi 1.0.0 and file_picker >=4.0.0 depends on ffi ^1.1.2, here_sdk from path is incompatible with file_picker >=4.0.0.
So, because AppName depends on both file_picker 4.1.3 and here_sdk from path, version solving failed.
pub get failed (1; So, because AppName depends on both file_picker 4.1.3 and here_sdk from path, version solving failed.)
The issue is the "ffi: 1.0.0" in Here's pubspec.yaml which locks in version 1.0. For reference, I am using 4.8.3 of the SDK. Is there any reason why Here doesn't use the carat ^ notation so that pub can use the latest 1.x version and not the hardcoded 1.0.0 version? I can go in and change the pubspec.yaml version myself for Here SDK, but i don't want to introduce any incompatibility. Technically this should be ok because of semantic-versions, but of course i don't want to make any assumptions.
thoughts? thanks!
We are evaluating upgrading ffi version but there is no certain timeline on this by when this will be available. It is possible to change the ffi version in the pubspec.yml but as explained above that it is risky.

Flutter automation testing dependency issue

I am trying to start with UI automation tests in my flutter app. I am following this particular VIDEO. I was able to establish the part where you write the following snippet into pubspec.yaml
dev_dependencies:
flutter_test:
sdk: flutter
flutter_driver:
sdk: flutter
I need both flutter_test and flutter driver.
But when I add
test: any
I get this following error after hitting Get Dependencies
The current Dart SDK version is 2.8.4.
Because test <1.3.0 requires SDK version >=1.8.0 <2.0.0-∞ and test
=1.16.0-nullsafety requires SDK version >=2.10.0-0 <2.11.0, test <1.3.0-∞ or >=1.16.0-nullsafety is forbidden.
And because test >=1.3.0 <1.12.0 depends on boolean_selector ^1.0.0,
test <1.12.0-∞ or >=1.16.0-nullsafety requires boolean_selector
^1.0.0.
And because test >=1.9.3 <1.15.4 depends on analyzer >=0.36.0 <0.40.0
and every version of flutter_test from sdk depends on boolean_selector
2.0.0, if flutter_test any from sdk and test <1.15.4-∞ or >=1.16.0-nullsafety then analyzer >=0.36.0 <0.40.0.
And because test >=1.15.4 <1.16.0-nullsafety depends on analyzer
=0.36.0 <0.41.0 and json_serializable 0.5.8+1 depends on analyzer ^0.32.0, one of flutter_test any from sdk or test any or
json_serializable 0.5.8+1 must be false.
Because json_serializable >=0.1.0+1 <=0.5.8 requires SDK version
=1.22.1 <2.0.0-∞ and no versions of json_serializable match >0.5.8+1 <0.6.0, json_serializable >=0.1.0+1 <0.5.8+1 or >0.5.8+1 <0.6.0 is
forbidden.
Thus, one of flutter_test any from sdk or test any or
json_serializable >=0.1.0+1 <0.6.0 must be false.
And because MyApp depends on json_serializable ^0.5.0,
flutter_test from sdk is incompatible with test.
So, because MyApp depends on both flutter_test any from sdk and
test any, version solving failed. pub get failed (1; So, because
MyApp depends on both flutter_test any from sdk and test any,
version solving failed.)
I even tried to put there some specific version like 1.5.4 into the test parameter I get the same error.
PS:
My Flutter version is 1.17.4
My Dart Version 2.8.4
Is there a way how get rid of the error mentioned above? As I said, when I do not use "test" parameter everything works. I guess I will need this parameter later on.

Flutter issue - Flutter_driver from sdk depends on file 5.0.6 and flutter_gallery depends on file 5.0.7

I got this issue using flutter packages get:
Because every version of flutter_driver from sdk depends on file 5.0.6 and flutter_gallery depends on file 5.0.7, flutter_driver from sdk is forbidden.
So, because flutter_gallery depends on flutter_driver any from sdk, version solving failed.
pub upgrade failed (1)
I don't know what I am supposed to do here, I was trying to compile this flutter example: https://github.com/flutter/flutter/tree/master/examples/flutter_gallery
This may be because flutter dependencies are locked to fixed versions.
You can check this in the pubspec.yaml for flutter_driver which is in
\flutter\packages\flutter_driver
and compare it to the latest version at GitHub
If so, flutter upgrade won't necessarily update the dependencies versions. Doing a forced update of the packages may resolve your problem.
flutter update-packages --force-upgrade