Skip to content
CAI
Software that uses CAICheck a score

ninenines/gun

63.6

Adequate · 13 November 2026

20.3k

lines of production code

Erlang

primary language

7

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

Features

Introduction of built-in HTTP/3 support and protocol abstraction layer

Gun now includes initial support for the HTTP/3 protocol via the new gun\_http3 module, allowing users to connect using HTTP/3 in addition to HTTP/1.1, HTTP/2, and WebSockets. This change introduces a unified protocol abstraction, evidenced by the new gun\_conns\_sup supervisor and gun\_content\_handler module, which standardizes how different protocols handle data and events. The update also adds a comprehensive event system (gun\_event) with granular lifecycle callbacks such as domain\_lookup, tls\_handshake, and push\_promise events, enabling better observability and control over connection states across all supported protocols.

src · high confidence

Behavioural changes

Gun 2.0 manual restructured and updated with new API features

The documentation has been completely revamped to follow a one-page-per-function structure, covering all connection, request, stream, and WebSocket management functions. This release introduces several new capabilities: user-initiated HTTP/2 pings via gun:ping/2,3, explicit stream information retrieval with gun:stream\_info/2, and the ability to change the connection owner using gun:set\_owner/2. The manual also documents the removal of implicit body detection in request functions (requiring explicit body or separate gun:data/3 calls), the addition of a gun:shutdown/1 function for graceful connection closure, and the requirement of a StreamRef argument for gun:ws\_send/3. Furthermore, it details new HTTP/1.1 options for flow control, header transformation, and block size limits, as well as SOCKS5 proxy support and WebSocket subprotocol negotiation.

doc/src/manual · high confidence

Gun 2.6.0 release with HTTP/3 support and build system overhaul

This release updates Gun to version 2.6.0, introducing an initial HTTP/3 implementation (conditionally enabled via the GUN\_QUICER flag) and adding a TLS-over-TLS transport (gun\_tls\_proxy). The project has removed its dependency on Ranch, now requiring only Cowlib 2.20.0, and mandates Erlang/OTP 27 or later. The build system has been significantly restructured to use erlang.mk with a generated rebar.config, and the documentation format has switched from Markdown to Asciidoc.

(repo-wide) · high confidence

Gun User Guide restructured and updated for version 2.6

The documentation has been reorganized into a structured book format with dedicated chapters for Introduction, Connection, HTTP, Websocket, and Advanced topics, alongside a comprehensive set of migration guides covering versions 1.0 through 2.5. The guide now reflects the requirements for Erlang/OTP 27.0+, documents the new \gun:await\_up/1,2,3\ functions for synchronous connection handling, and includes detailed explanations of the internal TLS-over-TLS implementation via \gun\_tls\_proxy\ and \gun\_tunnel\. It also covers new features such as the \reply\_to\ option for Websocket upgrades, automatic header lowercasing, and security improvements in Cowlib 2.20.0.

doc/src/guide · high confidence

Test coverage

Added test handler modules for WebSocket, SSE, and cookie scenarios; Initial test suite for Gun HTTP client.

Dependencies

Gun HTTP client updated to version 2.6.0

The Gun application metadata has been updated to version 2.6.0, reflecting the latest release of the HTTP/1.1, HTTP/2, and WebSocket client for Erlang/OTP. This update ensures the application manifest correctly identifies the current version and lists all associated modules, including support for HTTP/3, Socks5, TLS proxying, and WebSocket protocols.

ebin · high confidence

Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 65 → 64 (-1.3)
  • Rubric changed (rubric-2026.10.5 → rubric-2026.11.3) — scores are not directly comparable.

Lenses

  • Code Health 70 → 70 (+0.0)
  • Architecture 100 → 100 (+0.0)
  • Maturity 52 → 52 (+0.3)
  • Readiness 70 → 64 (-6.0)
  • Security 100 → 100 (+0.0)

Resolved (2)

  • Hotspot: src/gun.erl (src/gun.erl)
  • Hotspot: src/gun_ws.erl (src/gun_ws.erl)

New (21)

  • Edited copies of one member (3 members, 11+ corresponding lines) (src/gun_http2.erl)
  • Edited copies of one member (4 members, 11+ corresponding lines) (src/gun.erl)
  • Edited copies of one member (4 members, 13+ corresponding lines) (src/gun_http2.erl)
  • Edited copies of one member (4 members, 9+ corresponding lines) (src/gun_tunnel.erl)
  • Edited copy of a member (10 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (10 corresponding lines) (src/gun_tls_proxy.erl)
  • Edited copy of a member (12 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (13 corresponding lines) (src/gun_tls_proxy.erl)
  • Edited copy of a member (15 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (20 corresponding lines) (src/gun_http.erl)
  • Edited copy of a member (25 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (26 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (31 corresponding lines) (src/gun_http.erl)
  • Edited copy of a member (31 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (4 corresponding lines) (src/gun_http.erl)
  • Edited copy of a member (4 corresponding lines) (src/gun_http.erl)
  • Edited copy of a member (45 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (5 corresponding lines) (src/gun_http.erl)
  • Edited copy of a member (6 corresponding lines) (src/gun_http2.erl)
  • Edited copy of a member (7 corresponding lines) (src/gun_tunnel.erl)
  • …and 1 more

Changes since last survey

  • 7 commits — 4 feature/other, 3 fixes

By area

  • doc/src — 5 commits
  • (root) — 1 commit
  • src/gun_http2.erl — 1 commit

Notable commits

  • fix: Fix AsciiDoc source language for Makefile snippets
  • fix: Fix HTTP/2 header table size types
  • fix: Fix HTTP/2 max_concurrent_streams type
  • change: Add the max_header_list_size HTTP/2 option
  • change: Fix typos and grammar errors in documentation
  • change: Gun 2.8.0
  • change: Update the HTTP/2 window after a reset stream's DATA

Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

ninenines/gun was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 13 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 8ea2a6d157ce3c58db6d0d804c6457f559c6d202 — the exact code this score is about.
  • Scored under rubric-2026.11.3 — the same rubric and the same method as every other entry in this index.
  • Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.57+preprod-8ebfb01cf4c0.