[PYTHON] Set sitecustomize.py on CircleCI.

For products with sys.getdefaultencoding ()! ='ascii', sitecustomize.py is required.

sitecustomize.py.cirlceci


# -*- coding: utf-8 -*-
import sys
sys.setdefaultencoding('utf-8')

circle.yml


dependencies:
  pre:
    - cp circleci/sitecustomize.py venv/lib/python2.7/sitecustomize.py

Like this.

I copied it to venv / lib / python2.7 / site-packages all the time and it didn't work and I was crying. In this case, CircleCI is Debian-based, so there is a file in /usr/lib/python2.7/sitecustomize.py and that is prioritized.

Recommended Posts

Set sitecustomize.py on CircleCI.
Set up Python 3.4 on Ubuntu
Set matplotlib font on ubuntu
Set up Polyglot on Windows
Set up Python environment on CentOS
Comment on Pull Request from CircleCI
Error compiling mmh3 module on CircleCI
Run cron on Amazon Linux (set on Linux)
Set the environment variable PYTHONPATH on zsh
Set swap space on Ubuntu on Raspberry Pi
On Ubuntu Linux, set Tab to q