0 出现问题的背景条件(废话篇)

在清理电脑临时文件之后,担心临时文件清理会出现有些软件不能正常启动的现象,尝试了当下正在学习的anaconda,果然,已启动出现了报错,想着出现问题了就解决呗,解决不了大不了重新下载, 也不麻烦
anaconda3卸载干净教程,亲测有效

安装anaconda3、tensorflow2.0、tensorflow2.4和tensorflow2.0-Gpu教程,实测

1 问题描述

启动anconda3出现了网页报错,搜了整个CSDN都没找到解决方法

Navigator Error
An unexpected error occurred on Navigator start-up

Report
Please report this issue in the anaconda issue tracker

Main Error
expected str, bytes or os.PathLike object, not NoneType
Traceback
Traceback (most recent call last):
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\exceptions.py", line 75, in exception_handler
    return_value = func(*args, **kwargs)
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\app\start.py", line 151, in start_app
    window = run_app(splash)
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\app\start.py", line 65, in run_app
    window = MainWindow(splash=splash, tab_project=False)
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\widgets\main_window.py", line 168, in __init__
    self.api = AnacondaAPI()
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\api\anaconda_api.py", line 2337, in AnacondaAPI
    ANACONDA_API = _AnacondaAPI()
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\api\anaconda_api.py", line 89, in __init__
    self._conda_api = CondaAPI()
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\api\conda_api.py", line 1773, in CondaAPI
    CONDA_API = _CondaAPI()
  File "D:\Anaconda\Anaconda3\lib\site-packages\anaconda_navigator\api\conda_api.py", line 353, in __init__
    self.sys_rc_path = join(self.ROOT_PREFIX, '.condarc')
  File "D:\Anaconda\Anaconda3\lib\ntpath.py", line 76, in join
    path = os.fspath(path)
TypeError: expected str, bytes or os.PathLike object, not NoneType

请添加图片描述

2 解决方法

  • 删除C盘/用户/用户名中的.conda和.condrac文件
  • 找到的有人说上述方法可以,我尝试了以下,我仅仅删除.condrac文件就可以了,亲测有效!!我的.conda是文件夹,.condrac是一个文件
  • 如果仅仅删除.condrac文件问题没有解决,可以尝试下再删除.conda文件夹,但是由于这一步我没有尝试,实在没有办法的 小伙伴可以尝试下,不保证!!!

3 参考文献

Logo

腾讯云面向开发者汇聚海量精品云计算使用和开发经验,营造开放的云计算技术生态圈。

更多推荐