Iterating generator from C

2006-06-17 Thread sven . suursoho
Does messing with signal handlers and longjmp affect Python interpreter? I'm trying to find solution for problem, described in http://groups.google.com/group/comp.lang.python/browse_thread/thread/98cbae94ca4beefb/9d4d96fd0dd9fbc3 and came up with test application. It works well but i'm not sure it

RE: Iterating generator from C (PostgreSQL's pl/python RETUN SETOF/RECORD iterator support broken on RedHat buggy libs)

2006-05-22 Thread Hannu Krosing
I try to move this to -dev as I hope there more people reading it who are competent in internal working :). So please replay to -dev only. - The question is about use of generators in embedde v2.4 with asserts enabled. Can somebody explain, why the code in try2.c works with wrappers

Re: [PATCHES] [HACKERS] Iterating generator from C (PostgreSQL's pl/python RETUN

2006-05-15 Thread Hannu Krosing
Ühel kenal päeval, E, 2006-05-15 kell 17:21, kirjutas Tom Lane: > Hannu Krosing <[EMAIL PROTECTED]> writes: > >> Sven Suursoho wrote: > >>> As for testing in actual pl/python build environment, we had objections > >>> from > >>> leading postgresql Tom Lane that even if we do test it at build time

Re: [HACKERS] Iterating generator from C (PostgreSQL's pl/python RETUN

2006-05-15 Thread Tom Lane
Hannu Krosing <[EMAIL PROTECTED]> writes: >> Sven Suursoho wrote: >>> As for testing in actual pl/python build environment, we had objections >>> from >>> leading postgresql Tom Lane that even if we do test it at build time, >>> a determined DBA may substitute a buggy python.so later and still c

RE: Iterating generator from C (PostgreSQL's pl/python RETUN SETOF/RECORD iterator support broken on RedHat buggy libs)

2006-05-15 Thread Hannu Krosing
Sorry for cross-posting, but this IS a cross-platform issue. Christian Tismer tismer at stackless.com wrote: > Sven Suursoho wrote: > > >>> Is there any way to rewrite following program to handle returned > >>> generator without hitting this bug? > > The only way I can think of getting aroun

Re: Iterating generator from C

2006-05-15 Thread Christian Tismer
Sven Suursoho wrote: >>> Is there any way to rewrite following program to handle returned >>> generator without hitting this bug? The only way I can think of getting around this is to make sure that there is always a running python frame. This would be possible if you can control how the exten

Re: Iterating generator from C

2006-05-15 Thread Sven Suursoho
Mon, 15 May 2006 16:53:12 +0300, Christian Tismer <[EMAIL PROTECTED]>: >> I am working on project that has embedded python interpreter to run >> user-specified python procedures. Those procedures might return any >> iterable object with set of result data -- basically everything for >> w

Re: Iterating generator from C

2006-05-15 Thread Christian Tismer
Sven Suursoho wrote: > Hi, > > > I am working on project that has embedded python interpreter to run > user-specified python procedures. Those procedures might return any > iterable object with set of result data -- basically everything for which > iter() returns valid object (list, tuple,

Iterating generator from C

2006-05-13 Thread Sven Suursoho
Hi, I am working on project that has embedded python interpreter to run user-specified python procedures. Those procedures might return any iterable object with set of result data -- basically everything for which iter() returns valid object (list, tuple, dict, iterator etc) It works ok, e