Good dependency solver written in Elixir?

I am looking for a good dependency solver written in Elixir. Currently, I use a hybrid Erlang/Elixir solution code from with https://github.com/chef/chef-server/tree/master/src/oc_erchef/apps/depsolver

Depsolver is a dependency solver package for erlang. You supply it with a list of versioned objects that are in the world and then you can solve for different version constraints. If no solution can be found, detailed back tracking information is returned that can be used to detect what exact dependencies are causing the problem.

It kinda works, but I have some specific needs (tracking info when a dep object has a certain property) and adapting the Erlang part is quite hard.

Question: Who knows a nice dependency solver, with versioned objects, written in Elixir?

That sounds like the kind of thing that Hex would include. The source code for Hex is available https://github.com/hexpm/hex. I don’t know how straightforward it might be to extract it’s dependency resolution code and adapt it to another environment, but it might be worth a little of your time. If all else fails you could work with the Hex folks to separate out their dependency resolution and make it a more general library in much the same way that Phoenix Pub Sub was separated out and can stand on its own.

3 Likes