Angaben zum Datum
Datum aus der Quelle.
Erstmals gesehen am .
Asyncpg von MagicStack
Asyncpg 0.32.0: Python 3.15, PostgreSQL 19 und neuer Pool-Parameter
Asyncpg 0.32.0 unterstützt Python 3.15 und PostgreSQL 19, macht pool min_size zu einer dauerhaft gehaltenen Mindestanzahl an Verbindungen (neuer Parameter init_size steuert die Startverbindungen), beschleunigt die SCRAM-Passwortableitung und behebt u. a. einen Pool-Deadlock nach Protokollabbruch sowie die Beachtung von Connection.close(timeout=...).
Improvements
Support Python 3.15 (#1367, #1378) (by @elprans in 1b118464 and 58c0c595)
Support PostgreSQL 19 (#1379) (by @elprans in 8d2a5aed)
Make pool
min_sizea maintained connection floor and addinit_sizeto control the number of connections opened at startup (#1323). Idle connections at or belowmin_sizeare retained, and closed connections are replaced in the background.init_sizedefaults tomin_size. To preserve the previous behavior, where the pool could drain to zero, replacemin_size=Nwithinit_size=N, min_size=0. (by @shatilov-diman in 67a1cbc5)Use
hashlib.pbkdf2_hmac()for faster SCRAM password derivation (#1359) (by @twelfthlabor in 00319a9b)Use the statement cache for
copy_records_to_table()introspection (#1360) (by @matemax in dd058652)
Fixes
Clean up connections rejected by
target_session_attrsimmediately so an unresponsive rejected host cannot delay the selected connection, and cleanup tasks cannot outlive the event loop. Rejected connections are aborted without waiting for a graceful disconnect; servers may log "unexpected EOF on client connection" if the Terminate message is not delivered before the transport closes.Fix a connection pool deadlock when releasing a connection after a protocol abort (#1324) (by @pchaseh in 4a83cc2f)
Honor
Connection.close(timeout=...)while waiting for a pending cancellation (#1361) (by @gyanu2507 in c06bcb4d) …