Kimvana / AIM

Other
6 stars 2 forks source link

More standardised / well-known input parameter file format, like YAML or TOML #5

Closed GlitchCat closed 8 months ago

GlitchCat commented 1 year ago

Having a more standardised and popular input parameter format would make it easier for other programs to create and/or read such an input parameter file without having to create a new parser for your custom format.

This would also reduce the code required in the FileHandler.py file for handling this input file format, possibly reducing bugs by using a well tested library.

JSON and XML are built into python, so those might also be nice. These are less human-readable though, so the decision is ultimately up to you depending on your concerns.

More info on TOML vs YAML: https://stackoverflow.com/questions/65283208/toml-vs-yaml-vs-strictyaml

For YAML PyYAML is popular. For TOML, tomllib is standardized: PEP 680 – tomllib: Support for Parsing TOML in the Standard Library