Re: ISN extension - wrong volatility level for isn_weak() function
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Daniel Gustafsson <daniel@yesql.se>
Cc: Viktor Holmberg <v@viktorh.net>, pgsql-bugs@lists.postgresql.org
Date: 2025-03-14T14:16:24Z
Lists: pgsql-bugs
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
contrib/isn: Make weak mode a GUC setting, and fix related functions.
- 44890442398c 18.0 landed
-
Update contrib/seg for new scalarlesel/scalargesel selectivity functions.
- 44ba29206449 11.0 cited
Daniel Gustafsson <daniel@yesql.se> writes: > On 14 Mar 2025, at 12:49, Viktor Holmberg <v@viktorh.net> wrote: >> The isn_weak function in the isn extension reports the wrong value if you look at it inside a transaction: > I wonder if this should really be marked VOLATILE instead as it has a side > effect. Indeed. This whole area seems really poorly considered. The comment in isn--1.1.sql says -- isn_weak(boolean) - Sets the weak input mode. -- This function is intended for testing use only! despite which it's documented at length in isn.sgml. On the other hand, so far as I can find it's tested nowhere, which means none of the "weak mode" code is getting exercised. regards, tom lane