Skip to content

Release the pendulum downgrade - #1435

Merged
laixintao merged 1 commit into
mainfrom
j-bennet/release-4.0.1
Oct 30, 2023
Merged

laixintao merged 1 commit into
mainfrom
j-bennet/release-4.0.1

Conversation

@j-bennet

Copy link
Copy Markdown
Contributor

Release the pendulum downgrade (#1434).

@j-bennet
j-bennet requested review from a team and meeuw October 29, 2023 23:15
@laixintao
laixintao merged commit 525487c into main Oct 30, 2023
@laixintao
laixintao deleted the j-bennet/release-4.0.1 branch October 30, 2023 02:18
@dmarinuswoodwing

Copy link
Copy Markdown

Nice, thanks!

DiegoDAF added a commit to DiegoDAF/pgcli.daf that referenced this pull request Nov 26, 2026
Since psycopg 3.3.9 a second Ctrl-C during its cancel closes the connection
(psycopg dbcli#1435) instead of leaving it busy. recover_from_interrupt() saw a
closed connection and did nothing, so the query kept running on the server
until it next sent data to the client.

The cancel key libpq gives at connect time (PQgetCancel) still reaches the
backend after the connection is closed: pgcli saves it on every connect and
sends it once in that case, in a thread bounded to 2 s with Ctrl-C ignored.
Checked end to end through a link with 150 ms of latency: two Ctrl-C 0.15 s
or 0.4 s apart leave no pg_sleep running, with psycopg 3.3.8 and 3.3.9.
DiegoDAF added a commit to DiegoDAF/pgcli.daf that referenced this pull request Nov 26, 2026
Since psycopg 3.3.9 a second Ctrl-C during its cancel closes the connection
(psycopg dbcli#1435) instead of leaving it busy. recover_from_interrupt() saw a
closed connection and did nothing, so the query kept running on the server
until it next sent data to the client.

The cancel key libpq gives at connect time (PQgetCancel) still reaches the
backend after the connection is closed: pgcli saves it on every connect and
sends it once in that case, in a thread bounded to 2 s with Ctrl-C ignored.
Checked end to end through a link with 150 ms of latency: two Ctrl-C 0.15 s
or 0.4 s apart leave no pg_sleep running, with psycopg 3.3.8 and 3.3.9.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants