完整报错是:
CommandNotFoundError: Your shell has not been properly configured to use 'conda activate'.
To initialize your shell, run
$ conda init <SHELL_NAME>
Currently supported shells are:
- bash
- fish
- tcsh
- xonsh
- zsh
- powershell
See 'conda init --help' for more information and options.
IMPORTANT: You may need to close and restart your shell after running 'conda init'.
解决方法
在控制台运行:
source activate
conda deactivate
问题解析
未正确退出环境,会导致这样的报错。如果按照它说的先退出并重启shell,再执行conda init并没有什么卵用…
本文讲述了如何处理因未正确退出Conda环境导致的'condaactivate'命令找不到的错误,包括错误原因、解决步骤和常见误解。重点在于提供正确操作方法,如源码激活和环境切换技巧。
1006

被折叠的 条评论
为什么被折叠?



