zc.buildout构建项目时报错‘AttributeError: '_NamespacePath' object has no attribute 'sort'’
在使用zc.buildout构建项目时如果碰到‘AttributeError: '_NamespacePath' object has no attribute 'sort'’报错:
An internal error occurred due to a bug in either zc.buildout or in a
recipe being used:
Traceback (most recent call last):
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 2123, in main
getattr(buildout, command)(args)
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 680, in install
[self[part]['recipe'] for part in install_parts]
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 680, in <listcomp>
[self[part]['recipe'] for part in install_parts]
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 1274, in __getitem__
options._initialize()
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 1382, in _initialize
self.initialize()
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 1388, in initialize
recipe_class = _install_and_load(reqs, 'zc.buildout', entry, buildout)
File "c:\python36\lib\site-packages\zc\buildout\buildout.py", line 1338, in _install_and_load
allow_hosts=buildout._allow_hosts
File "c:\python36\lib\site-packages\zc\buildout\easy_install.py", line 920, in install
return installer.install(specs, working_set)
File "c:\python36\lib\site-packages\zc\buildout\easy_install.py", line 673, in install
ws.add(dist)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 790, in add
self._added_new(dist)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 990, in _added_new
callback(dist)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 3047, in <lambda>
add_activation_listener(lambda dist: dist.activate(replace=True), existing=False)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 2574, in activate
fixup_namespace_packages(self.location)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 2162, in fixup_namespace_packages
subpath = _handle_ns(package, path_item)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 2091, in _handle_ns
_rebuild_mod_path(path, packageName, module)
File "c:\python36\lib\site-packages\pkg_resources\__init__.py", line 2120, in _rebuild_mod_path
orig_path.sort(key=position_in_sys_path)
AttributeError: '_NamespacePath' object has no attribute 'sort'
可以尝试升级一下setuptools来解决这个问题:
pip3 install --upgrade setuptools
zc.buildout构建项目时报错‘AttributeError: '_NamespacePath' object has no attribute 'sort'’的更多相关文章
- pycharm install python packaging tools时遇到AttributeError: '_NamespacePath' object has no attribute 'sort'错误
pycharm install python packaging tools时报错AttributeError: '_NamespacePath' object has no attribute 's ...
- 解决window7 x64位Anaconda启动报错:AttributeError: '_NamespacePath' object has no attribute 'sort'
最近论文需要用到python做数据分析,python语法简单,但是Windows下安装第三方包恶心的要命,statsmodels用pip死活安装不上,网上查了说包相互依赖windows下的pip不能下 ...
- 解决Win7(x64)Anaconda3报错:AttributeError: '_NamespacePath' object has no attribute 'sort'
最近论文需要用到python做数据分析,python语法简单,但是Windows下安装第三方包恶心的要命,statsmodels用pip死活安装不上,网上查了说包相互依赖windows下的pip不能下 ...
- facenet pyhton3.5 训练 train_softmax.py 时报错AttributeError: 'dict' object has no attribute 'iteritems'
报错原因:在进行facenet进行train_softmax.py训练时,在一轮训练结束进行验证时,报错AttributeError: 'dict' object has no attribute ' ...
- 在使用ubuntu16.04+python3.5 下使用pip3出现pip3 error - '_NamespacePath' object has no attribute 'sort'
使用pip3安装tensorflow以及gensim等时,出现如下错误: Traceback (most recent call last): File "/usr/local/bin/pi ...
- Python脚本报错AttributeError: ‘module’ object has no attribute’xxx’解决方法
最近在编写Python脚本过程中遇到一个问题比较奇怪:Python脚本完全正常没问题,但执行总报错"AttributeError: 'module' object has no attrib ...
- py+selenium 明明定位不到元素,但却不报错或是报错AttributeError: 'list' object has no attribute 'click'【已解决】
问题:定位不到元素,但却不报错或者出现报错AttributeError: 'list' object has no attribute 'click' 如图 或者 解决方法: 将”driver ...
- dnspython模块报错 AttributeError: 'CNAME' object has no attribute 'address'
有时候用到这个模块的时候会报错 AttributeError: 'CNAME' object has no attribute 'address' 如下所示 [root@ansible ch01]# ...
- 关于flask登录视图报错AttributeError: '_AppCtxGlobals' object has no attribute 'user'
在一个小程序中写了一个登录视图函数,代码如下: @app.route('/login',methods = ['GET','POST']) @oid.loginhandler def login(): ...
随机推荐
- 获取cookie值
function get_cookie(Name) { var search = Name + "=" var returnvalue = ""; if (do ...
- 「LuoguP4779」 【模板】单源最短路径(标准版)
Description 2018 年 7 月 19 日,某位同学在 NOI Day 1 T1 归程 一题里非常熟练地使用了一个广为人知的算法求最短路. 然后呢? 100→60: Ag→Cu: 最终,他 ...
- bzoj4555
ntt+cdq分治 原来zwh出的cf是斯特林 第二类斯特林数的定义是S(i,j)表示将i个物品分到j个无序集合的方案数,那么这道题中S(i,j)*j!*2^j是指将i个物品分到j个有序集合中并且每个 ...
- B. Chris and Magic Square
time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standa ...
- 自定义HTML中select控件
HTML中默认的select控件比较难看,大家可以参考,本文提供一种解决思路,当然也可以用CSS实现. function selectInit(tid,isIn){ if(!$("#&quo ...
- git apply failed (转载)
转自:http://blog.csdn.net/aaronzzq/article/details/6955893 git version 1.6.0.4 几个新手刚刚开始接触 Git,为了维护核心仓库 ...
- RxJava入门之路(二)
收集一下能够避免背压的运算符 sample(500, TimeUnit.MILLISECONDS) 定期收集数据,并发送最后一个 throttleFirst(500,TimeUnit.MILLISE ...
- ASP.NET Core Web API + Angular 仿B站(一) 目的分析以及创建 WebAPI + Angular7 项目
前言: 本系列文章主要为对所学 Angular 框架的一次微小的实践,对 b站页面作简单的模仿. 本系列文章主要参考资料: 微软文档: https://docs.microsoft.com/zh-cn ...
- hdoj1394
题意还告诉我们是0-n-1之间的数,那么我们每次把一个数放到后面去,求一下比他大的,还有比他小的: 比如: 1 3 6 9 0 8 5 7 4 2 逆序数num:22 3 6 9 0 8 5 7 4 ...
- python 生成器 generator
一.生成器定义 通过列表生成表达式,我们可以直接创建一个列表.但是,受到内存限制,列表容量肯定是有限的.所以,如果列表元素可以按照某种算法推算出来,那我们是否可以在循环的过程中不断推算出后续的元素呢? ...