Merge "Set default python encoding to utf-8"

This commit is contained in:
Jenkins 2017-02-06 11:48:03 +00:00 committed by Gerrit Code Review
commit 8b65d9184f
1 changed files with 6 additions and 0 deletions

View File

@ -12,7 +12,13 @@
# License for the specific language governing permissions and limitations
# under the License.
import codecs
import os
import sys
# Set default io encoding
sys.stdout = codecs.getwriter('utf8')(sys.stdout)
sys.stderr = codecs.getwriter('utf8')(sys.stderr)
_boolean_states = {'1': True, 'yes': True, 'true': True, 'on': True,
'0': False, 'no': False, 'false': False, 'off': False}