Skip to content
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

riot-{web,desktop}: throw an error to use element-web #93774

Merged
merged 1 commit into from Jul 27, 2020

Conversation

Ma27
Copy link
Member

@Ma27 Ma27 commented Jul 24, 2020

Motivation for this change

For full migration, a compat-layer will be added to 20.03: #93773

Note: please wait with this until #93773 is merged!

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@worldofpeace
Copy link
Contributor

I really don't see why we have any need to make this a throw, that only makes sense if there's no equivalent package, and that would be element. tbh, all aliases should be like a lib.warn guiding people to use the new option like in mkRenamedOptionModule. Plus, these lists are not being reliably cleaned up before release.

I'm inclined to say we shouldn't change anything.

@Ma27
Copy link
Member Author

Ma27 commented Jul 27, 2020

@worldofpeace I'd like to avoid confusion by people who mistake riot with element. And in this case, it can be mostly fixed by a single s/riot/element/g. The entire application has been rebranded and some feature-flags were removed as those are available by default.

Plus, these lists are not being reliably cleaned up before release.

I'm well-aware that the current situation isn't perfect. However those aliases are usually prefixed with a comment mentioning the release where those can be dropped, so at least that's documented an no-one has to e.g. check all aliases in question manually.

@mguentner
Copy link
Contributor

For 20.03, I would say a warn is enough. It leaves the possibility open to postpone (manual) configuration changes until 20.09. It should be only s/riot/element/g but you never know.
For 20.09 the riot-* options should be removed completely.

@worldofpeace
Copy link
Contributor

For 20.03, I would say a warn is enough.

I believe using lib.warn here breaks evaluation. Might have to check the tracker for the previous case of that.

@Ma27
Copy link
Member Author

Ma27 commented Jul 27, 2020

It does, that's why I didn't do it for now.

@worldofpeace
Copy link
Contributor

@worldofpeace I'd like to avoid confusion by people who mistake riot with element. And in this case, it can be mostly fixed by a single s/riot/element/g. The entire application has been rebranded and some feature-flags were removed as those are available by default.

Interesting, I guess you could say a rebrand of an application that includes a name change is just on the fence of being a new application and not being a new application (where silently not being aware of the attribute change doesn't make sense). And I can see that, since lib.warn isn't an option (IIRC), throw is the next best thing.
With that explanation I can see why this is now needed 👍 Perhaps expand the commit message slightly to make it more evident? (if you feel like it 😁 ).

Copy link
Contributor

@worldofpeace worldofpeace left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See above comment

This approach has been discussed in NixOS#93774[1]. The application has been
completely rebranded and to avoid confusion, users should actively be
pointed to `element-*`.

[1] NixOS#93774 (comment)
@Ma27
Copy link
Member Author

Ma27 commented Jul 27, 2020

I updated the commit message and also referenced the discussion here.

@worldofpeace I've seen today that you also mentioned this issue in rfc#33. As I regularly take care of processes like this (and also do nixpkgs maintenance for a while now), I'd be happy to support establishing an improved deprecation process. Feel free to ping me in the relevant discussions if you think I might be helpful for that :)

@Ma27
Copy link
Member Author

Ma27 commented Jul 27, 2020

Approved by two contributors now and we came to the conclusion that the usage of a throw is currently the best option here, so I'll merge now.

@Ma27 Ma27 merged commit b1b06de into NixOS:master Jul 27, 2020
@Ma27 Ma27 deleted the riot-removal branch July 27, 2020 22:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants