Mix "Hex request failed" in CI
Mix tried to reach the Hex registry and the HTTP request failed. The package metadata or tarball could not be downloaded.
What this error means
deps.get or hex.info fails with Hex request failed or a connection/timeout error against repo.hex.pm. It is usually transient and clears on a re-run.
** (Mix) Hex request failed.
The HTTP client failed with reason: :timeout
Request: GET https://repo.hex.pm/installs/...Common causes
Transient registry or network failure
A timeout, DNS hiccup, or 5xx from Hex/the CDN makes a single request fail even though the package exists.
Proxy or TLS misconfiguration
A CI proxy or missing CA certificates blocks HTTPS to repo.hex.pm.
How to fix it
Retry the fetch
Re-run deps.get; transient Hex failures usually pass on retry. On Latchkey managed runners, self-healing auto-retries transient registry fetch failures so a one-off Hex blip does not fail the job.
mix deps.getConfigure proxy and certificates
- Set HTTP(S)_PROXY if the runner requires a proxy.
- Ensure CA certificates are installed for TLS to repo.hex.pm.
- Point Hex at a reachable mirror with
mix hex.config mirror_urlif needed.
Cache the Hex/deps directory
Cache ~/.hex and deps so most builds avoid the network entirely.
How to prevent it
- Cache Hex artifacts between runs.
- Keep CA certificates current on runners.
- Use a reliable Hex mirror for high-volume CI.