Revision history for pg_integrity_checksums CLI 0.7.0 2026-11-17 - Feature: the CLI warns on stderr when it connects to a remote host without verifying the server certificate (sslmode other than verify-ca or verify-full). Unix sockets, localhost and loopback addresses are exempt; PGICS_NO_SSL_WARNING=1 silences the warning. Connection behavior is unchanged. - Feature: logical baselines include sequences (kind "sequence"), checksummed with pg_sequence_logical_checksum(): definition plus last_value/is_called, so verify after a migration reports a sequence that was not carried over with its table. A definition change is schema_changed. A sequence owned by a column (serial, identity, OWNED BY) records its table, and --table/--exclude-table follow that table; other sequences match by name. New --no-sequences flag and include_sequences profile key; the scope records include_sequences. Baselines without that field (all earlier ones) are verified and updated without sequences. Physical baselines never contain sequences. Needs extension 2.9.0; with an older extension capture warns and leaves sequences out unless they were requested explicitly. Older CLI versions cannot read baselines that contain sequences. - Feature: capture --hash accepts crc32c and xxh3, which write v2 baselines (also as the hash of a config profile); verify and update use the baseline's algorithm as before. Needs extension 2.9.0 or later: capture fails before the scan on an older extension. The v2 baseline schema lists the new values. Older CLI releases reject such baselines. - Feature: new compare command compares the tables of two live databases (--source and --target) row by row and reports each missing, extra and changed row by key, without copying table data to the client. It compares pg_table_bucket_checksums() per bucket of the key hash and fetches pg_table_row_checksums() only for the buckets that differ. The key is the primary key, the whole row for tables without one, or set per table with --key schema.table=col1,col2. Tables only on one side, with different columns, or that fail are reported too. Supports the capture scope filters, --buckets, --max-rows, --workers, --timeout, --format text|json, --output, --show-ok and --no-fail. Needs extension 2.8.0 or later on both servers. 0.6.0 2026-11-17 - Feature: update accepts --allow-version-mismatch, so a baseline can be refreshed with its scope kept after a PostgreSQL major upgrade. - Fix: the --format error message now lists junit. - Fix: with --output, verify, update, diff, show and doctor truncated an existing report (or left an empty new one) when the command failed before producing output, for example on an invalid baseline or a connection error. The report is now only replaced once there is output. - Docs: --changed-since can reuse a stale checksum for a change committed just before the run (statistics are published with a delay). - Dependencies: github.com/jackc/pgx/v5 5.13.0. - Fix: the CLI failed with "function pg_table_logical_checksum(regclass) does not exist" when the (relocatable) extension was installed in a schema outside search_path. The extension's schema is now read from pg_extension and used to qualify the function calls. - Fix: schema_changed was reported after a dump/restore of a table with a dropped column, because attnum (which counts dropped columns) went into schema_hash. Columns are now numbered by position among live columns. Baselines record schema_hash_version 3; older hashes are not comparable, so re-capture baselines (update --yes). - Fix: an object that was checksummed in the baseline but is skipped now (for example an index that became invalid) is reported as changed instead of skipped, so verify no longer exits 0 for it. 0.5.0 2026-11-15 - verify and update check that the baseline matches the server (PostgreSQL major version, and for physical baselines the cluster and database) before checksumming anything, instead of after scanning the whole database. The exit code (3) is unchanged. - Saving a baseline fsyncs the directory after the rename, so a crash right after a successful save cannot bring back the old file. - Fix: schema_hash changed after a dump/restore, so verify reported schema_changed for a correctly restored database. Constraints were hashed in OID order, which a restore does not reproduce; they are now ordered by name. The hash also depended on the connection's search_path and quote_all_identifiers, which change how format_type(), pg_get_expr() and pg_get_constraintdef() spell names; they are now pinned to pg_catalog and off while the hashes are computed. Baselines record schema_hash_version 2. Hashes of older baselines are not comparable: verify and diff compare data only and print a warning until the baseline is re-captured (update --yes). - Fix: verify --changed-since could reuse a stale checksum forever. The table statistics were read inside the snapshot transaction, after its snapshot, so a change committed in between was counted but not checksummed, and later runs saw unchanged counters. The statistics are now read before the snapshot is taken: a change in between only forces a recomputation on the next run. - verify --changed-since is ignored on a standby, with a warning, and every object is checksummed. WAL replay does not update the table statistics the shortcut relies on. They are normally zero on a standby, which already forced full checksums, but a standby with non-zero counters (for example cloned from a cleanly stopped primary) could reuse a stale checksum for a changed table. 0.4.0 2026-11-09 - Add capture --hash fnv64 and the v2 baseline format with an explicit checksum algorithm. - Keep fnv32/v1 as the default and continue reading v1 baselines. - Verify and update inherit the hash algorithm from the baseline. - Reject diff comparisons between baselines that use different hashes. 0.3.1 2026-11-09 - Publish the 0.3.0 init and config commands after the failed 0.3.0 release tag. - Fix the cosign bundle format used by the release workflow. 0.3.0 2026-11-08 - Add init to generate a .pgics.yaml with a default profile. - Add config validate and config show with DSN masking. 0.2.0 2026-11-07 - Add .pgics.yaml profiles with environment-referenced DSNs and config-relative baseline/output paths. - Add shell-style glob filters for schemas and tables. - Add --dsn, --connect-timeout and --application-name. - Add --output and JUnit output for verify, diff and update. - Add doctor preflight checks for SELECT privileges and RLS. - Add --fail-on schema-changed. - Write gzip baselines automatically for .gz output paths. - Add shell completion generation for bash, zsh, fish and PowerShell. - Add a standalone CLI Docker image and a composite GitHub Action. 0.1.0 2026-11-07 - First standalone release of the Go CLI. - Add capture, verify, diff, show, update and doctor commands. - Add versioned JSON baseline format v1 and its JSON Schema. - Use one repeatable-read read-only transaction for consistent snapshots. - Support logical and physical checksums, schema filters and CI exit codes. - Add schema signatures and report schema changes separately from data changes. - Add --changed-since for logical verification using table statistics as a documented heuristic. - Add gzip baseline reading and atomic baseline writes. - Add integration coverage for PostgreSQL 12 through 19. - Release independently from the extension with cli-v* tags.