Changeset 5156
- Timestamp:
- 08/18/08 15:29:58 (5 months ago)
- Files:
-
- branches/1.0/turbogears/qstemplates/quickstartbig/+package+/controllers/root.py_tmpl (modified) (1 diff)
- branches/1.0/turbogears/qstemplates/quickstart/+package+/controllers.py_tmpl (modified) (1 diff)
- branches/1.0/turbogears/startup.py (modified) (1 diff)
- branches/1.1/turbogears/qstemplates/quickstartbig/+package+/controllers/root.py_tmpl (modified) (1 diff)
- branches/1.1/turbogears/qstemplates/quickstart/+package+/controllers.py_tmpl (modified) (1 diff)
- branches/1.1/turbogears/startup.py (modified) (1 diff)
- branches/1.5/turbogears/tests/test_controllers.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/1.0/turbogears/qstemplates/quickstartbig/+package+/controllers/root.py_tmpl
r4334 r5156 30 30 31 31 forward_url = None 32 previous_url = request. path32 previous_url = request.object_path 33 33 34 34 if identity.was_login_attempted(): branches/1.0/turbogears/qstemplates/quickstart/+package+/controllers.py_tmpl
r4334 r5156 30 30 31 31 forward_url = None 32 previous_url = request. path32 previous_url = request.object_path 33 33 34 34 if identity.was_login_attempted(): branches/1.0/turbogears/startup.py
r5145 r5156 150 150 request.object_path = path[len(webpath):] 151 151 elif not request.path.startswith(webpath): 152 raise cherrypy.NotFound(path) 152 # check for webpath only if not forwarded 153 try: 154 if not request.wsgi_environ['HTTP_X_FORWARDED_SERVER']: 155 raise KeyError 156 except (AttributeError, KeyError): 157 raise cherrypy.NotFound(path) 153 158 154 159 branches/1.1/turbogears/qstemplates/quickstartbig/+package+/controllers/root.py_tmpl
r4363 r5156 30 30 31 31 forward_url = None 32 previous_url = request. path32 previous_url = request.object_path 33 33 34 34 if identity.was_login_attempted(): branches/1.1/turbogears/qstemplates/quickstart/+package+/controllers.py_tmpl
r4363 r5156 30 30 31 31 forward_url = None 32 previous_url = request. path32 previous_url = request.object_path 33 33 34 34 if identity.was_login_attempted(): branches/1.1/turbogears/startup.py
r5145 r5156 149 149 elif path.startswith(webpath): 150 150 request.object_path = path[len(webpath):] 151 elif not request.path.startswith(webpath): 151 elif not request.path.startswith(webpath): 152 # check for webpath only if not forwarded 153 try: 154 if not request.wsgi_environ['HTTP_X_FORWARDED_SERVER']: 155 raise KeyError 156 except (AttributeError, KeyError): 152 157 raise cherrypy.NotFound(path) 153 158 branches/1.5/turbogears/tests/test_controllers.py
r5145 r5156 590 590 def test_approots(self): 591 591 response = self.app.get("/subthing/", status=200) 592 # TODO: this works in 1.1, broken in 1.5 592 # TODO: this works in 1.0 and 1.1, broken in 1.5 593 # (probably because of check_app_root was removed in r5019) 593 594 # assert "/subthing/foo" in response 594 595 response = self.app.get("/nosubthing/", status=404) … … 597 598 def test_lower_approots(self): 598 599 response = self.app.get("/subthing/subsubthing/") 599 # TODO: this works in 1. 1, broken in 1.5600 # TODO: this works in 1.0 and 1.1, broken in 1.5 600 601 # assert "/subthing/subsubthing/foo" in response 601 602 … … 603 604 config.update({"server.webpath": "/coolsite/root"}) 604 605 response = self.app.get("/subthing/") 605 # TODO: this works in 1. 1, broken in 1.5606 # TODO: this works in 1.0 and 1.1, broken in 1.5 606 607 # assert "/coolsite/root/subthing/foo" in response 607 608