Best Version Requirment for HTTPoison and Poison

I recently started working on a pretty big Elixir project. The amount of dependencies grew over time and it’s getting harder and harder to maintain them.

The main issue is due to 2 very popular libraries: HTTPoison and Poison.

Both of them are used in 2 different major versions:

HTTPoison: 0.x and 1.x
Poison: 2.x and 3.x

I currently have not run into backward compatibility issues so in a project where I control all dependencies I usually go for updating to the latest version. Would be great if someone could share their experience with this.

I am currently trying to go through all the dependencies that pin the dependencies down to the older version (e.g. something like {:httpoison, "~> 0.13"} will never update to 1.x).

I’m jsut wondering, what is the best version string I should replace this.

For HTTPoison I settled for: ~> 0.13 or ~> 1.1
For Poison: ~> 2.0 or ~> 3.1

Any other recommendations?

1 Like

Did You think about Jason to replace Poison?


Never heard of it, will consider it for my own projects. Thanks.

However I don’t think it’s a good idea, changing the JSON libraries of random Open Source projects.

It is not a random project, It’s a project from core team member, and it will probably replace Poison in the future due to its fast nature :slight_smile:

1 Like