What happened?
I've got a json file with the following structure
{"rules": [
{...},
{...},
...,
{...},
]}
The file is read with eckit::LocalConfiguration{eckit::YAMLConfiguration{eckit::PathName{...}}}
and accessed with .getSubConfigurations("rules"), which returns a std::vector<eckit::LocalConfiguration>.
Now, because of the trailing comma, the vector contains an additional element which is printed as LocalConfiguration[root=].
This element is not expected.
For a formal JSON, the trailing comma would not be allowed. In a YAML file it should (AFAIK - maybe compare with this closed issue on the YAML formatter prettier: prettier/prettier#7452)
What are the steps to reproduce the bug?
Create an additional test that parses a list with trailing comma.
Version
1.30.0
Platform (OS and architecture)
Atos
Relevant log output
There are just followup errors when accessing keys in the subdictionary.
Explicitly printing the last entry shows `LocalConfiguration[root=]`.
Accompanying data
No response
Organisation
ECMWF
What happened?
I've got a json file with the following structure
The file is read with
eckit::LocalConfiguration{eckit::YAMLConfiguration{eckit::PathName{...}}}and accessed with
.getSubConfigurations("rules"), which returns astd::vector<eckit::LocalConfiguration>.Now, because of the trailing comma, the vector contains an additional element which is printed as
LocalConfiguration[root=].This element is not expected.
For a formal JSON, the trailing comma would not be allowed. In a YAML file it should (AFAIK - maybe compare with this closed issue on the YAML formatter
prettier: prettier/prettier#7452)What are the steps to reproduce the bug?
Create an additional test that parses a list with trailing comma.
Version
1.30.0
Platform (OS and architecture)
Atos
Relevant log output
Accompanying data
No response
Organisation
ECMWF