安装Django好 启动只要一访问8000端口就报告错误!那位高手给看一下!

安装Django好 启动只要一访问8000端口就报告错误!那位高手给看一下!

Django version 0.95 (post-magic-removal), using settings 'newtest.settings'
Development server is running at http://127.0.0.1:8000/
Quit the server with CONTROL-C.
----------------------------------------
Exception happened during processing of request from ('127.0.0.1', 3278
Traceback (most recent call last):
  File "/usr/local//lib/python2.4/SocketServer.py", line 222, in handle_request
    self.process_request(request, client_address)
  File "/usr/local//lib/python2.4/SocketServer.py", line 241, in process_request
    self.finish_request(request, client_address)
  File "/usr/local//lib/python2.4/SocketServer.py", line 254, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/usr/local/lib/python2.4/site-packages/django/core/servers/basehttp.py", line 537, in __init__
    BaseHTTPRequestHandler.__init__(self, *args, **kwargs)
  File "/usr/local//lib/python2.4/SocketServer.py", line 521, in __init__
    self.handle()
  File "/usr/local/lib/python2.4/site-packages/django/core/servers/basehttp.py", line 582, in handle
    if not self.parse_request(): # An error code has been sent, just exit
  File "/usr/local//lib/python2.4/BaseHTTPServer.py", line 276, in parse_request
    self.send_error(400, "Bad request syntax (%r)" % requestline)
  File "/usr/local//lib/python2.4/BaseHTTPServer.py", line 340, in send_error
    self.log_error("code %d, message %s", code, message)
  File "/usr/local//lib/python2.4/BaseHTTPServer.py", line 411, in log_error
    self.log_message(*args)
  File "/usr/local/lib/python2.4/site-packages/django/core/servers/basehttp.py", line 590, in log_message
    if self.path.startswith(self.admin_media_prefix) or self.path == '/favicon.ico':
AttributeError: WSGIRequestHandler instance has no attribute 'path'
----------------------------------------
我这mod_python mysql-python  mysql apache 都安装完毕了!
可真是翻山越岭的搞得
python manage.py runserver
Validating models...
0 errors found.
总于是弄出个 0 error  兴奋了半天 找局域网了另外一台机器访问8000端口没相应。
在本机 telnet  localhost  8000 报告错误
引用一下别人的话
在 http://www.djangoproject.com/documentation/django_admin/ 文档中专门讲述了这个问题。如果你不指定主机地址,django缺省会使用localhost即127.0.0.1。但其它的机器也存在这个地址。因此使用这个地址是不能被其它机器访问的。但你可以在启动时指定ip和端口,这样就可以了。如:

manage.py runserver 192.168.2.1:7000

终于看到界面了
这样在局域网的其他机器就可以访问界面了!
谢谢,我也遇到了同样的问题

看来看官方文档是王道啊,不知道国内有人翻印django官方文档没?还有那个diangobook