gpt4 book ai didi

python - Anaconda3 - 属性错误 : 'dict' object has no attribute 'rsplit'

转载 作者:太空狗 更新时间:2023-10-29 17:47:07 27 4
gpt4 key购买 nike

我正在通过网络浏览器在本地运行 Anaconda3。每次我去“Conda”部分查看已安装的包(位于 http://localhost:8888/tree#conda)时,我都会收到 An error occurred while retrieving installed packages。内部服务器错误

查看日志,这是目前正在发生的事情。有什么想法吗?

[E 13:53:08.195 NotebookApp] 500 GET /conda/environments/root?_=1484574786374 (127.0.0.1) 760.41ms referer=http://localhost:8888/tree?
[E 13:53:14.557 NotebookApp] Unhandled error in API request
Traceback (most recent call last):
File "/root/anaconda3/lib/python3.5/site-

packages/notebook/base/handlers.py", line 503, in wrapper
result = yield gen.maybe_future(method(self, *args, **kwargs))
File "/root/anaconda3/lib/python3.5/site-packages/nb_conda/handlers.py", line 62, in get
self.finish(json.dumps(self.env_manager.env_packages(env)))
File "/root/anaconda3/lib/python3.5/site-packages/nb_conda/envmanager.py", line 124, in env_packages
"packages": [pkg_info(package) for package in data]
File "/root/anaconda3/lib/python3.5/site-packages/nb_conda/envmanager.py", line 124, in <listcomp>
"packages": [pkg_info(package) for package in data]
File "/root/anaconda3/lib/python3.5/site-packages/nb_conda/envmanager.py", line 16, in pkg_info
name, version, build = s.rsplit('-', 2)
AttributeError: 'dict' object has no attribute 'rsplit'
[E 13:53:14.558 NotebookApp] {
"Accept-Language": "en-US,en;q=0.8,es;q=0.6",
"Connection": "keep-alive",
"X-Requested-With": "XMLHttpRequest",
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36",
"Accept-Encoding": "gzip, deflate, sdch, br",
"Cookie": "_xsrf=2|0e84028c|becasdfafdssffjkafdsjkf473451bfcb|1484574343; username-localhost-8888=\"2|1:0|10:1484574347|23:username-localhost-8888|44:ODBlMWE5Mjk1MjRiNDNmNDhkZTVkNTU5MGI3NTNmNDQ=|83dad5a9e1aa2da460539882d41f5b3a7ac93163dab3b324526b730be88d7d69\"",
"Referer": "http://localhost:8888/tree?",
"Host": "localhost:8888",
"Accept": "application/json, text/javascript, */*; q=0.01"
}
[E 13:53:14.559 NotebookApp] 500 GET /conda/environments/root?_=1484574792779 (127.0.0.1) 750.79ms referer=http://localhost:8888/tree?

最佳答案

也许这应该是一个评论,但我没有足够的声誉。

这是一个 reported bug in nb_conda . conda 的 package info 的输出格式发生了变化,需要对 nb_conda 进行适配。已经有一个 pull request that fixes this但我在任何 channel 都找不到零钱。

安装包含修复程序的分支目前有帮助:

pip install git+https://github.com/Anaconda-Platform/nb_conda.git@d488d9e --upgrade

--upgrade 是可选的,我需要它,因为我安装的版本相同。

conda-forge channel 安装 nb_conda_kernels(可能已将 nb_conda 作为依赖引入),如 motivic 所述对我的情况没有帮助,但如果那里的软件包包含修复程序,应该可以工作。

关于python - Anaconda3 - 属性错误 : 'dict' object has no attribute 'rsplit' ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41678162/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com