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

Dependency conflict #73

Open
eugkhp opened this issue Sep 11, 2024 · 9 comments
Open

Dependency conflict #73

eugkhp opened this issue Sep 11, 2024 · 9 comments

Comments

@eugkhp
Copy link

eugkhp commented Sep 11, 2024

I'm new to mix/elixir and when I was trying to add the dependency it failed with an error

Resolving Hex dependencies...
Resolution completed in 0.253s
Because the lock depends on swoosh 1.16.9 which depends on req ~> 0.5 or ~> 1.0, the lock requires req ~> 0.5 or ~> 1.0.
And because every version of instructor depends on req ~> 0.4.0, the lock is incompatible with instructor.
And because your app depends on the lock, no version of instructor is allowed.
So, because your app depends on instructor ~> 0.0.5, version solving failed.

Is it something I could solve on my end or the req version should be updated in instructor?

@stryderjzw
Copy link

Should be related to this PR here:
#59

@eugkhp
Copy link
Author

eugkhp commented Sep 12, 2024

Hmm, looks like it was merged 3 month ago, am I using the wrong version?

@stryderjzw
Copy link

https://github.com/thmsmlr/instructor_ex/releases/tag/v0.0.5

The latest version was before this PR. Since then, there hasn't been a release yet.

To make it work, you can use the main branch for now.

@eugkhp
Copy link
Author

eugkhp commented Sep 12, 2024

Oooh, I see, thanks

@BhargavaSwamy
Copy link

BhargavaSwamy commented Oct 21, 2024

Loved trying out Instructor in Livebook but facing a dependency conflict between Swoosh and Instructor over different versions of Req. Any guidance on how to resolve this would be greatly appreciated!

Updating instructor (https://github.com/thbar/instructor_ex.git - main)
remote: Enumerating objects: 444, done.
remote: Counting objects: 100% (183/183), done.
remote: Compressing objects: 100% (47/47), done.
remote: Total 444 (delta 156), reused 136 (delta 136), pack-reused 261 (from 1)
Resolving Hex dependencies...
Resolution completed in 0.132s
Because the lock depends on swoosh 1.17.2 which depends on req ~> 0.5 or ~> 1.0, the lock requires req ~> 0.5 or ~> 1.0.
And because your app depends on the lock, req ~> 0.5 or ~> 1.0 is required.
So, because your app depends on req ~> 0.4.0, version solving failed.

@Azraiths
Copy link

@BhargavaSwamy try mix deps.unlock swoosh then mix deps.get

@BhargavaSwamy
Copy link

@Azraiths - Tried your solution and Instructor is now working in my project. Thank you for helping out!

@ospaarmann
Copy link

It works with swoosh version 1.16, just unlock swoosh and then change the version to 1.16 if you use a higher version.

@BhargavaSwamy
Copy link

@ospaarmann - Thank you !

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

5 participants