fix python 3 error

fix json.loads "TypeError: can't use a string pattern on a bytes-like object"