genshindev / api

A fan-made Genshin Impact API for easy access to game data.
https://genshin.jmp.blue
Open Software License 3.0
692 stars 187 forks source link

Repair Dehya JSON #208

Closed man90es closed 1 year ago

man90es commented 1 year ago

It looks like Python has trouble processing the dash symbol in Dehya's JSON file. This PR replaces it with a correct UTF-8 en dash symbol.

The error that Python's built-in JSON module produces with the original file is UnicodeDecodeError: 'utf-8' codec can't decode byte 0x96 in position 6916: invalid start byte when executing code analogous to this:

import json

f = open("assets/data/characters/dehya/en.json")
json_data = json.load(f)