PLy_function_delete_args is modified as well to check whether the
key we intend to delete is in the globals dictionary.
New regression test is included in the patch.
--
Best regards,
Alexey Grishchenko
0001-Fix-endless-loop-in-plpython-set-returning-function.patch
Description: Binary data
--
Sent via pgsql
; dictionary. When internal function call
finishes, it removes the key "a" from the dictionary, and the outer
function fails with "NameError: global name 'a' is not defined" when it
tries to execute "return a + r"
But the second issue is a separate story and
les and global dictionary ("GD"). I will think on this, maybe there
might be a better design for this scenario. But I still think the second
scenario requires a separate patch
On Thu, Mar 10, 2016 at 4:33 PM, Tom Lane wrote:
> Alexey Grishchenko writes:
> > One scenario when t
Tom Lane wrote:
> Alexey Grishchenko > writes:
> > No, my fix handles this well.
> > In fact, with the first function call you allocate global variables
> > representing Python function input parameters, call the function and
> > receive iterator over the functio
Alexey Grishchenko wrote:
> Tom Lane wrote:
>
>> Alexey Grishchenko writes:
>> > No, my fix handles this well.
>> > In fact, with the first function call you allocate global variables
>> > representing Python function input parameters, call the func
Alexey Grishchenko wrote:
> Alexey Grishchenko wrote:
>
>> Tom Lane wrote:
>>
>>> Alexey Grishchenko writes:
>>> > No, my fix handles this well.
>>> > In fact, with the first function call you allocate global variables
>>> > repre
union all
pl_regression(# select null::int8 as a
pl_regression(# ) as q;
test
55
(1 row)
Time: 22.839 ms
--
Best regards,
Alexey Grishchenko
0001-Fix-for-PL-Python-slow-input-arrays-traversal-issue.patch
Description: Binary data
--
Sent via pgsql-ha
# SELECT * FROM test_type_conversion_array_int4(ARRAY[[1,2,3],[4,5,6]]);
INFO: ([[1, 2, 3], [4, 5, 6]], )
test_type_conversion_array_int4
-----
{{1,2,3},{4,5,6}}
(1 row)
--
Best regards,
Alexey Grishchenko
0001-PL-Python-adding-support-for-multi-dimensional-array
On Wed, Aug 3, 2016 at 12:49 PM, Alexey Grishchenko wrote:
> Hi
>
> Current implementation of PL/Python does not allow the use of
> multi-dimensional arrays, for both input and output parameters. This forces
> end users to introduce workarounds like casting arrays to text before