Opened 14 years ago

Closed 14 years ago

Last modified 13 years ago

#15178 closed Uncategorized (worksforme)

Development server hangs very often when used with IE9 beta

Reported by: Catalin Iacob Owned by: nobody
Component: Core (Other) Version: 1.3-beta
Severity: Normal Keywords: ie9 development-server
Cc: Catalin Iacob Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

For almost every request made by IE9 beta the development server hangs or results in the following stacktrace:

----------------------------------------
Exception happened during processing of request from ('127.0.0.1', 51855)
Traceback (most recent call last):
  File "C:\Python26\lib\SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "C:\Python26\lib\SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "C:\Python26\lib\SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "d:\django-sites\django-trunk\django\core\servers\basehttp.py", line 569, in __init__
    BaseHTTPRequestHandler.__init__(self, *args, **kwargs)
  File "C:\Python26\lib\SocketServer.py", line 617, in __init__
    self.handle()
  File "d:\django-sites\django-trunk\django\core\servers\basehttp.py", line 609, in handle
    self.raw_requestline = self.rfile.readline()
  File "C:\Python26\lib\socket.py", line 444, in readline
    data = self._sock.recv(self._rbufsize)
error: [Errno 10054] An existing connection was forcibly closed by the remote host
----------------------------------------

To reproduce this, for me it's enough to start a new project with django-admin, run the development server and try to load an URL. Sometimes it takes one or two refreshes of the page to get the exception. After the exception appears the development server is completely hung, it won't respond to requests from other browsers until it's restarted. This makes the development server totally unusable in combination with IE9 beta.

This thread suggests that other people experience this as well.

Software versions that I used:

  • Django SVN HEAD from today (revision 15343)
  • IE9 beta
  • Python 2.6.6 32 bit
  • Windows 7 64 bit

Change History (10)

comment:1 by Catalin Iacob, 14 years ago

Cc: Catalin Iacob added

comment:2 by Russell Keith-Magee, 14 years ago

Component: UncategorizedCore framework
Resolution: worksforme
Status: newclosed

Jezdez hasn't been able to reproduce this; the mailing list thread seems to suggest that the problem may lie with network settings on the box in question.

If you can narrow down *specific* test conditions that reproduce, feel free to reopen with details.

comment:3 by ufef, 14 years ago

I'm experiencing the same issue.
Django 1.1.2, Python 2.6, Windows 7 64bit, IE9 beta.

Can be reproduced immediately by using Ctrl+F5 for refresh.

I am not going to reopen as I guess it might have nothing to do with Django in particular.

in reply to:  3 ; comment:4 by Jannis Leidel, 14 years ago

Replying to ufef:

I'm experiencing the same issue.
Django 1.1.2, Python 2.6, Windows 7 64bit, IE9 beta.

Can be reproduced immediately by using Ctrl+F5 for refresh.

I am not going to reopen as I guess it might have nothing to do with Django in particular.

Would you be so kind and disable the Windows (or any other) firewall software for a moment and try again?

in reply to:  4 comment:5 by Catalin Iacob, 14 years ago

Replying to jezdez:

Would you be so kind and disable the Windows (or any other) firewall software for a moment and try again?

I tried disabling the Windows firewall and the problem persists. I also upgraded to IE9 RC and it still happens. NOD32 is running on the machine with problems and has some web access protection feature that might interfere but disabling that doesn't help either.

However, on 2 other PCs running Vista and IE9 I'm not seeing the problem. They didn't have NOD32, I added it on one but it still works. So far the only obvious difference between the 2 machines where I saw it working and the 2 where it doesn't is Vista vs. Windows 7. Jezdez, which one of the two did you test?

comment:6 by anonymous, 13 years ago

Easy pickings: unset
Severity: Normal
Type: Uncategorized

I've run into this issues in earlier django versions with certain browsers. One solution I found is to avoid using any aliases like http://localhost:8000/ and instead use http://127.0.0.1:8000/

comment:7 by anonymous, 13 years ago

UI/UX: unset
Version: SVN1.3-beta

I also had the problem with IE9, I foudnt hat by using the real IP address of the machine when starting the dev server instead of the default seemed to resolve the issue. Not sure why or whats really going there but this issue is popping up more and more doing some google searches.

comment:8 by Paul McMillan, 13 years ago

If anyone who has this problem is can provide a wireshark dump of the traffic while this issue is being seen, it might help the rest of us replicate/debug it.

I'd be willing to bet that this issue (at least some incarnations of it) may be due to the single-threaded nature of the dev server in the current stable versions of Django. If a IE has opened a request, it may not be properly closing it, or may leave it open in the background to finish downloading something when the page is refreshed, leaving the one server thread hanging, never to complete.

The new multithreaded dev client may fix this issue.

comment:9 by jpablo.romero@…, 13 years ago

Using the ip of the machine solved the problem for us.

in reply to:  8 comment:10 by Catalin Iacob, 13 years ago

Replying to PaulM:

I'd be willing to bet that this issue (at least some incarnations of it) may be due to the single-threaded nature of the dev server in the current stable versions of Django.
The new multithreaded dev client may fix this issue.

Indeed, I can confirm that changeset 16427 (which makes the development server multithreaded) fixes the bug for me. Going back to changeset 16426 makes it fail again. Sorry for trying it out so late after PaulM's suggestion.

Note: See TracTickets for help on using tickets.
Back to Top