469,571 Members | 1,591 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,571 developers. It's quick & easy.

Egg cache problem with mod_python/ez_setup

Hello there,

I have this weird problem with a mod_python application.

Recently I installed ElementTree and cElementTree through ez_setup.py,
even though they were already installed normally (this might not be too
smart, but I don't think it's related to my actual problem).

I have a web application written on top of mod_python that uses
cElementTree for several things. After installing cElementTree through
ez_setup.py, it turns out that I got this Exception on the site:

(most relevant info at the end, obviously, it's quite lengthy)

Mod_python error: "PythonHandler equilex"

Traceback (most recent call last):

File "/usr/lib/python2.4/site-packages/mod_python/apache.py", line
287, in HandlerDispatch

File "/usr/lib/python2.4/site-packages/mod_python/apache.py", line
464, in import_module
module = imp.load_module(mname, f, p, d)

File "/var/www/equilex.eu/http/equilex/__init__.py", line 2, in ?
from equilex.model import Session

File "/var/www/equilex.eu/http/equilex/model/__init__.py", line 4, in ?
from page import Page

File "/var/www/equilex.eu/http/equilex/model/page.py", line 1, in ?
from menu import Menu

File "/var/www/equilex.eu/http/equilex/model/menu.py", line 1, in ?
import cElementTree as et

File "build/bdist.linux-i686/egg/cElementTree.py", line 7, in ?

File "build/bdist.linux-i686/egg/cElementTree.py", line 4, in

line 799, in resource_filename
return get_provider(package_or_requirement).get_resource_ filename(

line 1228, in get_resource_filename
self._extract_resource(manager, self._eager_to_zip(name))

line 1249, in _extract_resource
real_path = manager.get_cache_path(

line 880, in get_cache_path

line 846, in extraction_error
raise err

ExtractionError: Can't extract file(s) to egg cache

The following error occurred while trying to extract file(s) to the
Python egg

[Errno 13] Permission denied: '/var/www/.python-eggs'

The Python egg cache directory is currently set to:


Perhaps your account does not have write access to this directory? You can
change the cache directory by setting the PYTHON_EGG_CACHE environment
variable to point to an accessible directory.

Now, I already had a /tmp/eggs dir for eggs, and I had a SetEnv
directive in my vhost config for my Trac vhost (which uses eggs). So I
moved the SetEnv directive from the vhost config to my global
httpd.conf. Curious enough, after restarting apache2, I still got the
same error!! Is there any reason why it may not be picking up the env
variable that points it to the other directory?



Jun 12 '06 #1
0 1870

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by yoda | last post: by
3 posts views Thread by Charles | last post: by
2 posts views Thread by exhuma.twn | last post: by
7 posts views Thread by Ben Finney | last post: by
113 posts views Thread by John Nagle | last post: by
7 posts views Thread by Nader Emami | last post: by
1 post views Thread by Gerard M | last post: by
3 posts views Thread by Lawrence D'Oliveiro | last post: by
reply views Thread by suresh191 | last post: by
4 posts views Thread by guiromero | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.