{"action":"closed","issue":{"url":"https://api.github.com/repos/timc13/webapp-improved/issues/83","repository_url":"https://api.github.com/repos/timc13/webapp-improved","labels_url":"https://api.github.com/repos/timc13/webapp-improved/issues/83/labels{/name}","comments_url":"https://api.github.com/repos/timc13/webapp-improved/issues/83/comments","events_url":"https://api.github.com/repos/timc13/webapp-improved/issues/83/events","html_url":"https://github.com/timc13/webapp-improved/issues/83","id":141111010,"number":83,"title":"PathPrefixRoute redirects when rest of route is empty but then 404s.","user":{"login":"GoogleCodeExporter","id":9614759,"avatar_url":"https://avatars.githubusercontent.com/u/9614759?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCodeExporter","html_url":"https://github.com/GoogleCodeExporter","followers_url":"https://api.github.com/users/GoogleCodeExporter/followers","following_url":"https://api.github.com/users/GoogleCodeExporter/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCodeExporter/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCodeExporter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCodeExporter/subscriptions","organizations_url":"https://api.github.com/users/GoogleCodeExporter/orgs","repos_url":"https://api.github.com/users/GoogleCodeExporter/repos","events_url":"https://api.github.com/users/GoogleCodeExporter/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCodeExporter/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/timc13/webapp-improved/labels/auto-migrated","name":"auto-migrated","color":"ededed"},{"url":"https://api.github.com/repos/timc13/webapp-improved/labels/Priority-Medium","name":"Priority-Medium","color":"ededed"},{"url":"https://api.github.com/repos/timc13/webapp-improved/labels/Type-Defect","name":"Type-Defect","color":"ededed"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-03-15T21:56:33Z","updated_at":"2016-03-15T22:00:13Z","closed_at":"2016-03-15T22:00:13Z","body":"```\nWhat steps will reproduce the problem?\n1.\nclass HelloWorld(webapp2.RequestHandler):\n    @user_util.open_access\n    def get(self):\n        self.response.out.write(\"Hello World\")\n\napplication = request_handler.WSGIApplication([\n    routes.PathPrefixRoute('/hello', [\n        routes.RedirectRoute('',\n            HelloWorld,\n            strict_slash=True,\n            name=\"hello\"),\n        routes.RedirectRoute('/world',\n            HelloWorld,\n            strict_slash=True,\n            name=\"hello-world\")\n        ])\n    ])\n\n\n2.\nGo to /hello/\n\nWhat is the expected output? What do you see instead?\nA redirect to /hello and Hello World being output is expected. Instead it does \nthe redirect to /hello but I get a 404 then.\n\nUsing:\nwebapp2-2.5.2\n\nPlease provide any additional information below.\nChanging the regex in webapp2_extras/routes.py PathPrefixRoute.regex like:\n\n222c222\n<             webapp2._parse_route_template(self.prefix + '<:/.*>')\n---\n>             webapp2._parse_route_template(self.prefix + '<:|/.*>')\n\nwould allow both /hello/ and /hello to work while still forbidding /helloworld\n```\n\nOriginal issue reported on code.google.com by `ja...@khanacademy.org` on 23 Aug 2013 at 4:57"}}