Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to install supervisord on a ubuntu ec2 server. When running easy_install I get the following error:

> easy_install supervisor
...
RuntimeError: maximum recursion depth exceeded

I know how to change the max recursion depth in a python script using sys.setrecursionlimit() but how do I change it for the runtime environment?

share|improve this question

1 Answer 1

/usr/bin/easy_install is a python script. Can you not just add a line to set a new value after the import sys line ?

#! /usr/bin/python
# EASY-INSTALL-ENTRY-SCRIPT: 'setuptools==0.6c9','console_scripts','easy_install'
__requires__ = 'setuptools==0.6c9'
import sys
sys.setrecursionlimit(1200)
from pkg_resources import load_entry_point
sys.exit(
   load_entry_point('setuptools==0.6c9', 'console_scripts', 'easy_install')()
)
share|improve this answer
    
I tried that, up to 5000. Is there a limit to how high the limit can be safely set? –  Dave Aug 29 '11 at 1:07
    
I don't know - on the (non EC2 ) Ubuntu systems I have to hand I have to set the value as lw as 50 to see the error you get. –  Iain Aug 29 '11 at 8:11

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.