[OpenLayers-Users] Tilecache 1.3 problems, mod_python, windows

joanne cook j.cook at oxfordarch.co.uk
Mon Jan 8 04:22:21 EST 2007


Hi All,
 
Having had problems getting tilecache to work using cgi, I am now trying using mod_python, under apache 2.2.3. As far as I can tell, mod_python is set up correctly, as I can get a test script to work. However, I am having no luck at all with tilecache. The only alteration I have made to tilecache.cfg is to chance the DiskCache base to /temp/tilecache. I am trying to access the following url:
http://localhost/tilecache-1.3/tilecache.py?LAYERS=basic&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&SRS=EPSG:4326&BBOX=-180,-90,0,90&WIDTH=256&HEIGHT=256
 
I have also changed the first line of my python files to #!c:/Python25/python.exe -u, which is the location of my python exe file.
 
I have included the following in my httpd.conf file (I also tried it as an .htaccess file):
 
<Directory "C:/xampp/tilecache-1.3/">
    AddHandler python-program .py
    PythonHandler TileCache.Service 
    PythonOption TileCacheConfig /tilecache.cfg
  PythonDebug On
</Directory>
 
 
The error I get is this:
MOD_PYTHON ERROR

ProcessId:      508
Interpreter:    'localhost'

ServerName:     'localhost'
DocumentRoot:   'C:/xampp/htdocs'

URI:            '/tilecache-1.3/tilecache.py'
Location:       None
Directory:      'C:/xampp/htdocs/tilecache-1.3/'
Filename:       'C:/xampp/htdocs/tilecache-1.3/tilecache.py'
PathInfo:       ''

Phase:          'PythonHandler'
Handler:        'TileCache.Service'

Traceback (most recent call last):

  File "C:\Python25\Lib\site-packages\mod_python\importer.py", line 1537, in HandlerDispatch
    default=default_handler, arg=req, silent=hlist.silent)

  File "C:\Python25\Lib\site-packages\mod_python\importer.py", line 1202, in _process_target
    module = import_module(module_name, path=path)

  File "C:\Python25\Lib\site-packages\mod_python\importer.py", line 304, in import_module
    return __import__(module_name, {}, {}, ['*'])

ImportError: No module named TileCache.Service

My concern is that I don't have the path to tilecache.cfg correctly set, or some other pythonpath problem. Given the above setup, what should these values be, or is there some other problem?

Cheers

Jo

-------------------------------------------
Joanne Cook BSc MLitt AIFA MBCS
Information Systems Coordinator
Oxford Archaeology North
-------------------------------------------


This message has been scanned for viruses by BlackSpider MailControl - www.blackspider.com



More information about the Users mailing list