python - AttributeError: module 'html.parser' has no attribute 'HTMLParseError' -


  1. this hints,how can resolve it?
  2. i use python 3.5.1 created virtual envirement virtualenv
  3. the source code works on friend's computer machine

error:

traceback (most recent call last):   file "manage.py", line 10, in <module>     execute_from_command_line(sys.argv)   file "a:\python3.5\lib\site-packages\django\core\management\__init__.py", line 385, in execute_from_command_line     utility.execute()   file "a:\python3.5\lib\site-packages\django\core\management\__init__.py", line 354, in execute     django.setup()   file "a:\python3.5\lib\site-packages\django\__init__.py", line 18, in setup     django.utils.log import configure_logging   file "a:\python3.5\lib\site-packages\django\utils\log.py", line 13, in <module>     django.views.debug import exceptionreporter, get_exception_reporter_filter   file "a:\python3.5\lib\site-packages\django\views\debug.py", line 10, in <module>     django.http import (httpresponse, httpresponseservererror,   file "a:\python3.5\lib\site-packages\django\http\__init__.py", line 4, in <module>     django.http.response import (   file "a:\python3.5\lib\site-packages\django\http\response.py", line 13, in <module>     django.core.serializers.json import djangojsonencoder   file "a:\python3.5\lib\site-packages\django\core\serializers\__init__.py", line 23, in <module>     django.core.serializers.base import serializerdoesnotexist   file "a:\python3.5\lib\site-packages\django\core\serializers\base.py", line 6, in <module>     django.db import models   file "a:\python3.5\lib\site-packages\django\db\models\__init__.py", line 6, in <module>     django.db.models.query import q, queryset, prefetch  # noqa   file "a:\python3.5\lib\site-packages\django\db\models\query.py", line 13, in <module>     django.db.models.fields import autofield, empty   file "a:\python3.5\lib\site-packages\django\db\models\fields\__init__.py", line 18, in <module>     django import forms   file "a:\python3.5\lib\site-packages\django\forms\__init__.py", line 6, in <module>     django.forms.fields import *  # noqa   file "a:\python3.5\lib\site-packages\django\forms\fields.py", line 18, in <module>     django.forms.utils import from_current_timezone, to_current_timezone   file "a:\python3.5\lib\site-packages\django\forms\utils.py", line 15, in <module>     django.utils.html import format_html, format_html_join, escape   file "a:\python3.5\lib\site-packages\django\utils\html.py", line 16, in <module>     .html_parser import htmlparser, htmlparseerror   file "a:\python3.5\lib\site-packages\django\utils\html_parser.py", line 12, in <module>     htmlparseerror = _html_parser.htmlparseerror attributeerror: module 'html.parser' has no attribute 'htmlparseerror' 

as can read here error raised...

because htmlparseerror deprecated python 3.3 onwards , removed in python 3.5.

what can downgrade python version or upgrade django version.


Comments

Popular posts from this blog

c++ - llvm function pass ReplaceInstWithInst malloc -

Cross-Compiling Linux Kernel for Raspberry Pi - ${CCPREFIX}gcc -v does not work -

java.lang.NoClassDefFoundError When Creating New Android Project -