-
Notifications
You must be signed in to change notification settings - Fork 386
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
Fix client-server event schemas: move age
, dedupe fields
#1558
Fix client-server event schemas: move age
, dedupe fields
#1558
Conversation
This commit adds support for event schema examples to have references to help reduce the chance of fields being forgotten. This also helps reduce duplication of fields, allowing for a more consistent spec that uses the same values everywhere. This also removes both `unsigned` and `age` from the examples as per: * matrix-org#1524 * matrix-org#630 Finally, this replaces "localhost" in the examples with an example domain. This is really just a nitpick thing on my part where seeing a "real world" domain is preferred. Fixes matrix-org#1524 Fixes matrix-org#630 Step towards https://github.com/matrix-org/matrix-doc/issues/1530
hm, is this just removing age from the examples? or from the schema itself? as |
From the examples. I'll double check the schemas and make sure the age appears for the call event stuff. |
i am still a bit confused about this - in practice, a compliant server is going to show an |
This is useful for a lot of things, like bridges (appservices), VoIP handling, and clients which generally may wish to do something with the field. Might as well include it on every event, despite the recommendation of matrix-org#1524
age
, dedupe fieldsage
, dedupe fields
I've gone ahead and just added the This is primarily because application services (particularly bridges) have a very good reason to look at this field, alongside clients which do VoIP. It's worth noting that it is not a required field, however it is something that should be provided. |
Fixes #1294 |
Otherwise the script will try to find a schema for our templates, which don't exist.
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.
lgtm other than one nit
"content": { | ||
"membership": "invite", | ||
"avatar_url": "mxc://localhost/SEsfnsuifSDFSSEF#auto", | ||
"avatar_url": "mxc://domain.com/SEsfnsuifSDFSSEF#auto", | ||
"displayname": "Alice Margatroid" | ||
}, | ||
"unsigned": { |
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.
the unsigned.age
field gets lost here, which I'm guessing was not intentional
Rendered: see 'docs' status check
Edit: Halfway through this PR the
age
field changed from being "removed" to just "moved" underunsigned
.This commit adds support for event schema examples to have references to help reduce the chance of fields being forgotten. This also helps reduce duplication of fields, allowing for a more consistent spec that uses the same values everywhere.
This also removes both
unsigned
andage
from the examples as per:Finally, this replaces "localhost" in the examples with an example domain. This is really just a nitpick thing on my part where seeing a "real world" domain is preferred.
Fixes #1524
Fixes #630
Step towards https://github.com/matrix-org/matrix-doc/issues/1530