Skip to content
CAI
Software that uses CAICheck a score

wg/epgsql

58.0

Adequate · 23 September 2026

1.3k

lines of production code

Erlang

primary language

5

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is an Erlang PostgreSQL client library that provides robust database connectivity with support for asynchronous notifications, SSL encryption, and configurable timeouts. It handles a wide range of PostgreSQL data types, including complex temporal and array structures, while ensuring reliable error handling and protocol compliance. The codebase includes comprehensive test coverage for security features like client certificate authentication and various SQL operations.

Features

Add support for PostgreSQL date/time types and array types

The epgsql library now supports encoding and decoding of PostgreSQL date, time, timestamp, and interval types using both binary and integer formats, enabling accurate handling of temporal data. Additionally, the library adds support for various array types including booleans, integers (2, 4, 8-bit), floats (4, 8-bit), characters, and text, allowing users to work with multi-dimensional and single-dimensional arrays directly. The connection handling has been updated to use a dedicated socket module that supports SSL encryption and asynchronous notifications, while the application structure has been modernized to generate the version number from git tags.

src · high confidence

Behavioural changes

Enhanced PostgreSQL client with async notifications, SSL, and timeout support

The epgsql client now supports asynchronous notice and notification messages, allowing users to receive server-side warnings and LISTEN/NOTIFY events via a specified process. It also adds configurable connection and query timeouts, SSL session encryption, and improved error handling that requires calling pgsql:sync after errors. The README is updated to document these new features, including the async message formats and error tuples.

(repo-wide) · high confidence

The ebin/epgsql.app file is no longer a symlink to the source directory; it is now generated at compile time. This change ensures the application metadata is correctly placed in the build output directory rather than pointing back to the source tree.

ebin · high confidence

Test coverage

Added SSL/TLS test certificates and updated test schema for SSL and multibyte character support; Expanded PostgreSQL protocol and SQL feature coverage in tests.

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

How this codebase got here

Score

  • CAI 42 → 58 (+16.4)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 93 → 97 (+4.7)
  • Architecture 69 → 69 (+0.0)
  • Maturity 27 → 56 (+28.7)
  • Readiness 24 → 43 (+18.9)
  • Security 100 → 100 (+0.0)
  • Event Sourcing 100 → 100 (+0.0)

Resolved (8)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • No exposed public API
  • Test reliability not included
  • The single README describes the project as a collection of tools without stating how to install dependencies or run any example. (README)
  • complexity unreadable for .erl, .hrl — churn × complexity hotspots could not be measured
  • early-stage repository — too little history to judge knowledge freshness
  • single-maintainer — knowledge-concentration (bus factor) risk

New (5)

  • Coverage not measured — no coverage collector is wired up
  • Duplicated block (13 lines × 2) (src/pgsql_fdatetime.erl)
  • Duplicated block (17 lines × 2) (src/pgsql_fdatetime.erl)
  • Duplicated block (7 lines × 2) (src/pgsql_connection.erl)
  • Hotspot: src/pgsql_binary.erl (src/pgsql_binary.erl)

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

Survey your own repository

wg/epgsql 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 23 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 3318bd5d646cad0623ae9dcc6df015bb85258a63 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-955b9cee9818.