My main issue with TOML is precisely described in the homepage example:
[servers]
[servers.alpha]
is error prone. An sub heading shouldn't need to know about its parent, much less to have to copy it entirely.
[servers]
[servers.alpha]
is error prone. An sub heading shouldn't need to know about its parent, much less to have to copy it entirely.
Python 3.11.3 (main, May 4 2023, 05:53:32) [GCC 10.2.1 20210110]
Type 'copyright', 'credits' or 'license' for more information
IPython 8.13.2 -- An enhanced Interactive Python. Type '?' for help.
In [1]: !cat /tmp/x.toml
[servers.alpha]
x = 10
In [2]: import tomllib
...:
...: with open("/tmp/x.toml", "rb") as f:
...: t = tomllib.load(f)
...:
...: t
Out[2]: {'servers': {'alpha': {'x': 10}}}To the very best of my knowledge, Properties are merely Map<String,String> (see: https://docs.oracle.com/en/java/javase/11/docs/api/java.base... ) and any subsequent interpretation happens in the application (e.g. Spring treating `foo[1]=bar` as a list-ish assignment but the actual key returned from `getProperty` is the string literal as written `foo[1]`)