Skip to content
This repository has been archived by the owner on Apr 10, 2024. It is now read-only.

Version solving issue for package_info_plus #73

Closed
jt274 opened this issue Oct 9, 2023 · 7 comments
Closed

Version solving issue for package_info_plus #73

jt274 opened this issue Oct 9, 2023 · 7 comments
Assignees
Labels
type:chore This issue requires simple maintenance to be fixed

Comments

@jt274
Copy link

jt274 commented Oct 9, 2023

Describe the bug
Because App depends on google_maps_place_picker_mb ^3.1.2 which depends on package_info_plus ^4.1.0, package_info_plus ^4.1.0 is required.
So, because App depends on package_info_plus ^5.0.0, version solving failed.

To Reproduce
Steps to reproduce the behavior:

  1. Create flutter app
  2. Add dependencies of google_maps_place_picker_mb: ^3.1.2 and package_info_plus: ^5.0.0
  3. Build app

Expected behavior
App should build with package being updated to latest dependencies.

@martin-braun
Copy link
Member

Waiting for zeshuaro/google_api_headers#164 to be shipped.

@martin-braun martin-braun self-assigned this Oct 9, 2023
@martin-braun martin-braun added the type:chore This issue requires simple maintenance to be fixed label Oct 9, 2023
@martin-braun
Copy link
Member

@jt274 package_info_plus API hasn't changed, it was major bumped due to Kotlin version bump.

Put this in your pubspec.yaml until the next update is shipped and you can continue your work:

dependency_overrides:
  package_info_plus: any

Thank you.

@martin-braun martin-braun pinned this issue Oct 9, 2023
@jt274
Copy link
Author

jt274 commented Oct 10, 2023

@martin-braun This also appears to be an issue with geolocator 10.1.0. I had to override both packages to build.

@zakblacki
Copy link

Also waiting for update

@martin-braun
Copy link
Member

@zakblacki I want to look into this soon, I will report back.

@martin-braun
Copy link
Member

@zakblacki google_api_headers is still stuck on v4 of package_info_plus. I can't really do something about it, unless I choose to maintain even more packages. Flutter's dependency system is annoying.

@jt274 Flutter often succeeds dependency resolution of same packages (dependencies of dependencies), if their major version match, because dependencies are included using ^x.x.x by default, so only a minimum minor version of the given major version has to match. This obviously breaks if a package maintainer decides to change a major version of a dependency without changing their own major version as well.

If you update minor dependencies, your build can suddenly stop working, since a major version of a dependency of a dependency doesn't match. This is what the pubspec.lock prevents from happening and this is why it should be committed as well. You should consider to install geolocator 10.0.1 for now. I'm still locked on raising package_info_plus.

I start to see why the convention of raising your own major when other dependencies have new majors is such a necessity, so I will consider to incorporate this. This stalling is a huge problem in general, that we cannot overcome without dependency_overrides.

@martin-braun martin-braun added state:onhold This issue will be fixed when an external dependency has been updated and removed state:onhold This issue will be fixed when an external dependency has been updated labels Nov 28, 2023
@martin-braun
Copy link
Member

martin-braun commented Nov 30, 2023

Issue will be solved in the next release.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type:chore This issue requires simple maintenance to be fixed
Projects
None yet
Development

No branches or pull requests

3 participants