| From: | Michael Paquier <michael(at)paquier(dot)xyz> |
|---|---|
| To: | Jiho Lee <jiho99322(at)gmail(dot)com> |
| Cc: | Rucha Kulkarni <rirukool(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: Backend goes in infinite loop when a GUC_REPORT value can’t be converted to client_encoding |
| Date: | 2026-12-03 07:08:47 |
| Message-ID: | axEVf6dBRA54UdIH@paquier.xyz |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, Dec 03, 2026 at 02:52:55PM +0900, Jiho Lee wrote:
> I agree that filtering on the errcode is fragile, and a soft
> conversion would also avoid the PG_TRY block. One thing to consider
> with a placeholder such as "???": if last_reported then holds the
> real value, switching client_encoding back to UTF8 won't resend it,
> since only variables flagged GUC_NEEDS_REPORT are reported. The client
> would keep the placeholder until the variable changes again. From
> reading the code, v1 leaves the client with the same stale value.
> Re-flagging such variables when client_encoding changes might be
> worth it, but I haven't tested that.
>
> For v1 itself: it builds without warnings, and test_misc (including
> the new 017 test) and regress pass.
Err. FWIW, I'd recommend that you do not post purely AI-generated
messages that just summarize the situation and explain how the patch
looks kind of fine (or I just did not understand what you have sent).
That does not help in moving the discussion forward: v1 is incorrect,
needs fixing, that's not going to change, so let's just fix the patch.
--
Michael
| From | Date | Subject | |
|---|---|---|---|
| Previous Message | Michael Paquier | 2026-12-03 07:05:23 | Re: GetNewOidWithIndex() can reuse a TOAST value ID while its chunks are still in the heap |