What's your console output? What's the exact error message?
Did you include a trailing "."? You should not. I cannot replicate the issue without further information. --steve On 10/28/16 at 12:01 AM, [email protected] (Rado Duoistin) pronounced: > Hi all. I apologize for a simple question. > > > I'm doing a lesson > http://docs.pylonsproject.org/projects/pyramid/en/latest/quick_tutorial/request_response. > htm > <http://docs.pylonsproject.org/projects/pyramid/en/latest/quick_tutorial/request_response. > html> > > Why am I getting a 404 error when calling http://0.0.0.0:6543/plain. > > My *__init__.py* > from pyramid.config import Configurator > > > def main(global_config, **settings): > config = Configurator(settings=settings) > config.add_route('home', '/') > config.add_route('plain', '/plain') > config.scan('.views') > return config.make_wsgi_app() > > > My *views.py* > from pyramid.httpexceptions import HTTPFound > from pyramid.response import Response > from pyramid.view import view_config > > > > > class TutorialViews: > def __init__(self, request): > self.request = request > > > @view_config(route_name='home') > def home(self): > return HTTPFound(location='/plain') > > > @view_config(route_name='plain') > def plain(self): > name = self.request.params.get('name', 'No Name Provided') > > > body = 'URL %s with name: %s' % (self.request.url, name) > return Response( > content_type='text/plain', > body=body > ) > > I have config.add_route('plain', '/plain') and return HTTPFound(location= > '/plain'), but 404 not found ((( > > Where did I go wrong? > ------------------------ Steve Piercy, Soquel, CA -- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pylons-discuss/r471Ps-1085i-74A55880CA6C48358416576B2245C78A%40stevepi-mbp.local. For more options, visit https://groups.google.com/d/optout.
