Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
MSC4026: Allow
/versions
to optionally accept authentication #4026MSC4026: Allow
/versions
to optionally accept authentication #4026Changes from all commits
7fb0734
fbda588
9e998a8
8373784
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While I don't object, in principle, to making
/versions
optionally accept authentication, I'm a bit concerned about the proposed usage. If the usage is only for experimental features, how would clients detect support for stable features? I'd expect that the answer to that would be through the/capabilities
endpoint which seems kind of strange to use two completely different endpoints to detect whether a client can do something. That means that when the client switches between unstable and stable implementations (or wants to support both), then it need to call two different endpoints.I'd be more in favour of relaxing the restriction on
/capabilities
and distinguishing between server support for a feature and whether a given client is allowed to make use of the feature:/capabilities
should not be used to indicate server support for an unstable feature (which should still be indicated using/versions
), but may be used to indicate whether a client can use it.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using
/capabilities
for the awkward accepted-but-not-merged state might be appropriate (though clients are already calling/versions
to determine feature support), but for truly stable (ie: merged) features I strongly prefer we don't have flags at all. Feature support is ultimately determined by the spec version.If the concern is the awkward accepted-but-not-merged state, I feel that spec releases happen often enough these days where we can stop saying things are stable upon FCP acceptance. In practice, both clients and servers are taking more than 1 release cycle to get any given release implemented anyways, so it does not feel like it's materially helping to have stable features so early in the process.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't this why it is important to have stable features before the spec version though? Since clients/servers aren't keeping up with the spec versions, but want to be able to use new features quickly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They don't appear to be using those new features earlier than release, or at least they can't if the support is 1 release cycle behind.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But the point of this MSC is for selectively enabling/disabling a feature for certain users, not about whether the server has any support for a feature, and it's not about stable-but-not-merged features.
If a feature is being selectively enabled for certain users while it is unstable, my assumption is that it will continue to offer that feature only to certain users after it is stable/merged. So clients will need some way of determining whether they have access to the feature. If they just look at
/versions
, they can see if the server supports the given spec version, and know whether the server supports the feature, but they'd need to find out whether they have access, presumably by asking/capabilities
. And if clients will be using/capabilities
in the stable version, then it seems strange to tell them to use something else in the unstable version.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yea, for that particular case an unstable and stable capability pairing would indeed be better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That was not the motivation behind this MSC TBH. The reason we want to selectively enable unstable features for certain users is so that we can test these unstable features with real accounts without risking other users finding it and relying on those features (i.e. we want to be able to enable stuff on matrix.org for certain users without risking the unstable features becoming "defacto stable").
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, OK. That makes sense. Thanks for the clarification.
Can this be clarified in the MSC as well? Maybe something like:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I have updated to reflect the suggestion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For clarity, nobody should walk away from this thinking that the correct solution is to not advertise any unstable features to unauthenticated users. Unstable features that affect clients before they are logged in, and older clients that will not know to authenticate to this endpoint, are still valid.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the feature is only enabled for certain users, it seems like the unauthenticated version should just indicate no support for the given feature.