今天尝试在windows下搭建个人网站,选用了python3.5+django
安装了python3.5的64位版本,用pip install安装了django
运行python .manage.py runserver报错,提示错误如下:
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x000000000416A7B8>
Traceback (most recent call last):
File "F:Python3.5_64libsite-packagesdjangoutilsautoreload.py", line 229, in wrapper
fn(*args, **kwargs)
File "F:Python3.5_64libsite-packagesdjangocoremanagementcommandsrunserver.py", line 143, in inner_run
ipv6=self.use_ipv6, threading=threading)
File "F:Python3.5_64libsite-packagesdjangocoreserversbasehttp.py", line 191, in run
httpd = httpd_cls(server_address, WSGIRequestHandler, ipv6=ipv6)
File "F:Python3.5_64libsite-packagesdjangocoreserversbasehttp.py", line 76, in __init__
super(WSGIServer, self).__init__(*args, **kwargs)
File "F:Python3.5_64libsocketserver.py", line 443, in __init__
self.server_bind()
File "F:Python3.5_64libsite-packagesdjangocoreserversbasehttp.py", line 80, in server_bind
super(WSGIServer, self).server_bind()
File "F:Python3.5_64libwsgirefsimple_server.py", line 50, in server_bind
HTTPServer.server_bind(self)
File "F:Python3.5_64libhttpserver.py", line 140, in server_bind
self.server_name = socket.getfqdn(host)
File "F:Python3.5_64libsocket.py", line 658, in getfqdn
hostname, aliases, ipaddrs = gethostbyaddr(name)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb3 in position 0: invalid start byte
主要看出来两个熟悉的词,一个是IPv6,还有一个是UTF-8,但是不知道具体问题出在哪里。怀疑是不能使用ipv6,或者之类的错误。stack overflow上貌似有个类似的情况,但是刷不出来网页。
求助各位大神,帮忙解决一下。
第一次用ourcoders提问,请大家指正。