# PostgreSQL 19 ships two months late after a flood of AI-reported vulnerabilities

> Simon Willison's favorite feature is WAIT FOR LSN, which lets apps read their own writes from a replica.

- URL: https://devisdead.ai/news/postgresql-19-ships-two-months-late-after-a-flood-of-ai-reported-vulnerabilities
- Published: 2026-11-20T00:34:50Z
- Author: DevIsDead Newsroom
- Section: Dev
- Tags: postgresql, databases, security, open source
- Originally reported by Simon Willison's Weblog (https://simonwillison.net/2026/Nov/19/postgresql-19/).

PostgreSQL 19 is out, about two months later than the usual September release, mainly because the team had to deal with a flurry of issues from what Simon Willison calls the "ongoing AI-reported vulnerability apocalypse," he writes on [his blog](https://simonwillison.net/2026/Nov/19/postgresql-19/).

## The feature he likes

For apps that send reads to standby replicas, PostgreSQL 19 adds "read-your-writes" consistency through a new WAIT FOR LSN command. After writing on the primary, the app grabs the current WAL position with `pg_current_wal_insert_lsn()` and stores it, for example in a signed cookie. On the next request, a session on a standby runs `WAIT FOR LSN '...'` before querying, so it doesn't read until the replica has replayed that write. An optional timeout throws an error if the replica doesn't catch up in time.

Willison first saw the pattern in Wikipedia's MediaWiki, which hand-rolled a version on MySQL replication by storing the primary's binlog position in the session and waiting for replicas to reach it.

**[Scoreboard](/scoreboard) update:** Draw. AI found the bugs, and human maintainers shipped the fixes, late.

Stay undead.
