From: cosgroveb (@cosgroveb) <noreply+cosgroveb@github.com>
To: pgbouncer/pgbouncer <noreply+pgbouncer-pgbouncer@github.com>
Subject: Re: [pgbouncer/pgbouncer] issue #1706: `DISCARD ALL` reset pipelined with the next Parse wipes the client's prepared statement map
Date: Sat, 14 Nov 2026 04:29:23 +0000
Message-ID: <gh-pgbouncer-pgbouncer-1706-c6871717842@github.com> (raw)
In-Reply-To: <gh-pgbouncer-pgbouncer-1706@github.com>
References: <gh-pgbouncer-pgbouncer-1706@github.com>
Hi @vadv. Your issue description says:
> Client 1 prepares statement s1 and executes it. Client 1 disconnects
But the reproducer you've provided doesn't execute it. I find libpq naming a bit function naming confusing at times but in here:
```
pg.enter_pipeline_mode()
pg.send_prepare(b"s1", b"SELECT 1")
pg.send_query_prepared(b"s1", [])
pg.pipeline_sync()
assert pg.get_result().status == pq.ExecStatus.COMMAND_OK
assert pg.get_result() is None
```
... you would need to [call](https://github.com/pgbouncer/pgbouncer/blob/ac3bb6d748cefc9470c2c66e061549a59a072ce3/test/test_prepa...) `pg.send_prepare(...)`. After making this adjustment do you still see any issue?