Conversation
MSC4140 schedules delayed events with
`PUT /rooms/{roomId}/delayed_event/{eventType}/{txnId}`, taking `delay_ms`,
`content` and, for state events, `state_key` in the body. Scheduling
through the `org.matrix.msc4140.delay` query parameter on `/send` and
`/state` is now one of the MSC's rejected alternatives.
Schedule every delayed event through the unstable form of the endpoint,
giving state events a transaction ID of their own. The existing
"same txnID" subtest now checks that the endpoint is transactional, and
the state event tests check that a state event scheduled through it
lands as room state. A new test checks that a missing, zero or negative
`delay_ms` is rejected with a 400.
One test still schedules a message event and a state event through the
query parameter, so that form stays covered until homeservers drop it.
Signed-off-by: Paul Chobert <paul@chobert.fr>
MSC4140 lists scheduling delayed events through the `org.matrix.msc4140.delay` query parameter on `/send` and `/state` as a rejected alternative to the dedicated endpoint, so it is not part of the MSC to test for. Remove the test that still used it, along with the `getPathForSend` and `getDelayQueryParam` helpers only it needed. Signed-off-by: Paul Chobert <paul@chobert.fr>
12 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This is a sister PR to element-hq/synapse#19354
MSC4140 schedules delayed events with
PUT /rooms/{roomId}/delayed_event/{eventType}/{txnId}, takingdelay_ms,contentand, for state events,state_keyin the body. The tests intests/msc4140schedule delayed events with theorg.matrix.msc4140.delayquery parameter on/sendand/state, which the MSC now lists as a rejected alternative.This PR:
PUT /_matrix/client/unstable/org.matrix.msc4140/rooms/{roomId}/delayed_event/{eventType}/{txnId}, and drops the query parameter formtxnIdgives back the samedelay_iddelay_msis rejected with a 400Signed-off-by: Paul Chobert paul@chobert.fr