[QGIS-Developer] Boolean values vs. strings in QgsSettings and plugin meta data

Sebastian M. Ernst ernst at pleiszenburg.de
Wed Apr 1 04:43:32 PDT 2020

Hi all,

just seeking some clarification: There are plenty of places in QGIS
where Boolean values are derived from strings or converted to strings. I
have been mainly looking at the use in QgsSettings and plugin meta data.

So there are a few formats ... "yes"/"no", "1"/"0", "true"/"false",
"True"/"False" ...

When I touch a value, I usually stick to whatever form of serialization
the previous "owner" of this value has chosen (for backwards
compatibility). Though, is there some consensus on what to use and how
far backwards compatibility should go? (E.g. should QGIS 3.10 be able to
flawlessly work with a profile folder that was touched by QGIS 3.12 before?)

Best regards,

More information about the QGIS-Developer mailing list