make logging string unicode

This commit is contained in:
debugtalk
2017-11-02 20:40:56 +08:00
parent 0018f5257e
commit 895478719d
5 changed files with 22 additions and 21 deletions

View File

@@ -136,7 +136,7 @@ class HttpSession(requests.Session):
try:
response.raise_for_status()
except RequestException as e:
logging.error(" Failed to {method} {url}! exception msg: {exception}".format(
logging.error(u" Failed to {method} {url}! exception msg: {exception}".format(
method=method, url=url, exception=str(e)))
else:
logging.info(