[pve-devel] [RFC PATCH installer] fix #5973: auto: first boot: allow snake- and kebabcased property names
Thomas Lamprecht
t.lamprecht at proxmox.com
Thu Jan 30 11:06:41 CET 2025
Am 30.01.25 um 10:11 schrieb Daniel Kral:
> I also like that solution and that is more in line with the motivation
> behind the patch. I could queue up a patch for the next ISO release, so
> that it's indifferent to the user whether they write the config
> parameter names in their answer files in the old snake case or new
> kebab-case format.
Yes, please do.
> I'd prefer a single serde attribute for that rather than rename_all +
> alias at every property, if that's possible in a few lines, as it would
> be cleaner and we don't have to look at every property whether it's
> missing a alias attribute or not.
FWIW, you need to check out all structs that get serialized or are
member of such a struct anyway, and most are relatively small, so looking
at every property is not a big problem I think.
In the long term we might go back to a single variant to reduce complexity
for us and users. I'd target a relatively slow deprecation period for that
though, like e.g., allow both for Bookworm (e.g. PVE 8) and Trixie (e.g.
PVE 9) based releases but print a deprecation notice starting with Trixie
based releases and then drop support for the snake_case with Forky (e.g.
PVE 10) based releases.
Would be also good to know if there is any usage of snake_case for things
we send out, like the system info or post installation hook stuff.
More information about the pve-devel
mailing list