postgres
4.1.1 · 11 Nov 2026Unlicense38.9M / weekRepositoryHomepagenpmAtom feed
Upgrading postgres From 4.0.0 to 4.1.1
2 releases in betweenevery note read
Reading releases, release notes and advisories…
Release by release
- Fixed
A statement
sql.beginsends after its ownCOMMITorROLLBACKis rejected (#1320). A statement the callback did not await, sent between the transaction'sCOMMITorROLLBACKand the release of its connection, ran outside the transaction, and after a rollback its write was kept. It now rejects withUNSAFE_TRANSACTION, as a statement after the transaction has ended does. - Fixed
A command after a select in a multi-statement simple query has no columns (#1321). In
sql.unsafe('select …; rollback')theROLLBACKresult had the columns of theSELECTbefore it. - Fixed
A query queued behind one with an untyped string or boolean parameter resolves on Cloudflare Hyperdrive (#1319). Such a query is described first, and 4.1.0 sent its Bind, Execute and Sync together with the next query, which never resolved through Hyperdrive. On Cloudflare Workers the next query now waits until the described one is done, as in 3.4.9. Other runtimes still pipeline it.
- Fixed
.cursor()yields the rows ofSHOW,EXPLAINand other commands without a row count. Their last batch was only passed on when the command tag had a count, so a cursor over them yielded nothing.
- Fixed
- New
query_timeout(#1278). Seconds a query may take, waiting for a connection and running together, before it is canceled and rejects withQUERY_TIMEOUT. Off by default. Unlikestatement_timeoutit also ends a query whose server or network has gone silent, which TCP alone takes many minutes to notice. Transaction control queries andforEachare limited too; cursors, streams andsql.listenare not. - New
cancel_timeout, 5 seconds by default: how long a canceled query may take to end before its connection is closed. - New
sql.batch([queries])sends queries in one round trip with a single Sync: outside a transaction they commit or roll back together, and the batch rejects with the failing query's position inerror.index. - New
jsonon a transform (#1169). The built-in transforms rename the keys of JSON values in results but send JSON values as they are.json: falseleaves JSON values as they are both ways, andjson: truerenames their keys when sending too, with the transform'scolumn.to. Without it nothing changes.
- New
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.