[MapProxy] Re: Deploy MapProxy with isapi-wsgi

Jorge Gaspar Sanz Salinas jsanz at osgeo.org
Thu Mar 17 07:20:27 EDT 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

El 17/03/2011 11:54, Oliver Tonnhofer escribió:
> 
> On 17.03.2011, at 11:03, Jorge Gaspar Sanz Salinas wrote:
>>> The deployment of MapProxy shouldn't be that different than from TileCache, they are both Python applications. Or do you just use CGI? That is easier to setup, but much slower. 
>>
>> we're setting up tilecache as a cgi associating .py requests to the
>> executable, I know it's not the fastest way to deploy it, indeed.
>>
>> the cgi setup of mapproxy wasn't possible because some missing library
>> (eunuchs?) so I'm trying the ISAPI-WSGI way, we have not surrended :-)
> 
> The startup time of MapProxy is larger (more features, more code, longer startup), and so it is really not recommended to run MapProxy as CGI.
> 
> 
>>> If you have any additions to the documentation
>>>
>>> .. and you are familiar with mercurial/hg then you could just fork the documentation form http://bitbucket.org/olt/mapproxy, change the docs and make a pull request,
>>>
>>> .. or you could just update a file from https://bitbucket.org/olt/mapproxy/src/default/doc/ and mail it to me.
>>>
>>
>> probably the second one, I write restructuredtext everyday but I'm not
>> familiar with mercurial
> 
> 
> Yes, whatever works for you. I'm glad for any contribution.
> 
> Regards,
> Oliver
> 

Oliver thanks for your patience, I'm learning a few things regarding
python these days :-)

OK we've downgraded to PIL 1.1.6, this is my easy_isntall.pth file

import sys; sys.__plen = len(sys.path)
./mapproxy-1.0.0-py2.6.egg
./pastescript-1.7.3-py2.6.egg
./pastedeploy-1.3.4-py2.6.egg
./paste-1.7.5.1-py2.6.egg
./pyproj-1.8.9-py2.6-win32.egg
./isapi_wsgi-0.4.2-py2.6-win32.egg
./pil-1.1.6-py2.6-win32.egg
./pyyaml-3.09-py2.6-win32.egg
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:];
p=getattr(sys,'__egginsert',0); sys.path[p:p]=new; sys.__egginsert =
p+len(new)


There's a tool to see what's going on for Windows called win32traceutil
so now I can see the complete trace of 500 errors

c:\Python26\Lib\site-packages>python win32\lib\win32traceutil.py
Collecting Python Trace Output...
Internal Extension Error: Failed to import callback module 'isapi_mapproxy'
Last Windows error: No hay mßs archivos.
Traceback (most recent call last):
  File "c:\Python26\Lib\site-packages\isapi_mapproxy.py", line 13, in
<module>
    application = loadapp('config:config.ini',
relative_to="c:\\gis\\mapproxy\\apvmapproxy\\etc")
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 203, in loadapp
    return loadobj(APP, uri, name=name, **kw)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 223, in loadobj
    global_conf=global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 247, in loadcontext
    global_conf=global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 270, in _loadconfig
    return loader.get_context(object_type, name, global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 401, in get_context
    section)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 423, in _context_from_use
    object_type, name=use, global_conf=global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 353, in get_context
    global_conf=global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 247, in loadcontext
    global_conf=global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 277, in _loadegg
    return loader.get_context(object_type, name, global_conf)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 553, in get_context
    object_type, name=name)
  File
"C:\Python26\lib\site-packages\pastedeploy-1.3.4-py2.6.egg\paste\deploy\loadwsgi.py",
line 573, in find_egg_entry_point
    pkg_resources.require(self.spec)
  File "c:\Python26\Lib\site-packages\pkg_resources.py", line 666, in
require
    needed = self.resolve(parse_requirements(requirements))
  File "c:\Python26\Lib\site-packages\pkg_resources.py", line 565, in
resolve
    raise DistributionNotFound(req)  # XXX put more info here
pkg_resources.DistributionNotFound: PyYAML>=3.0,<3.99

It seems something with PyYAML but if I open a python console I can
import yaml without any problem (for example using yaml.dump({''name':"me"})

It seems I haven't learned enough anyway :-S

- -- 
Jorge Gaspar Sanz Salinas
http://es.osgeo.org
http://jorgesanz.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBAgAGBQJNge57AAoJEAOYD75lvHdBky8H/ir3Zj7T5CT3iVTqpMhZYgq+
mS8lvawBv/oB/xFbzyRiAsiK5Zsjjk7w6wSwCOFNPfFb2kSS+G4BX0C+SPxXRDIV
55YdNK4Fkk2EoTQktHwJQ2JXDVpIBUtXOIuPu2Sqq8LLVUOjBQuxw5RijXEHYMSB
eu3r1qdjzEq785Q+i1FC18XY3g6QExeS+dOIA3FIJUoyDXSSq96OHt03WJcJ0V8k
NbT99bVi6+2em5SzXa0ZnlKg9qBHp7brBc3qSmkp/5ihFB39eVhr2xUFiTD4Ut0l
EdZexff0iS/WzbV7hBqNfP+BOwgvw8HE0zH1aLq2PcRNBwDQdtI6NrD/ws4NfyE=
=lIGo
-----END PGP SIGNATURE-----


More information about the MapProxy mailing list