Argh.  Stupid mistake.  Thanks for the help.  That solved the issue.

Brian


On Dec 10, 9:41 am, webcb <cberkho...@gmail.com> wrote:
> It looks like its working just fine. Comment out your Try Except
> statements and debug the error. It probably has something to do with
> "definitions" and "definitions.json" not combining to something
> meaningful.
>
> class list:
>         def GET(self):
>               return "hello world"
>
> On Dec 7, 10:01 pm, Brian Krisler <bkris...@bkds.com> wrote:
>
>
>
>
>
>
>
> > Hi,
>
> > I have a simple web app that works great in my development
> > environment, but when I try to run it on Apache with WSGI, I can not
> > get beyond the 'Not Found' page. I have verified that my script is
> > indeed getting called, as I added a custom Not found message and now I
> > get that displayed when I attempt to access the app, however that is
> > the only success I have attained.
>
> > So it is clear that I have messed up my urls somehow.  Any suggestions
> > would be great!
>
> > In my Apache config I have:
>
> > WSGIScriptAlias /lff /data/www/lff/lff.py
>
> > <Directory /data/www/lff>
> >   Order deny,allow
> >   Allow from all
> > </Directory>
>
> > Then in /data/www/lff/lff.py:
>
> > import web
> > import json
> > import os
>
> > urls = (
> >     '/', 'list',
> > )
>
> > app = web.application(urls, globals(), autoreload=False)
>
> > def notfound():
> >         return web.notfound("Sorry, the page you were looking for was
> > not found.")
>
> > app.notfound = notfound
>
> > class list:
> >         def GET(self):
> >                 i = web.input(name='definitions')
> >                 if i.name == 'definitions':
> >                         try:
> >                                 path = os.path.join("definitions",
> > "definitions.json");
> >                                 print path
> >                                 return open(path)
> >                         except IOError:
> >                                 raise web.NotFound()
> >                 else:
> >                         raise web.badrequest()
>
> > if __name__ == "__main__":
> >     app.run()
> > else:
> >     application = app.wsgifunc()
>
> > if I goto:http://myhost/lff/ I get Sorry, the page you were looking
> > for was not found.
>
> > From my understanding, the '/' in the urls should map to lff/ from the
> > URL, but that is not working. Is there something else I am missing?
>
> > Thanks for any suggestions.
>
> > Brian

-- 
You received this message because you are subscribed to the Google Groups 
"web.py" group.
To post to this group, send email to webpy@googlegroups.com.
To unsubscribe from this group, send email to 
webpy+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/webpy?hl=en.

Reply via email to