Several parameter mistakes produce either an unusable message or none at all.
Mistake
What happens
int where a double is expected (C++ path)
bare std::bad_any_cast, names nothing
misspelt optional key (C++ path)
silently ignored; the JSON path warns
"max_iter": 7.9
silently truncated to 7
missing required parameter
C++: names one of several; JSON: names none. Never names the material
numsim-core already provides check_data_type (-> Parameter 'K' has wrong type) and range<Min, Max>. No material uses either.
Fix
attach check_data_type when a parameter is declared, so it applies to every material at once rather than per material;
reject unknown keys in the C++ path the same way the JSON path warns;
reject a non-integral value for an integer parameter;
wrap parameter errors at the material boundary so the message carries the material name and type (numsim-core cannot know these). The missing-names half is tracked in Missing-parameter error reports a count, not the parameter names numsim-core#20 .
All references are to main at 91bd26f .
Several parameter mistakes produce either an unusable message or none at all.
intwhere adoubleis expected (C++ path)std::bad_any_cast, names nothing"max_iter": 7.9numsim-core already provides
check_data_type(->Parameter 'K' has wrong type) andrange<Min, Max>. No material uses either.Fix
check_data_typewhen a parameter is declared, so it applies to every material at once rather than per material;All references are to
mainat 91bd26f.