Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Tom Lane
Joe Conway writes: > On 4/11/21 12:51 PM, Dave Cramer wrote: >> On Sun, 11 Apr 2021 at 12:43, Tom Lane > > wrote: >>> Concretely, maybe like the attached? >> +1 from me. >> I especially like the changes to the comments as it's more apparent what >> they >> should be u

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Joe Conway
On 4/11/21 12:51 PM, Dave Cramer wrote: On Sun, 11 Apr 2021 at 12:43, Tom Lane > wrote: I wrote: > Joe Conway mailto:m...@joeconway.com>> writes: >> Would an equivalent "PGWARNING" be something we are open to adding and >> back-patching? > I

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Dave Cramer
On Sun, 11 Apr 2021 at 12:43, Tom Lane wrote: > I wrote: > > Joe Conway writes: > >> Would an equivalent "PGWARNING" be something we are open to adding and > >> back-patching? > > > It's not real obvious how pl/r could solve this in a reliable way > > otherwise, so adding that would be OK with m

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Tom Lane
I wrote: > Joe Conway writes: >> Would an equivalent "PGWARNING" be something we are open to adding and >> back-patching? > It's not real obvious how pl/r could solve this in a reliable way > otherwise, so adding that would be OK with me, but I wonder whether > back-patching is going to help you

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Tom Lane
Joe Conway writes: > On 4/11/21 10:13 AM, Tom Lane wrote: >> Indeed. elog.h already provides a "PGERROR" macro to use for restoring >> the value of ERROR. We have not heard of a need to do anything special >> for WARNING though --- maybe that's R-specific? > R also defines WARNING in its header

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Joe Conway
On 4/11/21 10:13 AM, Tom Lane wrote: Andrew Dunstan writes: Well, plr.h does this: #define WARNING 19 #define ERROR 20 The coding pattern in plr.h looks quite breakable. Meh -- that code has gone 18+ years before breaking. Indeed. elog.h already provides a "PGERROR" m

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Tom Lane
Andrew Dunstan writes: >> Well, plr.h does this: >> >> #define WARNING 19 >> #define ERROR20 > The coding pattern in plr.h looks quite breakable. Instead of hard > coding values like this they should save the value from the postgres > headers in another variable befo

Re: PL/R regression on windows, but not linux with master.

2021-04-11 Thread Andrew Dunstan
On 4/10/21 8:56 PM, Tomas Vondra wrote: > On 4/11/21 2:38 AM, Dave Cramer wrote: >> >> >> >> On Sat, 10 Apr 2021 at 20:34, Tom Lane > > wrote: >> >> Dave Cramer mailto:davecra...@gmail.com>> writes: >> > On Sat, 10 Apr 2021 at 20:24, Tom Lane >

Re: PL/R regression on windows, but not linux with master.

2021-04-10 Thread Dave Cramer
On Sat, 10 Apr 2021 at 20:56, Tomas Vondra wrote: > On 4/11/21 2:38 AM, Dave Cramer wrote: > > > > > > > > > > On Sat, 10 Apr 2021 at 20:34, Tom Lane > > wrote: > > > > Dave Cramer mailto:davecra...@gmail.com>> > writes: > > > On Sat, 10 Apr 2021 at 20:24, Tom

Re: PL/R regression on windows, but not linux with master.

2021-04-10 Thread Tomas Vondra
On 4/11/21 2:38 AM, Dave Cramer wrote: > > > > > On Sat, 10 Apr 2021 at 20:34, Tom Lane > wrote: > > Dave Cramer mailto:davecra...@gmail.com>> writes: > > On Sat, 10 Apr 2021 at 20:24, Tom Lane > wrote: > >> That's quite b

Re: PL/R regression on windows, but not linux with master.

2021-04-10 Thread Dave Cramer
On Sat, 10 Apr 2021 at 20:34, Tom Lane wrote: > Dave Cramer writes: > > On Sat, 10 Apr 2021 at 20:24, Tom Lane wrote: > >> That's quite bizarre. What is the actual error level according to > >> the source code, and where is the error being thrown exactly? > > > Well it really is an ERROR, and

Re: PL/R regression on windows, but not linux with master.

2021-04-10 Thread Tom Lane
Dave Cramer writes: > On Sat, 10 Apr 2021 at 20:24, Tom Lane wrote: >> That's quite bizarre. What is the actual error level according to >> the source code, and where is the error being thrown exactly? > Well it really is an ERROR, and is being downgraded on windows to WARNING. That seems quit

Re: PL/R regression on windows, but not linux with master.

2021-04-10 Thread Dave Cramer
On Sat, 10 Apr 2021 at 20:24, Tom Lane wrote: > Dave Cramer writes: > > One of our tests purposely throws an error which returns > > "ERROR: R interpreter parse error" on linux > > and > > "WARNING: R interpreter parse error" on windows. > > That's quite bizarre. What is the actual error leve

Re: PL/R regression on windows, but not linux with master.

2021-04-10 Thread Tom Lane
Dave Cramer writes: > One of our tests purposely throws an error which returns > "ERROR: R interpreter parse error" on linux > and > "WARNING: R interpreter parse error" on windows. That's quite bizarre. What is the actual error level according to the source code, and where is the error being