Re: can't load plpython - Mailing list pgsql-hackers

From Tom Lane
Subject Re: can't load plpython
Date
Msg-id 29215.1238468640@sss.pgh.pa.us
Whole thread Raw
In response to can't load plpython  (Alvaro Herrera <alvherre@commandprompt.com>)
Responses Re: can't load plpython  (Alvaro Herrera <alvherre@commandprompt.com>)
Re: can't load plpython  (Euler Taveira de Oliveira <euler@timbira.com>)
List pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:
> ... However, on HEAD this is crashing for me, and it's right when plpython
> loads.  Backtrace below.

Does plpython pass its regression tests for you (I'd suppose not)?

For me on Fedora 10 x86_64, CVS HEAD plus python 2.5.2 passes regression
but the given example still dumps core.  postmaster log says

postgres: tgl regression [local] SELECT: Objects/stringobject.c:107: PyString_FromString: Assertion `str != ((void
*)0)'failed.
 
LOG:  server process (PID 4714) was terminated by signal 6: Aborted
LOG:  terminating any other active server processes

backtrace

#0  0x0000003e1d032f05 in raise () from /lib64/libc.so.6
#1  0x0000003e1d034a73 in abort () from /lib64/libc.so.6
#2  0x0000003e1d02bef9 in __assert_fail () from /lib64/libc.so.6
#3  0x0000003e3367e67c in PyString_FromString ()  from /usr/lib64/libpython2.5.so.1.0
#4  0x0000003e3366ec26 in PyDict_SetItemString ()  from /usr/lib64/libpython2.5.so.1.0
#5  0x0000000000b2149d in PLy_function_build_args (fcinfo=0x7fffff0adb80,    proc=0x2685c80) at plpython.c:1055
#6  0x0000000000b2281e in PLy_function_handler (fcinfo=0x7fffff0adb80,    proc=0x2685c80) at plpython.c:795
#7  0x0000000000b230f6 in plpython_call_handler (fcinfo=0x7fffff0adb80)   at plpython.c:356
#8  0x000000000056009a in ExecMakeFunctionResult (fcache=0x267c0f0,    econtext=0x267bfc0, isNull=0x267cb38 "",
isDone=0x267cbf0)  at execQual.c:1665
 
#9  0x000000000055af44 in ExecTargetList () at execQual.c:5001
#10 ExecProject (projInfo=<value optimized out>, isDone=0x7fffff0ae06c)   at execQual.c:5202
#11 0x000000000056f289 in ExecResult (node=0x267bea8) at nodeResult.c:155
#12 0x000000000055a27d in ExecProcNode (node=0x267bea8) at execProcnode.c:344
#13 0x0000000000557cca in ExecutePlan () at execMain.c:1504

> Obviously I don't know Python to fix it :-)

Me either.  Something is pretty bad in python-land, it seems.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Solaris getopt_long and PostgreSQL
Next
From: Tom Lane
Date:
Subject: Re: [GENERAL] string_to_array with empty input