Ticket #737 (defect)
Opened 7 months ago
Last modified 2 weeks ago
It's not possible to have custom request handler on application mount point
Status: closed (fixed)
| Reported by: | Almad | Assigned to: | rdelon |
|---|---|---|---|
| Priority: | high | Milestone: | |
| Component: | CherryPy code | Keywords: | |
| Cc: |
I have one application at /, second at /app. I'd like app to attach
dispatcher to both / and /app, which will redirect request with certain headers to /app/index and handling rest normally. Problem is, that clients are asking for /app?s=blahblah (and I cannot change it), instead of /app/?s=blahblah. Application at mount point / app is recognized (thus dipatcher on / has no effect), and thus path_info is empty string. Thus, request.get_resource() has no chance for loading proper dispatcher (because of while path_info chunk). Quick hack is to add if not trail:
tail = '/' before while cycle. This allows root dispatcher to be resolved.
Change History
10/04/07 10:55:12: Modified by fumanchu
- status changed from new to closed.
- resolution set to fixed.
04/26/08 19:20:46: Modified by fumanchu
Backported to 3.0.x in [1952].


Fixed in trunk in [1737].