#14239: Form input button embedded in <a /> crashes Django server
----------------------------------+-----------------------------------------
 Reporter:  leeezly               |       Owner:  nobody    
   Status:  new                   |   Milestone:            
Component:  HTTP handling         |     Version:  1.2       
 Keywords:  input button firefox  |       Stage:  Unreviewed
Has_patch:  0                     |  
----------------------------------+-----------------------------------------
 I am running Ubuntu Lucid and got the default Django project setup without
 any apps included, created from Eclipse/Pydev. This only happens with
 Firefox but I reckon the problem is on the Django side, managing the HTTP
 requests, even though Firefox seems to send a double GET with the
 following setup.

 With the Pydev(1.6.2) debug server running in Eclipse, I constantly get
 this bug. With the server running from terminal, I get the bug only once
 at the beginning.

 The bug happens after pushing the input button (<input type="button">) in
 the browser.

 {{{
 urls.py:
    def view(request):
       return HttpResponse('<html><body><a href="/"><input
 type="button"></a></body></html>')

    urlpatterns = patterns('',
       (r'^/?$', 'urls.view'),
    )
 }}}

 ERROR:
 {{{
 Traceback (most recent call last):
   File "/usr/local/lib/python2.6/dist-
 packages/django/core/servers/basehttp.py", line 281, in run
     self.finish_response()
   File "/usr/local/lib/python2.6/dist-
 packages/django/core/servers/basehttp.py", line 321, in finish_response
     self.write(data)
   File "/usr/local/lib/python2.6/dist-
 packages/django/core/servers/basehttp.py", line 400, in write
     self.send_headers()
   File "/usr/local/lib/python2.6/dist-
 packages/django/core/servers/basehttp.py", line 464, in send_headers
     self.send_preamble()
   File "/usr/local/lib/python2.6/dist-
 packages/django/core/servers/basehttp.py", line 382, in send_preamble
     'Date: %s\r\n' % http_date()
   File "/usr/lib/python2.6/socket.py", line 300, in write
     self.flush()
   File "/usr/lib/python2.6/socket.py", line 286, in flush
     self._sock.sendall(buffer)
 error: [Errno 32] Broken pipe
 }}}

-- 
Ticket URL: <http://code.djangoproject.com/ticket/14239>
Django <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