You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
js-sdk respects invite_state but also expects a invite_room_state at the top level (sibling of unsigned) of an event for whatever reason which is obviously wrong.
The text was updated successfully, but these errors were encountered:
t3chguy
added
the
clarification
An area where the expected behaviour is understood, but the spec could do with being more explicit
label
Jun 18, 2021
richvdh
transferred this issue from matrix-org/matrix-spec-proposals
Mar 2, 2022
In v2, stripped invite state has moved to a field in the request body.
I think this all happened because Synapse does a bit of a hack to store stripped state that it receives from an invite over federation, storing it in the unsigned field of an event and then popping that field whenever it needs to return that event to a client or server. The only area it doesn't pop that field is when sending events to application services.
Regardless, it should be removed from the CS spec.
For some follow up here, it seems that the field is actually present for appservices, and it was decided in #1273 (comment) that an MSC should be created to move the fields from the CS API to the AS API.
Two areas of the spec doc talk about invite stripped state:
https://matrix.org/docs/spec/client_server/r0.6.1#m-room-member
invite_room_state
in the Unsigned of your ownm.room.member
eventand
https://matrix.org/docs/spec/client_server/r0.6.1#get-matrix-client-r0-sync
rooms.invite.<room_id>.invite_state
The stored event has the
invite_room_state
field but Synapse strips it when including the membership event ininvite_state
. https://github.com/matrix-org/synapse/blob/develop/synapse/rest/client/v2_alpha/sync.py#L326-L341The
/state
API doesn't work in Synapse pre-join so it seems like a client has no way to ever see ainvite_room_state
in the real world.js-sdk respects
invite_state
but also expects ainvite_room_state
at the top level (sibling of unsigned) of an event for whatever reason which is obviously wrong.The text was updated successfully, but these errors were encountered: