Oh, also just noticed you are using Windows. In that case also keep an eye on discussion:
http://groups.google.com/group/modwsgi/browse_frm/thread/15145cc2d0a12f02 The recipe on virtual environments referenced may need some tweaking for Windows if wanting to use WSGIPythonHome to create an isolated Python base environment. We are trying to sort out if it does or not at the moment. If you don't need an isolated base environment, remainder of recipe probably fine. Graham On Jan 17, 4:46 pm, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > On Jan 17, 2:43 pm, David <[EMAIL PROTECTED]> wrote: > > > The article I've been working from > > is:http://wiki.pylonshq.com/display/pylonscookbook/mod_wsgi+and+workinge... > > > It seems to be the simplest route, though I can't get it to work > > properly. Through the step where I verify mod_wsgi works, which it > > does, everything is OK. When I move on to the startup script and the > > activate_workingenv.py script, I start getting a 500 error. > > I'd suggest as a start using the following documentation instead: > > http://code.google.com/p/modwsgi/wiki/IntegrationWithPylons > http://code.google.com/p/modwsgi/wiki/VirtualEnvironments > > That workingenv example is more complicated than it needs to be. The > virtual environments documentation on mod_wsgi web site shows more > minimal solution. > > If you cannot get it working with these other instructions, show the > contents of your WSGI script file. > > Graham > > > I've pasted the error log lines from Apache below. I've tried to > > isolate the issue but can't seem to peg the exact problem. It seems > > like there is an issue importing from Paste . I do have Paste and > > PasteDeploy installed, verified with easy_setup - and I can run Pylons > > apps w/ Paste from command line anyway. Unless I'm reading it wrong, > > it seems like the import of pkg_resources is where the trouble starts. > > pkg_resources is part of setuptools which I do have installed. > > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] mod_wsgi > > (pid=5224): Target WSGI script 'C:/Program Files/Python25/Scripts/ > > helloworld/wsgi/myapp.wsgi' cannot be loaded as Python module. > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] mod_wsgi > > (pid=5224): Exception occurred processing WSGI script 'C:/Program > > Files/Python25/Scripts/helloworld/wsgi/myapp.wsgi'. > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] Traceback (most > > recent call last): > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "C:/ > > Program Files/Python25/Scripts/helloworld/wsgi/myapp.wsgi", line 9, in > > <module> > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] from > > paste.deploy import loadapp > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "c:\ > > \program files\\python25\\lib\\site-packages\\pastescript-1.3.6- > > py2.5.egg\\paste\\__init__.py", line 4, in <module> > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] import > > pkg_resources > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "C:\ > > \Program Files\\Python25\\lib\\site-packages\\pkg_resources.py", line > > 2552, in <module> > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] working_set > > = WorkingSet() > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "C:\ > > \Program Files\\Python25\\lib\\site-packages\\pkg_resources.py", line > > 384, in __init__ > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] > > self.add_entry(entry) > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "C:\ > > \Program Files\\Python25\\lib\\site-packages\\pkg_resources.py", line > > 399, in add_entry > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] for dist in > > find_distributions(entry, True): > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "C:\ > > \Program Files\\Python25\\lib\\site-packages\\pkg_resources.py", line > > 1614, in find_distributions > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] importer = > > get_importer(path_item) > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] File "C:\ > > \Program Files\\Python25\\lib\\pkgutil.py", line 376, in get_importer > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] importer = > > path_hook(path_item) > > [Wed Jan 16 21:19:10 2008] [error] [client 127.0.0.1] TypeError: > > zipimporter() argument 1 must be string, not module --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---
