BUG #15598: PostgreSQL Error Code is not reported when connectionterminated due to idle-in-transaction timeout - Mailing list pgsql-bugs

From PG Bug reporting form
Subject BUG #15598: PostgreSQL Error Code is not reported when connectionterminated due to idle-in-transaction timeout
Date
Msg-id 15598-e3fec9d8c5184936@postgresql.org
Whole thread Raw
Responses Re: BUG #15598: PostgreSQL Error Code is not reported when connection terminated due to idle-in-transaction timeout
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      15598
Logged by:          Marcin Barczyński
Email address:      mba.ogolny@gmail.com
PostgreSQL version: 9.6.8
Operating system:   Windows 10
Description:

Here is the output on Ubuntu:
```
postgres=# SELECT version();
                                                               version
                                                        

-------------------------------------------------------------------------------------------------------------------------------------
 PostgreSQL 9.6.9 on x86_64-pc-linux-gnu (Ubuntu 9.6.9-2.pgdg14.04+1),
compiled by gcc (Ubuntu 4.8.4-2ubuntu1~14.04.4) 4.8.4, 64-bit
(1 row)

postgres=# SET idle_in_transaction_session_timeout=500;
SET
postgres=# BEGIN;
BEGIN
postgres=# SELECT * FROM pg_class;
FATAL:  25P03: terminating connection due to idle-in-transaction timeout
LOCATION:  ProcessInterrupts, postgres.c:2996
server closed the connection unexpectedly
    This probably means the server terminated abnormally
    before or while processing the request.
The connection to the server was lost. Attempting reset: Succeeded.
```

PostgreSQL Error Code 25P03 is reported as expected.

I downloaded PostgreSQL 9.6.11 for Windows from
https://www.openscg.com/bigsql/postgresql/installers.jsp/ (referenced at
https://www.postgresql.org/download/windows/),
and the error code is not reported:
```
postgres=# SELECT version();
                                                 version
----------------------------------------------------------------------------------------------------------
 PostgreSQL 9.6.11 on x86_64-pc-mingw64, compiled by gcc.exe (Rev5, Built by
MSYS2 project) 4.9.2, 64-bit
(1 row)


postgres=# SET idle_in_transaction_session_timeout=500;
SET
postgres=# BEGIN;
BEGIN
postgres=# SELECT * FROM pg_class;
server closed the connection unexpectedly
        This probably means the server terminated abnormally
        before or while processing the request.
The connection to the server was lost. Attempting reset: Succeeded.
```


pgsql-bugs by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: psql and readline comments
Next
From: Tom Lane
Date:
Subject: Re: BUG #15598: PostgreSQL Error Code is not reported when connection terminated due to idle-in-transaction timeout