Getting Started with Phoenix - Could not find Hex, which is needed to build dependency :phoenix

I’m new to Elixir and Phoenix. I’ve heard so many good things about them that I thought I’d give it a try. However, my first attempt to get started met with an immediate obstacle:

$ mix deps.get
Could not find Hex, which is needed to build dependency :phoenix
**Shall I install Hex? (if running non-interactively, use “mix local.hex --force”) [Yn] **
Assertion failed: (ctx), function digest_update, file /BuildRoot/Library/Caches/, line 49.
Abort trap: 6

I am not impressed.

FYI, I’m running under macOS 10.13.2.

Did you follow the install instructions?

Before we begin, please take a minute to read the Installation Guide. By installing any necessary dependencies beforehand, we’ll be able to get our application up and running smoothly.

Here’s the command to install Hex (If you have Hex already installed, it will upgrade Hex to the latest version):

mix local.hex

Did you install Elixir through Homebrew? I have heard a number of people having issues when they installed Elixir through homebrew, updated to high sierra, then tried using Elixir. You should just have to uninstall then reinstall Elixir.

If I am not mistaken, the reason this happens is because Apple changed the SSL library used between Sierra and High Sierra.


This is precisely it. Apple did a stupid stupid thing and replaced OpenSSL with BoringSSL, which on it’s on is fine, however they made it so that apps that tried to compile with OpenSSL got BoringSSL instead, which is not quite compatible and thus this is the stupid stupid thing, I.E. it crashes depending on the functions used.

As I recall this is fixed with the absolute latest of the latest Beam versions by forcing a different call set.

1 Like