Open dburov190 opened 5 years ago
The section names seems to be lowercased yes:
https://github.com/JuliaIO/ConfParser.jl/blob/master/src/ConfParser.jl#L109
It would probably make sense to lowercase the key when retrieving.
Either that or, maybe, just leave it as it is? i.e. substitute the linked line with
blockname = m.captures[1]
I think it would be more standard behavior? Python's configparser does that.
If an INI file has a section named
[General]
, then callingvar = retrieve(conf, "General", "var")
will cause an exception (since the dictionary field ofconf
will have "general" as one of the keys).It would be nice to have case-sensitive sections, but at the very least it shouldn't spit out an error, i.e. it should convert everything to lower case, for example, before trying to find a key in the internal dictionary.