Reorganize event structure in c2s spec and clarify event capabilities

Fixes https://github.com/matrix-org/matrix-doc/issues/1166
Fixes https://github.com/matrix-org/matrix-doc/issues/1527
Fixes https://github.com/matrix-org/matrix-doc/issues/1827

Note: In order to fix the "state events have the following fields: [no words]" bug (1827) we need to resolve references on common event types. When doing this we ultimately end up with more fields than may be required to explain the section, however this commit alters the section descriptions to just say "these fields" instead of "these additional fields".

This is also preferable over trying to get the inheritance reversed in the common event types, as the `/sync` endpoint has a high amount of reliance on partial events definitions.
This commit is contained in:
Travis Ralston 2019-06-05 22:55:11 -06:00
parent 9ac89cc915
commit 8fd5b15594
8 changed files with 66 additions and 78 deletions

View file

@ -748,6 +748,7 @@ class MatrixUnits(Units):
with open(filepath, encoding="utf-8") as f:
event_schema = yaml.load(f, OrderedLoader)
event_schema = resolve_references(filepath, event_schema)
schema_info = process_data_type(
event_schema,