pip错误:TypeError: parse() got an unexpected keyword argument 'transport_encoding'

12653人阅读 评论(36) 收藏 举报
分类:

Win10,ANACONDA3(64-bit),Python3.6.2。ANACONDA Prompt中不能用pip命令安装包,并且是在安装了TensorFlow后才发生的。报错如下:

Exception:
Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\basecommand.py", line 215, in main
    status = self.run(options, args)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\commands\install.py", line 335, in run
    wb.build(autobuilding=True)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\wheel.py", line 749, in build
    self.requirement_set.prepare_files(self.finder)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\req\req_set.py", line 380, in prepare_files
    ignore_dependencies=self.ignore_dependencies))
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\req\req_set.py", line 554, in _prepare_file
    require_hashes
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\req\req_install.py", line 278, in populate_link
    self.link = finder.find_requirement(self, upgrade)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\index.py", line 465, in find_requirement
    all_candidates = self.find_all_candidates(req.name)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\index.py", line 423, in find_all_candidates
    for page in self._get_pages(url_locations, project_name):
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\index.py", line 568, in _get_pages
    page = self._get_page(location)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\index.py", line 683, in _get_page
    return HTMLPage.get_page(link, session=self.session)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\index.py", line 811, in get_page
    inst = cls(resp.content, resp.url, resp.headers)
  File "C:\ProgramData\Anaconda3\lib\site-packages\pip\index.py", line 731, in __init__
    namespaceHTMLElements=False,
TypeError: parse() got an unexpected keyword argument 'transport_encoding' 

解决办法:输入命令

conda install -c anaconda html5lib

会看到一系列更新的结果,然后再次使用pip安装包,发现可以成功安装


-------------------------------------------------------------------------------------------------------------------

更新

以上方法不成功的话,可以尝试输入命令:

conda install pip


查看评论

parse() got an unexpected keyword argument 'transport_encoding'

parse() got an unexpected keyword argument 'transport_encoding'
  • jacke121
  • jacke121
  • 2017-10-09 23:34:42
  • 7384

tweepy安装报错

pip install tweepy Downloading/unpacking tweepy   Downloading tweepy-3.5.0.tar.gz   Running setup...
  • poson
  • poson
  • 2015-11-23 16:34:06
  • 3548

TypeError: parse() got an unexpected keyword argument 'transport_encoding'

环境:win10, Anaconda3(64bit), python3.6.3问题:pip安装keras时出现报错:TypeError: parse() got an unexpected keywo...
  • kicilove
  • kicilove
  • 2017-12-08 16:27:43
  • 625

安装tflearn报错(typeerror parse() got an unexpected keyword argument transport_encoding)

原文:http://blog.csdn.net/cheese_pop/article/details/78201359 查了一些大神的博客,在anaconda prompt窗口安装tflearn...
  • u012535605
  • u012535605
  • 2018-01-29 16:14:34
  • 227

【Python配置】TypeError: parse() got an unexpected keyword argument 'transport_encoding'

1.找到Anaconda的路径 2.找到Lib的路径 3.找到site-packages的路径下的pip文件夹,打开 4.找到文件index.py,打开后找到731行,将transport_en...
  • TwT520Ly
  • TwT520Ly
  • 2018-02-01 15:49:36
  • 138

解决anaconda pip,parse() got an unexpected keyword argument 'transport_encoding'错误

听朋友说微软新开源的LightGBM可以直接用anaconda的pip安装,于是尝试了一下,环境为windows7,python3.6,可是在安装的时候失败了,提示parse() got an une...
  • slibra_L
  • slibra_L
  • 2017-12-16 12:02:55
  • 488

解决:TypeError: parse() got an unexpected keyword argument 'transport_encoding'

博主的系统环境如下:Win10 1709  教育版Anaconda3-5.0.1-Windows-x86_64.exePython是Anaconda中自带的3.6.3。由于原来电脑中装有Arcgis就...
  • qq_15969343
  • qq_15969343
  • 2018-01-13 22:07:36
  • 234

TypeError:__init__() got an unexpected keyword argument 'xxx'

第一用parcharm连接MySQL数据库时候,出现如下错误:> Traceback (most recent call last): File > "F:/pycharm/数据库mysql/co...
  • zhongxuejiwen
  • zhongxuejiwen
  • 2017-07-27 16:14:56
  • 5608

Windows下Keras报错TypeError: <lambda>() got an unexpected keyword argument 'name'

Keras 报错 TypeError: lambda() got an unexpected keyword argument ‘name’ 环境 Windows10 x64 Keras 0...
  • jk123vip
  • jk123vip
  • 2016-04-07 04:36:25
  • 2165
    个人资料
    持之以恒
    等级:
    访问量: 10万+
    积分: 1935
    排名: 2万+
    最新评论