open5e-api
open5e-api copied to clipboard
Recurring random unicode characters in .json files.
Our json files occasionally get edited by stuff like pythons open() which sometimes results in weird character stuff.
Example of errant unicode showing up unwanted. https://github.com/open5e/open5e-api/pull/185/commits/6118e17e26ce3954d7ca4aaa661299738d4f396d
This is sometimes invisible to people editing the files (because of their editors and stuff).
Potential solutions:
- Tests (literally pytest tests) that check the files for a set of commonly messed up characters and fail if they show up.
- Pre-commit checks for unicode or something, I'm not sure exactly the specific scenario.
- Documentation on how to interact with the json files using python files plus maybe some examples?