Using hashes for `stateVersion` instead of human-readable strings

To elaborate a bit, I think there ended up being three largely separate topics that should get PRs/further discussion:

  1. Changing system.stateVersion to something that isn’t a NixOS version
    • There’s pretty unanimous agreement that this should be done, only the exact shape the replacement should take and when it should be bumped isn’t fully agreed on.
    • I think a PR would be plenty of space to discuss this.
  2. Deprecating system.stateVersion and making it module-specific
    • Clearly desirable, but the impact on the ecosystem and third-party modules is huge, and there is worry about the amount of boilerplate this could add.
    • A PR might alleviate (or affirm) the latter, but I think a pre-RFC is warranted and the approach may be easier to swallow if 3. has at least been considered in more detail.
  3. Minimizing the use of system.stateVersion and clarifying in policy when it should be used
    • This would be nice because it makes the concept less nebulous, and it is clearly already not a very good way to handle the problems it is being used to handle.
    • We didn’t arrive at a full conclusion, I think a pre-RFC would be useful for this, as it could mean pretty wide changes in the contract of NixOS versions, and it would also impact third party modules.
10 Likes