I tried that before, then I get a no Caches error.<br><br>I've fixed this now. It's far from a perfect solution, but it works. I think my Python environment is not setup right.<br><br>My apache config:<br><Directory /var/www/tilecache/><br>
PythonPath "['/var/www/tilecache/']+sys.path"<br> AddHandler python-program .py<br> PythonHandler TileCache.Service<br> PythonOption TileCacheConfig /var/www/myapp/current/config/tilecache.cfg<br> PythonDebug On<br>
</Directory><br><br>LoadModule python_module /usr/lib/apache2/modules/mod_python.so<br># a hack to load mapnik library<br>LoadFile /usr/local/lib/libmapnik.so.0.5<br><br>Cheers,<br>Xin<br><br><br><div><span class="gmail_quote">On 28/03/2008, <b class="gmail_sendername">Frank Porcelli</b> <<a href="mailto:fporcelli@taic.net">fporcelli@taic.net</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div link="blue" vlink="blue" lang="EN-US">
<div>
<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;">Xin –</span></font></p>
<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;"> </span></font></p>
<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;">Change "TileCache.Service" to "TileCache/Service"
in your apache config and it should work.</span></font></p>
<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;"> </span></font></p>
<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;">Frank</span></font></p>
<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;"> </span></font></p>
<div>
<div style="text-align: center;" align="center"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">
<hr align="center" size="2" width="100%">
</span></font></div>
<p><b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma; font-weight: bold;">From:</span></font></b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma;">
<a href="mailto:tilecache-bounces@openlayers.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">tilecache-bounces@openlayers.org</a> [mailto:<a href="mailto:tilecache-bounces@openlayers.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">tilecache-bounces@openlayers.org</a>] <b><span style="font-weight: bold;">On Behalf Of </span></b>Xin<br>
<b><span style="font-weight: bold;">Sent:</span></b> Friday, March 28, 2008 3:07
PM<br>
<b><span style="font-weight: bold;">To:</span></b> <a href="mailto:tilecache@openlayers.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">tilecache@openlayers.org</a><br>
<b><span style="font-weight: bold;">Subject:</span></b> [Tilecache] mod_python
and no TileCache.Service error</span></font></p>
</div><div><span class="e" id="q_118f6cf930fbe0e6_1">
<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"> </span></font></p>
<p style="margin-bottom: 12pt;"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">I am trying to get
TileCache to work using mod_python. I get this error with my configuration:<br>
<br>
Phase: 'PythonHandler'<br>
Handler: 'TileCache.Service'<br>
<br>
ImportError: No module named TileCache.Service<br>
<br>
TileCache is located in /var/www/tilecache.<br>
<br>
ls /var/www/tilecache/<br>
docs
setup.py TileCache tilecache.cgi
tilecache.fcgi tilecache_install_config.py<br>
ez_setup.py tests
tilecache.cfg tilecache_clean.py tilecache_http_server.py tilecache_seed.p<br>
<br>
My apache2 config:<br>
# Tilecache configuration<br>
<Directory /var/www/tilecache/><br>
AddHandler python-program .py<br>
PythonHandler TileCache.Service<br>
PythonOption TileCacheConfig /var/www/myapp/config/tilecache.cfg<br>
PythonDebug On<br>
</Directory><br>
<br>
Alias /tilecache/ "/var/www/tilecache/"<br>
<Directory "/var/www/tilecache"><br>
AllowOverride None<br>
Options Indexes FollowSymLinks Multiviews<br>
Order allow,deny<br>
Allow from all<br>
</Directory><br>
<br>
<a href="http://www.nabble.com/Problem-with-TileCache-installation-td12671985.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.nabble.com/Problem-with-TileCache-installation-td12671985.html</a>
is some hints, but it didn't solve my problem. When I changed
PythonHandler TileCache.Service to PythonHandler TileCache/Service,
I got no Caches module error.<br>
<br>
Why can't it find the modules? do I need to set some environmental variable?<br>
<br>
Thanks for any help<br>
<br>
Xin<br>
<br>
</span></font></p>
</span></div></div>
</div>
</blockquote></div><br>