0
0

More than 3 years have passed since last update.

Pythonデフォルトの文字コードの指定

Last updated at Posted at 2021-01-21

1.デフォルトの文字コード指定
1-1.path to python/Lib/site-packages でsitecustomize.pyを作成

~/path to python/Lib/site-packages
$ touch sitecustomize.py

1-2.下記コードを記載
文字コードは、公式サイトを参考にする。

sitecustomize.py
import sys
sys.setdefaultencoding('utf-8')
0
0
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0