I'm using python 2.7 and I'm trying to write a file with some encoding (in my 'finalList' variable the encoding is: 0xe9)
This is how I'm trying to write my file using the 'json' and 'io' modules
import json
import io
with io.open('my.json', 'w', encoding='utf8') as outfile:
json.dump(finalList, outfile)