gpt4 book ai didi

python - 尝试安装biopython后,Conda返回未找到的属性错误符号

转载 作者:行者123 更新时间:2023-12-02 16:12:37 26 4
gpt4 key购买 nike

我一直在努力使biopython工作,似乎我在此过程中破坏了conda。此时,将显示conda的帮助菜单,并且conda --version返回conda 4.7.5,但是其他所有内容(包括conda info都将引发错误AttributeError: dlsym(0x1004381c0, archive_read_open_filename_w): symbol not found

这是在Mac OS 10.14.4上。 Conda只是在工作,我最后一次使用它来安装biopython而不出现错误conda install -c conda-forge biopython。运行import Bio仍然会导致一个ImportError: No module named Bio。因此,在故障排除中,我运行了pip uninstall biopython(表示已成功卸载了biopython-1.73),并运行了pip install biopython,返回了:

Requirement already satisfied: biopython in /Users/dmattox/anaconda/lib/python2.7/site-packages (1.73)
Requirement already satisfied: numpy in /Users/dmattox/anaconda/lib/python2.7/site-packages (from biopython) (1.13.1)


然后,我再次尝试使用conda conda install -c conda-forge biopython安装,它从 conda info返回了上面显示的相同错误。我现在尝试使用conda进行任何操作时,都会出现此AttributeError。我在下面包括了追溯。有什么建议?

Traceback (most recent call last):
File "/Users/dmattox/anaconda/bin/conda", line 13, in <module>
sys.exit(main())
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/cli/main.py", line 150, in main
return conda_exception_handler(_main, *args, **kwargs)
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1335, in conda_exception_handler
return_value = exception_handler(func, *args, **kwargs)
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1046, in __call__
return self.handle_exception(exc_val, exc_tb)
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1090, in handle_exception
return self.handle_unexpected_exception(exc_val, exc_tb)
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1101, in handle_unexpected_exception
self.print_unexpected_error_report(error_report)
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1171, in print_unexpected_error_report
from .cli.main_info import get_env_vars_str, get_main_info_str
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/cli/main_info.py", line 19, in <module>
from ..core.index import _supplement_index_with_system
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/core/index.py", line 9, in <module>
from .package_cache_data import PackageCacheData
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda/core/package_cache_data.py", line 15, in <module>
from conda_package_handling.api import InvalidArchiveError
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/conda_package_handling/api.py", line 3, in <module>
from libarchive.exception import ArchiveError as _LibarchiveArchiveError
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/libarchive/__init__.py", line 1, in <module>
from .entry import ArchiveEntry
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/libarchive/entry.py", line 6, in <module>
from . import ffi
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/libarchive/ffi.py", line 184, in <module>
c_int, check_int)
File "/Users/dmattox/anaconda/lib/python2.7/site-packages/libarchive/ffi.py", line 95, in ffi
f = getattr(libarchive, 'archive_'+name)
File "/Users/dmattox/anaconda/lib/python2.7/ctypes/__init__.py", line 375, in __getattr__
func = self.__getitem__(name)
File "/Users/dmattox/anaconda/lib/python2.7/ctypes/__init__.py", line 380, in __getitem__
func = self._FuncPtr((name_or_ordinal, self))
AttributeError: dlsym(0x100548400, archive_read_open_filename_w): symbol not found

最佳答案

通过zhihu中的方法解决了我的错误

这是我解决问题的步骤,希望对您有所帮助:

在Mac上导致此错误的原因是之前已安装Python,我试图删除所有python和Anaconda文件,然后再次安装anaconda,然后成功运行conda命令。


从Macintouch-> Frameworks-> PythonFramework-> Versions-> 3.x中删除python
删除.bash_profile中有关python和anaconda的所有记录(通过shift + command +查找此隐藏文件。)
在应用程序中删除anaconda导航器
再次安装Anaconda

关于python - 尝试安装biopython后,Conda返回未找到的属性错误符号,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56878603/

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