- Speed up resolution, most of all in projects with many dependencies. The
solver now calls the registry's
versions/2once per package in a resolution, and only callsdependencies/3for the versions it considers instead of every version of a package.
- Fix
Protocol.UndefinedErrorwhen formatting a failure or logging debug output in a project whose consolidatedString.Charsprotocol doesn't include the solver's implementations, such as when the solver is vendored into a Mix archive. - Don't add a package's dependency incompatibilities again when the solver tries another version of the package. Since v0.2.0 they were added again each time, which repeated work in resolutions that backtrack.
- Add
HexSolver.constraint_to_requirement!/1to serialize constraints as version requirements. - Parse
>= 0.0.0-0as an unconstrained range and< 0.0.0-0as an empty constraint. - Accept intersections of pessimistic ranges such as
~> 1.0.0 and ~> 1.0. - Raise
HexSolver.UnsatisfiableRequirementErrorfor requirements with disjoint ranges such as~> 1.0 and >= 2.0.0. - Require Elixir 1.12 or later.
- Fix
FunctionClauseErrorwhen parsingandchains with more than two terms, two bounds in the same direction, or==. - Fix infinite loop when a dependency has an empty constraint.
- Add sub dependencies.
- Fix intersection of ranges during parsing.
- Do not override locked deps.
- Change "lock" to "the lock" in failure message.
- Raise when parsing intersected ranges.
- Skip unselected optionals during solving.
- Add support for package repositories (repos). Repos are the package source, so that if two packages with the same name but different repos are derived they will cause conflict.
HexSolver.run/5expects lists of maps instead of tuples in thedependenciesandlockedparameters.HexSolver.run/5returns{:ok, %{package() => {Version.t(), repo()}}for for the success case instead of{:ok, %{package() => Version.t()}}.
Initial version.