Re: Add errdetail() with PID and UID about source of termination signal

From: Jakub Wartak <jakub(dot)wartak(at)enterprisedb(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com>, Jim Jones <jim(dot)jones(at)uni-muenster(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Add errdetail() with PID and UID about source of termination signal
Date: 2026-02-25 08:26:28
Message-ID: CAKZiRmz6RxKoANQEJcC+K4AtBREGt5-5JcXjEotd6AsE2c2=Bw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Feb 24, 2026 at 5:15 PM Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:
>
>
> On 2026-02-24 Tu 5:05 AM, Jakub Wartak wrote:
> > On Tue, Feb 24, 2026 at 9:40 AM Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com> wrote:
> > [..]
> >
> >> There is guidance in the documentation regarding error message style: https://www.postgresql.org/docs/current/error-style-guide.html
> >> ```
> >> Detail and hint messages: Use complete sentences, and end each with a period. Capitalize the first word of sentences. Put two spaces after the period if another sentence follows (for English text; might be inappropriate in other languages).
> >> ```
> >>
> >> I also noticed that some existing DETAIL and HINT messages do not fully follow this guideline. But I believe new code should adhere to the documented style as much as possible. In particular, DETAIL and HINT messages should begin with a capital letter and follow the complete-sentence convention.
> > Hi, v2 attached, WIP, the only known remaining issue to me is that
> > windows might fail to compile as it probably doesn't have concept of
> > uid_t... I'm wondering what to do there.
>
>
> I don't think it will arise, as Windows doesn't have the siginfo stuff,
> AFAIK.
>

Hi Andrew. Ok, so V3 is attached with just one change: uid_t/pid_t
changed to uint32 to make win32 happy.

Perhaps one question is whether this should be toggleable with GUC or not.

-J.

Attachment Content-Type Size
v3-0001-Add-errdetail-with-PID-and-UID-about-source-of-te.patch text/x-patch 13.5 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ashutosh Bapat 2026-02-25 08:28:21 Re: SQL Property Graph Queries (SQL/PGQ)
Previous Message Chao Li 2026-02-25 08:22:37 Re: Skipping schema changes in publication