找回密码
 会员注册
查看: 34|回复: 0

超算FatalPythonerrorinit_fs_encodingfailedtogetthePythoncodecofthefilesystemencoding

[复制链接]

2万

主题

0

回帖

6万

积分

超级版主

积分
63691
发表于 2024-9-13 13:00:46 | 显示全部楼层 |阅读模式
PythonpathconfigurationYTHONHOME=(notset)PYTHONPATH=(notset)programname='/lustre/home/xzhou/anaconda3/bin/python'isolated=0environment=1usersite=1importsite=1sys._base_executable='/lustre/home/xzhou/anaconda3/bin/python'sys.base_prefix='/lustre/home/xzhou/anaconda3'sys.base_exec_prefix='/lustre/home/xzhou/anaconda3'sys.executable='/lustre/home/xzhou/anaconda3/bin/python'sys.prefix='/lustre/home/xzhou/anaconda3'sys.exec_prefix='/lustre/home/xzhou/anaconda3'sys.path=['/lustre/home/xzhou/anaconda3/lib/python38.zip','/lustre/home/xzhou/anaconda3/lib/python3.8','/lustre/home/xzhou/anaconda3/lib/python3.8/lib-dynload',]FatalPythonerror:init_fs_encoding:failedtogetthePythoncodecofthefilesystemencodingPythonruntimestate:coreinitializedLookupError:nocodecsearchfunctionsregistered:can'tfindencodingCurrentthread0x00002ab215870ec0(mostrecentcallfirst)ythonpathconfigurationYTHONHOME=(notset)PYTHONPATH=(notset)programname='python'isolated=0environment=1usersite=1importsite=1sys._base_executable='/lustre/home/xzhou/anaconda3/bin/python'sys.base_prefix='/lustre/home/xzhou/anaconda3'sys.base_exec_prefix='/lustre/home/xzhou/anaconda3'sys.executable='/lustre/home/xzhou/anaconda3/bin/python'sys.prefix='/lustre/home/xzhou/anaconda3'sys.exec_prefix='/lustre/home/xzhou/anaconda3'sys.path=['/lustre/home/xzhou/anaconda3/lib/python38.zip','/lustre/home/xzhou/anaconda3/lib/python3.8','/lustre/home/xzhou/anaconda3/lib/python3.8/lib-dynload',]FatalPythonerror:init_fs_encoding:failedtogetthePythoncodecofthefilesystemencodingPythonruntimestate:coreinitializedLookupError:nocodecsearchfunctionsregistered:can'tfindencodingCurrentthread0x00002aed882fcec0(mostrecentcallfirst):123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051FatalPythonerror:init_fs_encoding:failedtogetthePythoncodecofthefilesystemencoding出现这种原因,我的是因为用了Anaconda的python!!!在cmd中输入python也会提示同样的问题!把PYTHONHOME和PYTHONPATH改成conda的目录即可!FatalPythonerror:initfsencoding:Unabletogetthelocaleencoding(好像不是同一个问题)C++Boost调用python报错:init_fs_encoding:failedtogetthePythoncodecofthefile错误:FatalPythonerror:init_fs_encoding:failedtogetthePythoncodecofthefilesystemencoding(经验证管用!!!!!!)已解决FatalPythonerror:init_fs_encoding:failedtogetthePythoncodecofthefilesystemencodinglinux查看python环境变量_Linux中添加PYTHONPATH配置anaconda环境变量方法
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 会员注册

本版积分规则

QQ|手机版|心飞设计-版权所有:微度网络信息技术服务中心 ( 鲁ICP备17032091号-12 )|网站地图

GMT+8, 2024-12-25 13:36 , Processed in 0.429041 second(s), 26 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表