-
-
Notifications
You must be signed in to change notification settings - Fork 158
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RFC 0137] Nix language versioning #137
base: master
Are you sure you want to change the base?
Conversation
f1002b3
to
04a6fc1
Compare
04a6fc1
to
bb73166
Compare
This comment was marked as resolved.
This comment was marked as resolved.
the convention indeed does not encourage discipline, as @andir points out[1], and at the worst would encourage haphazard changes because it makes them appear harmless, as @tazjin adds [2]. [1]: https://github.com/NixOS/rfcs/pull/137/files#r1050542977 [2]: https://github.com/NixOS/rfcs/pull/137/files#r1050580213
as suggested by @piegamesde
1fc0711
to
9afffbe
Compare
This comment was marked as duplicate.
This comment was marked as duplicate.
as suggested by @infinisil and @kevincox
Co-authored-by: piegames <account+github@piegames.de>
This RFC is now open for shepherd nominations. (I think, if this is still intended to be a draft please mark as such) |
I'd like to nominate myself as a shepherd. We had a discussion at Nixcon, and these are the takeaway points we agreed on as I understand them (most are aligned with the current RFC text, although some adjustments will have to be made):
I am still not sure whether we want to go down the path of versioning the language, and if the benefits are worth the cost. But I am convinced that if we are going to, this is more or less how it will look like. |
So, thinking about the "When the set of values of a type is modified" case which is still missing. I see several different approaches to this:
I am in favor of option 1. until someone can convince me that this scenario actually has some desirable use cases. Otherwise, I simply don't see it being worth the effort handling (and it can always be specified later on when needed AFAICT). |
Thanks for the writeup. I almost entirely agree. One small thing about value changes. The nice things about these is that they aren't actually part of this decision but part of the actual changes in a language version. This means that we don't actually need to set any rules here because whether or not a value change is a good idea will be discussed at the time that the change is actually made. That being said I think it is almost certainly going to be a bad idea and don't expect to see literal value types change in the future. (See Python 3 str vs bytes vs unicode for an example.) There would have to be a pretty significant issue that needs addressing and there would need to be lots of care to ensure that it works well with most existing code. |
I've been asked to repeat my stance on this, which I've partially explained on this issue, and also in conversations with people. My two primary points are these:
As the maintainer of |
This RFC is now in discussion with the following shepherds: @piegamesde, @sterneseemann (lead), @gabriel-doriath-dohler. Thanks! |
as discussed with @roberth and @piegamesde Co-authored-by: Yorick van Pelt <yorick.vanpelt@tweag.io>
00c0a5d
to
3e27f3c
Compare
Updated the RFC text with what we discussed with @piegames and @roberth, based on #137 (comment). @tazjin – agreed that the Nix ecosystem has more acute issues than evolving the language, and that allowing for more moving parts will make the job of implementors harder. Certainly, many problematic patterns can be removed from plain sight through conventions. I disagree on the details though:
Clearly, implementing the RFC would be a significant undertaking, and at this point developing a prototype seems not to be worth the effort given both the expressed opposition to the proposal and other priorities. @alyssais noted on some other occasion that it would be reasonable if language implementors had some say in the language specification and evolution (on the merit of having put in the work and thereby being knowledgeable on the subject matter). @Ericson2314 repeatedly pointed out that more competition for implementation quality would benefit the ecosystem. Adding more requirements will certainly not make new evaluators cheaper, and having any specification at all (that is not "all Nixpkgs release branches should evaluate and produce the same store paths as the upstream evaluator of the day") should probably be considered before attempting to change that specification. In any case, I would surely want to have everyone on board who is as deeply involved with the language as Tvix developers, and I take your input very seriously. So thank you @tazjin and @sternenseemann for taking the time to work with us here. There is also something to be said about the needs of language users though, that is, Nix expression authors, especially the ever-growing number of beginners. Depending on the ecosystem's growth patterns, the scales may still tip in a way that make these particular longer-term considerations become economically viable to pursue further. I hope that the work done here is a useful exploration of both the problem and solution space that can be picked up in the future. For now I will put the RFC into draft mode. Shepherds, if you agree we can close it and add a concluding statement if mine is not enough. |
I'm fine with closing this RFC, however I see the need for some improvements around the Nix language and its versioning. Specifically, I'd like to see how far we can take our existing language versioning and deprecation infrastructure without having to introduce new per-file language syntax. This is an area that should be explored eventually. For example, I'd like to see more aggressive deprecation of language features that shouldn't be used in new code. |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
Introduce a convention to determine which version of the Nix language grammar to use for parsing and evaluating Nix expressions.
Add parameters to the Nix language evaluator, controlling the behavior of deprecation warnings and errors.
Design goals: avoid breaking existing code, prevent inadvertently breaking reproducibility, minimise maintenance burden for implementors and users.
Regardless, changes to the language, especially breaking changes, should remain a rare exception.
Rendered
Reviewers: Please add inline comments adding your arguments as suggestions, ideally one per comment. Resolving these conversations will keep the amount of foreground information tightly limited to what's still relevant.
Readers: No need to inspect closed comments, the considerations and conclusions there can be assumed to be part of the RFC text.
Please, do not add regular comments concerning contents! Otherwise we will lose track quickly.
Reserve regular comments for procedural issues, such as determining shepherds.
This work is sponsored by Antithesis ✨