当前位置:网站首页>Conda創建虛擬環境報錯,問題解决

Conda創建虛擬環境報錯,問題解决

2022-06-12 07:52:00 NEOzhuo

問題描述

Fatal Python error: init_sys_streams: can't initialize sys standard Microsoft Windows [Version 10.0.17134.228] (c) 2018 Microsoft Corporation. All rights reserved. C:\WINDOWS\system32>c: C:\WINDOWS\system32>cd Python37-32 The system cannot find the path specified. C:\WINDOWS\system32>cd \ C:\>cd Python37-32 C:\Python37-32>python Fatal Python error: init_sys_streams: can't initialize sys standard streams
AttributeError: module 'io' has no attribute 'OpenWrapper'

Current thread 0x0000139c (most recent call first):

參考網址

解决方法

首先嘗試在命令行執行python -E,看是否不報錯,如果加-E不報錯的話,直接執行python報錯的話,就用下面的方法解决。

  • 在系統的環境變量裏:(我的電腦-屬性-高級設置-環境變量)裏面存在PYTHONHOMEPYTHONPATH,兩個環境變量,删除這兩個就可以了。

  • 如果因為使用snippets所以得用PYTHONHOME的話,那麼就在現有的環境變量PATH裏找肯定有跟PYTHONHOME重複的環境變量,删除就好了。

原网站

版权声明
本文为[NEOzhuo]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/163/202206120749192832.html

随机推荐