Re: plpython: Remove support for major version conflict detection

From: Mario González Troncoso <gonzalemario(at)gmail(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: plpython: Remove support for major version conflict detection
Date: 2025-10-08 15:28:45
Message-ID: CAFsReFWue=MozOj+8o6diOoxvqaxm4wUrHEXxBo1g_4zy4kE+A@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I'm attaching the same patch after rebasing from master. I had to just
change this in src/pl/plpython/plpy_main.c

- static bool PLy_procedure_is_trigger(Form_pg_proc procStruct);
+ static PLyTrigType PLy_procedure_is_trigger(Form_pg_proc procStruct);

Now the function returns PLyTrigType instead of a bool.

lgtm

On Wed, 8 Oct 2025 at 12:19, Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:
>
> This essentially reverts commit 866566a690b, which installed safeguards
> against loading plpython2 and plpython3 into the same process. We don't
> support plpython2 anymore, so this is obsolete.
>
> The Python and PL/Python initialization now happens again in _PG_init()
> rather than the first time a PL/Python call handler is invoked. (Often,
> these will be very close together.)
>
> I kept the separate PLy_initialize() function introduced by 866566a690b
> to keep _PG_init() a bit modular.
>
> (I'm looking at the some further work to allow multiple interpreters in
> PL/Python, so I'm trying to clean up the initialization code a bit first.)

--
https://www.linkedin.com/in/gonzalemario

Attachment Content-Type Size
0001-plpython-Remove-support-for-major-version-conflict-d.patch text/x-patch 5.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabrice Chapuis 2025-10-08 15:35:06 Re: issue with synchronized_standby_slots
Previous Message Robert Haas 2025-10-08 15:20:28 Re: Should we update the random_page_cost default value?