Skip to content

chore(deps): update dependency hackney to v4 - autoclosed#864

Closed
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/hackney-4.x
Closed

chore(deps): update dependency hackney to v4 - autoclosed#864
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/hackney-4.x

Conversation

@renovate

@renovate renovate Bot commented Apr 22, 2026

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Type Update Change
hackney (source) prod major ~> 1.18~> 4.0

Release Notes

benoitc/hackney (hackney)

v4.0.0: hackney 4.0.0

Compare Source

Hackney 4 trims the client down. The HTTP/2 and HTTP/3 stacks are now delegated to erlang_h2 and erlang_quic, so hackney no longer ships its own framing, HPACK / QPACK codecs, control streams or state machines. The HTTP/3 path is fully RFC 9114 compliant via quic_h3, with ALPN negotiation, Alt-Svc discovery (RFC 7838), and the same hackney:request/5 API as HTTP/1.1.

The bundled metrics subsystem is gone. In its place a Go-style middleware chain runs around hackney:request/1..5, configured per request with {middleware, [Fun, ...]} or globally via application:set_env(hackney, middleware, [...]). Users plug in prometheus, telemetry or anything else without hackney owning the policy. See the Middleware Guide and the HTTP/3 Guide.

Breaking

  • Removed hackney_metrics, hackney_metrics_backend, hackney_metrics_prometheus, hackney_metrics_dummy. The metrics_backend app env is no longer read. Migration recipes for prometheus and telemetry are in guides/middleware.md. Pool state is still observable through hackney_pool:get_stats/1.
  • HTTP/2 and HTTP/3 low-level message tags and modules moved to the new libraries. The user-facing hackney:request/5 API is unchanged.

What's new

  • Middleware chain (hackney_middleware): outermost-first composition, request rewrite, response rewrite, short-circuit, per-request or global config.
  • HTTP/3 via quic_h3: pure Erlang QUIC stack, no NIFs. ALPN-negotiated, opt-in with {protocols, [http3, http2, http1]} or application:set_env(hackney, default_protocols, [http3, http2, http1]).
  • Alt-Svc auto-discovery: server Alt-Svc headers are now parsed and cached on every response (HTTP/1.1, HTTP/2 and HTTP/3), so subsequent requests can upgrade to HTTP/3 transparently. Honors clear and merges multiple Alt-Svc headers per RFC 7230 §3.2.2.
  • HTTP/2 connection-pooling stability fixes for sustained concurrent load (#​836).

Deps

  • h2 0.4.0
  • quic 1.0.0

Full changelog: https://github.com/benoitc/hackney/blob/4.0.0/NEWS.md

v3.2.1

Compare Source

Bug Fixes
  • Fix recv_timeout option being ignored for pooled connections (#​832)
  • Fix off-by-one error in HPACK decoding (#​831)
  • Fix invalid match in handle_h2_frame/2 for HTTP/2 window updates (#​829)
  • Fix binary syntax in EDoc comment to fix XML parsing error

v3.2.0: hackney 3.2.0

Compare Source

Refactor
  • Replace all cowlib modules with hackney-native implementations
  • Remove src/libs/ directory (all modules moved to src/)
Performance
  • HTTP/2 state machine optimizations:
    • Stream caching for recently accessed streams
    • gb_sets for lingering streams (O(log N) vs O(N) lookups)
    • IOList accumulation for header fragments
  • HPACK and QPACK header compression with O(1) static table lookups
  • WebSocket: use rand:bytes/1 instead of crypto:strong_rand_bytes/1 for mask keys
Added
  • h2spec HTTP/2 compliance testing (95% pass rate - 139/146 tests)
    • h2spec_server.erl: Minimal HTTP/2 server for compliance testing
    • h2spec_SUITE.erl: CT suite for running h2spec tests
    • Makefile target: make h2spec-test
  • HTTP/3 E2E tests against real servers
    • hackney_http3_e2e_SUITE.erl: Tests against Cloudflare, Google, quic.tech
    • Makefile targets: make http3-e2e-test, make all-e2e-test
  • HTTP/2 machine benchmarks (hackney_http2_machine_bench.erl)
Bug Fixes
  • Fix HTTP/2 flow control for body sending (use send_or_queue_data/4)
  • Fix async 204/304/HEAD responses not sending done message
  • Fix unknown HTTP/2 frame types not being ignored (RFC 7540 4.1)
  • Fix HTTP/2 frame size validation

v3.1.2

Compare Source

Dependencies
  • Bump quic dependency to 0.10.1

v3.1.1: hackney 3.1.1

Compare Source

Bug Fixes

  • Fix HTTP/3 Fin flag handling for HEAD requests and responses without body
  • Bump quic dependency to 0.7.1 (fixes packet number reconstruction)

Added

  • Add TLS options support in hackney_quic (verify, cacerts, cacertfile, SNI)
  • Add redirect following in hackney_h3 (follow_redirect, max_redirect options)
  • Add HTTP/3 integration and redirect test suites (36 new tests)

v3.1.0

Compare Source

Refactor

  • Replace QUIC NIF with pure Erlang implementation. HTTP/3 now works with zero external dependencies - no CMake, Go, or C compiler needed. Just rebar3 compile.

Removed

  • Remove c_src/ directory containing lsquic, BoringSSL, and NIF code (~1.3M lines of C)
  • Remove do_cmake.sh and do_quic.sh build scripts

Added

  • Add hackney_qpack.erl for QPACK header compression (RFC 9204)

Changed

  • hackney_quic:is_available/0 now always returns true (pure Erlang is always available)
  • Update documentation to reflect no C dependencies

Dependencies

  • Add quic ~>0.5.1 (pure Erlang QUIC implementation)

v3.0.3

Compare Source

Bug Fixes
  • Restore function-based streaming body support (#​821). Functions passed to send_body/2 now work correctly for iterative body streaming, supporting both stateless fun() -> {ok, Data} | eof and stateful fun(State) -> {ok, Data, NewState} | eof forms.
CI
  • Fix FreeBSD CI job by adding pcre2 package to resolve git linker error

v3.0.2

Compare Source

Bug Fixes
  • Add default Content-Type: application/octet-stream header when sending a body without explicit Content-Type (#​823). This restores 1.x behavior and follows RFC 7231 recommendations.
Dependencies

v3.0.1

Compare Source

v3.0.0

Compare Source

v2.0.1

Compare Source

v2.0.0

Compare Source


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate

renovate Bot commented Apr 22, 2026

Copy link
Copy Markdown
Contributor Author

⚠️ Artifact update problem

Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.

♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

  • any of the package files in this branch needs updating, or
  • the branch becomes conflicted, or
  • you click the rebase/retry checkbox if found above, or
  • you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:

File name: mix.lock
Command failed: install-tool elixir 1.20.1

@renovate renovate Bot force-pushed the renovate/hackney-4.x branch 4 times, most recently from 15aed93 to f03129c Compare April 24, 2026 04:48
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch from f03129c to 67dc392 Compare May 5, 2026 23:41
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch from 67dc392 to faa0df6 Compare May 18, 2026 12:31
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch 2 times, most recently from 8e49308 to b6ac5fd Compare May 28, 2026 10:45
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch 4 times, most recently from 9b76696 to 6b5e1b7 Compare June 7, 2026 10:15
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch 3 times, most recently from 3ef01a5 to aa9234b Compare June 13, 2026 17:29
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch from aa9234b to f17f6a6 Compare June 18, 2026 19:06
@renovate renovate Bot force-pushed the renovate/hackney-4.x branch from f17f6a6 to a579499 Compare June 22, 2026 19:03
@brianmay

Copy link
Copy Markdown
Owner

@copilot What is going wrong here? It appears renovate cannot install Elixir 1.20.1 for some reason, and as a result is not updaating the lock file.

Copilot AI commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

@copilot What is going wrong here? It appears renovate cannot install Elixir 1.20.1 for some reason, and as a result is not updaating the lock file.

It doesn’t look like Elixir installation is the main blocker here. The branch only changed mix.exs, and the failing Nix job shows Hex resolution fails before a new lock can be written:

oauth2_metadata_updater 1.2.2 -> hackney ~> 1.0
lock -> hackney ~> 1.0
app -> hackney ~> 4.0

So Renovate is trying to bump hackney to ~> 4.0, but the current dependency graph is still pinned to hackney ~> 1.0, which makes the update unsatisfiable and leaves mix.lock unchanged. The renovate.json Elixir constraint (1.20.1) may be a separate config mismatch, since repo CI is still on 1.20.0-rc.6, but the concrete failure I could verify on this PR is the dependency solver conflict, not Elixir provisioning.

Copilot AI requested a review from brianmay June 23, 2026 21:21
@renovate renovate Bot changed the title chore(deps): update dependency hackney to v4 chore(deps): update dependency hackney to v4 - autoclosed Jul 1, 2026
@renovate renovate Bot closed this Jul 1, 2026
@renovate renovate Bot deleted the renovate/hackney-4.x branch July 1, 2026 22:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants