From 0b30de4b163e9642f1bfa59ac07607c966b4a7de Mon Sep 17 00:00:00 2001 From: Numan Siddique Date: Wed, 11 Feb 2015 20:27:22 +0530 Subject: [PATCH] Enable utf-8 support in schema transformer To support utf-8 characters in resource name, the default encoding needs to be changed to 'utf-8' for schema transformer as well. Change-Id: Iebf3344820519ef2ca3e8f5a72fa697ebc40e982 Partial-Bug: #1396894 --- src/config/schema-transformer/to_bgp.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/config/schema-transformer/to_bgp.py b/src/config/schema-transformer/to_bgp.py index f23e9499c72..0eb5d80d725 100644 --- a/src/config/schema-transformer/to_bgp.py +++ b/src/config/schema-transformer/to_bgp.py @@ -14,6 +14,8 @@ from gevent import monkey monkey.patch_all() import sys +reload(sys) +sys.setdefaultencoding('UTF8') import requests import ConfigParser import cgitb