[Python-Dev] Preventing recursion core dumps

Just van Rossum just@letterror.com
Fri, 11 Aug 2000 16:14:40 +0100


> > Agreement on 5000?
>
> No, the __getattr__ example still dumps core for me.  With 4000 it is
> fine, but this indicates that this is totally the wrong approach: I
> can change the available stack size with ulimit -s and cause a core
> dump anyway.  Or there could be a loger path through the C code where
> more C stack is used per recursion.
>
> We could set the maximum to 1000 and assume a "reasonable" stack size,
> but that doesn't make me feel comfortable either.
>
> It would be good if there was a way to sense the remaining available
> stack, even if it wasn't portable.  Any Linux experts out there?

Gordon, how's that Stackless PEP coming along?

Sorry, I couldn't resist ;-)

Just