Re: [HACKERS] Weird PL/Python elog output

2009-10-31 Thread Marko Kreen
On 10/31/09, Peter Eisentraut wrote: > On fre, 2009-10-30 at 17:13 +0200, Marko Kreen wrote: > > I vote for handling tuple with 1 element better, otherwise keep old > > behaviour. > > > > I don't think breaking multi-arg calls is good idea, as they may be used > > only in special situations.

Re: [HACKERS] Weird PL/Python elog output

2009-10-31 Thread Peter Eisentraut
On fre, 2009-10-30 at 17:13 +0200, Marko Kreen wrote: > On 10/30/09, Peter Eisentraut wrote: > > Calling PL/Python's elog functions exposes some curious behavior. For > > example, calling plpy.error('foo') prints > > > > ERROR: ('foo',) > > > > (instead of the > > > > ERROR: foo > > > > th

Re: [HACKERS] Weird PL/Python elog output

2009-10-30 Thread Marko Kreen
On 10/30/09, Peter Eisentraut wrote: > Calling PL/Python's elog functions exposes some curious behavior. For > example, calling plpy.error('foo') prints > > ERROR: ('foo',) > > (instead of the > > ERROR: foo > > that one might have hoped for.) This is an implementation artifact, > becaus

[HACKERS] Weird PL/Python elog output

2009-10-30 Thread Peter Eisentraut
Calling PL/Python's elog functions exposes some curious behavior. For example, calling plpy.error('foo') prints ERROR: ('foo',) (instead of the ERROR: foo that one might have hoped for.) This is an implementation artifact, because those functions don't check their arguments, just take them