[Tilecache] tilecache_seed.py KeyError
Matthew Perry
perrygeo at gmail.com
Sun Jul 27 19:48:24 EDT 2008
tilecache_seed.py KeyError - Resolved:
Service.cfgfiles is hardcoded to
('/etc/tilecache.cfg', '../tilecache.cfg', 'tilecache.cfg')
so tilecache_seed.py will only work if your cfg file is found in one
of those three locations. You can either symlink your cfg file to
/etc/tilecache.cfg or run the script from the tilecache directory.
- matt
On Sun, Jul 27, 2008 at 6:41 AM, Matthew Perry <perrygeo at gmail.com> wrote:
> On Sat, Jul 26, 2008 at 10:42 PM, ritesh ambastha
> <ritesh.linux at gmail.com> wrote:
>> While seeding through this tilecache.py file, you need to install
>> PythonPaste module. Also, mapscript.so should be globally accessible. I
>> would suggest, tilecache_seed.py
>> "http://localhost:81/tilecache/tilecache.cgi?" cities zoom_start zoom_end
>> "x1.0, y1.0,x2.0,y2.0"
>>
>
> Thanks for your input. paste and mapscript are both installed
> globally. the above command gives the same KeyError.
>
> To be clear, my tilecache web service is working perfectly, it's only
> the seeding that is giving me trouble.
>
>
>
>> On Sun, Jul 27, 2008 at 8:55 AM, Matthew Perry <perrygeo at gmail.com> wrote:
>>>
>>> I installed 2.04 and am having trouble seeding a cache.
>>>
>>> $ tilecache_seed.py "http://localhost:81/tilecache/tilecache.py?" cities 0
>>> 6
>>> Traceback (most recent call last):
>>> File "/usr/bin/tilecache_seed.py", line 5, in <module>
>>> pkg_resources.run_script('TileCache==2.04', 'tilecache_seed.py')
>>> File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 448,
>>> in run_script
>>> self.require(requires)[0].run_script(script_name, ns)
>>> File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 1166,
>>> in run_script
>>> execfile(script_filename, namespace, namespace)
>>> File
>>> "/usr/lib/python2.5/site-packages/TileCache-2.04-py2.5.egg/EGG-INFO/scripts/tilecache_seed.py",
>>> line 9, in <module>
>>> TileCache.Client.main()
>>> File
>>> "/usr/lib/python2.5/site-packages/TileCache-2.04-py2.5.egg/TileCache/Client.py",
>>> line 104, in main
>>> layer = svc.layers[sys.argv[2]]
>>> KeyError: 'cities'
>>>
>>> I can confirm that:
>>>
>>> a) there is a layer defined in my tilecache.cfg called 'cities'
>>> b) requesting a layer from the tilecache works just fine. eg:
>>>
>>>
>>> http://localhost:81/tilecache/tilecache.py?LAYERS=cities&FORMAT=image%2Fgif&TRANSPARENT=true&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&SRS=EPSG%3A54009&BBOX=-8923761.189473685,3438942.54105263,-8619883.395789474,3742820.334736841&WIDTH=256&HEIGHT=256
>>>
>>> So why doesn't tilecache_seed.py work? Any ideas?
>>>
>>>
>>>
>>>
>>> --
>>> Matthew T. Perry
>>> http://www.perrygeo.net
>>> _______________________________________________
>>> Tilecache mailing list
>>> Tilecache at openlayers.org
>>> http://openlayers.org/mailman/listinfo/tilecache
>>
>>
>
>
>
> --
> ·´¯`·.¸. , . .·´¯`·.. ><((((º>`·.¸¸.·´¯`·.¸.·´¯`·...¸><((((º>
> "The best way to predict the future is to invent it." -- Alan Kay
> Matthew T. Perry
> http://www.perrygeo.net
>
--
·´¯`·.¸. , . .·´¯`·.. ><((((º>`·.¸¸.·´¯`·.¸.·´¯`·...¸><((((º>
"The best way to predict the future is to invent it." -- Alan Kay
Matthew T. Perry
http://www.perrygeo.net
More information about the Tilecache
mailing list