#3414: middleware/common.py and SCGI bug - string index out of range
-----------------------------------------------------------+----------------
          Reporter:  Piotr MaliƄski <[EMAIL PROTECTED]>  |         Owner:  
nobody
            Status:  reopened                              |     Milestone:     
   
         Component:  Core framework                        |       Version:  
SVN   
        Resolution:                                        |      Keywords:     
   
             Stage:  Accepted                              |     Has_patch:  1  
   
        Needs_docs:  0                                     |   Needs_tests:  0  
   
Needs_better_patch:  0                                     |  
-----------------------------------------------------------+----------------
Changes (by Richard Davies <[EMAIL PROTECTED]>):

 * cc: [EMAIL PROTECTED] (added)

Comment:

 I run Django with Lighttpd, using the error-handler-404 mechanism borrowed
 from the standard Rails config for this web server
 (http://github.com/rails/rails/tree/master/railties/configs/lighttpd.conf)

 When run in this manner, Lighttpd does not set PATH_INFO
 
(http://trac.lighttpd.net/trac/wiki/FrequentlyAskedQuestions#Whatkindofenvironmentdoesserver
 .error-handler-404setup), so I have been using Jordi's
 attachment:wsgi_path_from_many_params.diff, which worked well at first for
 me, to take self.path from REQUEST_URI in the absence of PATH_INFO.

 More recently, when using query strings, I note that REQUEST_URI includes
 the query string (e.g. "/script/?foo=bar"), whereas self.path should not.
 I am therefore posting an update to Jordi's patch which correctly strips
 out the query string from REQUEST_URI before setting self.path. When used
 in this mode, Lighttpd also does not set QUERY_STRING itself, so I also
 take the opportunity to set QUERY_STRING based on REQUEST_URI if it is not
 already present.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/3414#comment:16>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to