Jenkins 执行 Saltstack 出现'ascii' codec can't decode 错误

python 默认编码问题
新增文件/usr/lib/python2.7/site-packages/sitecustomize.py

sitecustomize.py 文件示例:
import sys reload(sys) sys.setdefaultencoding(
'utf-8')

检测Python 编码 

>>> sys.getdefaultencoding() 
'utf-8' 
>>>

 

相关文章:

  • 2022-02-10
  • 2021-08-05
  • 2021-05-31
  • 2021-12-29
  • 2021-04-12
  • 2022-12-23
  • 2021-06-07
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-26
  • 2021-12-23
  • 2022-12-23
  • 2021-11-07
  • 2022-12-23
  • 2021-05-23
相关资源
相似解决方案