| From: | shihao zhong <zhong950419(at)gmail(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Subject: | Re: [PG19] Bogus errors for polymorphic plpython functions |
| Date: | 2026-10-31 03:37:25 |
| Message-ID: | CAGRkXqTg0rRHqWXHwO4Qk+4sc0k5k-dW7pswN6Cg1EKSjHwiFQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hi Tom,
Looks right to me. plpython now checks the types before looking at
check_function_bodies, like plpgsql does.
One thing. The patch rejects every pseudotype for OUT and TABLE
arguments, including record. The old code skipped OUT arguments, and
plpgsql does allow record there. Is that intended?
+ if (argmodes &&
+ (argmodes[i] == PROARGMODE_OUT ||
+ argmodes[i] == PROARGMODE_TABLE))
+ ereport(ERROR,
+ (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
+ errmsg("PL/Python functions cannot return type
%s",
Also the new tests only run with check_function_bodies on. Maybe move
to early sections before resetting the guc?
Thanks,
Shihao
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Lane | 2026-10-31 03:41:32 | Re: [PG19] Bogus errors for polymorphic plpython functions |
| Previous Message | David Shorten | 2026-10-31 03:03:35 | Standby stuck after walreceiver restart just before a WAL segment boundary |