Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Paket.dependency with version ranges fails when package has pinned dependency and that version is unlisted #1579
We can't use version ranges in the paket.dependency file when a nuget package has a pinned dependency which has been unlisted and we require that dependency as well as that package.
paket.dependencies brings in both packages, but tries to allow itself to use an unpinned version of the dependency:
For testing, the specific unlisted package we're having trouble with is
I would expect paket to bring in version 1.1.5 of NugetPackageB since it satisfies the requirements of both the package.dependencies and NugetPackageA.
The actual behaviour is to claim that no version matches both criteria, which is wrong as the required version exists, it's just unlisted.
If you pin the dependency to the same version as NugetPackageA or remove all version constraints, everything works ok. Version constraints are useful tho.
No, unlisted means that they're not on the nuget feed, but they are available for download since projects get built against specific versions.
I can see what's happening in that paket is saying "What versions are available and match the constraints", getting a shortlist, then seeing that 1.1.5 is not in that shortlist.
But it's still a valid setup as you can still find and install version 1.1.5. If you can convince paket to allow the configuration, it will print a nice warning about it being unlisted, and everything works fine.