python manage.py runserver 出错

qq_jgmlx5of Django开发-基础篇 最后由 qq_jgmlx5of 于2016年09月28日回复

  • 2 解决
  • 4.1k 浏览

C:UsersAdministrator>cd E:python_space

C:UsersAdministrator>e:

E:python_space>django-admin.py startproject a002

E:python_space>cd a002

E:python_spacea002>python manage.py runserver

Traceback (most recent call last):

File "manage.py", line 10, in execute_from_command_line(sys.argv)

File "D:python35libsite-packagesdjangocoremanagement__init__.py", line385, in execute_from_command_line utility.execute()

File "D:python35libsite-packagesdjangocoremanagement__init__.py", line354, in execute django.setup() File "D:python35libsite-packagesdjango__init__.py", line 18, in setup from django.utils.log import configure_logging

File "D:python35libsite-packagesdjangoutilslog.py", line 10, in from django.views.debug import ExceptionReporter, get_exception_reporter_filter

File "D:python35libsite-packagesdjangoviewsdebug.py", line 10, in from django.http import (HttpResponse, HttpResponseServerError,

File "D:python35libsite-packagesdjangohttp__init__.py", line 4, in from django.http.response import (HttpResponse, StreamingHttpResponse,

File "D:python35libsite-packagesdjangohttpresponse.py", line 13, in from django.core.serializers.json import DjangoJSONEncoder

File "D:python35libsite-packagesdjangocoreserializers__init__.py", line 23, in from django.core.serializers.base import SerializerDoesNotExist

File "D:python35libsite-packagesdjangocoreserializersbase.py", line 6,in from django.db import models File "D:python35libsite-packagesdjangodbmodels__init__.py", line 6, in from django.db.models.query import Q, QuerySet, Prefetch # NOQA

File "D:python35libsite-packagesdjangodbmodelsquery.py", line 13, in from django.db.models.fields import AutoField, Empty 

File "D:python35libsite-packagesdjangodbmodelsfields__init__.py", line 18, in from django import forms

File "D:python35libsite-packagesdjangoforms__init__.py", line 6, in from django.forms.fields import * # NOQA

File "D:python35libsite-packagesdjangoformsfields.py", line 18, in from django.forms.utils import from_current_timezone, to_current_timezone

File "D:python35libsite-packagesdjangoformsutils.py", line 15, in from django.utils.html import format_html, format_html_join, escape

File "D:python35libsite-packagesdjangoutilshtml.py", line 16, in from .html_parser import HTMLParser, HTMLParseError

 File "D:python35libsite-packagesdjangoutilshtml_parser.py", line 12, in

HTMLParseError = _html_parser.HTMLParseErrorAttributeError: module 'html.parser' has no attribute 'HTMLParseError'E:python_spacea002>