django-devserver icon indicating copy to clipboard operation
django-devserver copied to clipboard

reload fails with "Address already in use"

Open sk1p opened this issue 15 years ago • 0 comments

sometimes, reloading fails with the following errors:

Validating models...
0 errors found

Django version 1.2.3, using settings 'testing123.settings'
Running django-devserver 0.0.4 (0477c17a47a251d58531b957fd480eff6e6d6d3d)
Forked server is running at http://127.0.0.1:8000/
Quit the server with CONTROL-C.
 * Running on http://127.0.0.1:8000/
Unhandled exception in thread started by <function inner_run at 0x16e28c0>
Traceback (most recent call last):
  File "/home/alex/.virtualenvs/test/src/devserver/devserver/management/commands/runserver.py", line 146, in inner_run
    use_reloader=use_reloader, use_debugger=True)
  File "/home/alex/.virtualenvs/test/lib/python2.6/site-packages/werkzeug/serving.py", line 529, in run_simple
    test_socket.bind((hostname, port))
  File "<string>", line 1, in bind
socket.error: [Errno 98] Address already in use

the same happens with the threaded server. usually, touching the file again makes the server work again.

sometimes, it prints the following

 * Detected change in '/home/alex/.virtualenvs/test/lib/python2.6/site-packages/simplecms/models.py', reloading

above or below.

this is with Werkzeug==0.6.2 and devserver 0477c17a47a251d58531b957fd480eff6e6d6d3d

sk1p avatar Nov 27 '10 04:11 sk1p