You can open with codecs
:
import json
import codecs
json.load(codecs.open('sample.json', 'r', 'utf-8-sig'))
or decode with utf-8-sig
yourself and pass to loads
:
json.loads(open('sample.json').read().decode('utf-8-sig'))
You can open with codecs
:
import json
import codecs
json.load(codecs.open('sample.json', 'r', 'utf-8-sig'))
or decode with utf-8-sig
yourself and pass to loads
:
json.loads(open('sample.json').read().decode('utf-8-sig'))