Skip to content
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

MSC2676: Message editing #2676

Merged
merged 28 commits into from
Jul 18, 2022
Merged
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
8b95ffc
initial version of message editing proposal
uhoreg Jul 7, 2020
7f42c8b
fix MSC numbers
uhoreg Jul 7, 2020
5473009
Fix JSON in example
uhoreg Nov 24, 2020
e44f566
clarifications
uhoreg Jun 2, 2021
634dc2e
remove obsolete "XXX:", and fix a typo
uhoreg Oct 28, 2021
f9768e7
Initial cleanup and restructuring
richvdh Apr 12, 2022
1de6c11
Clarify algorithm for replacing content
richvdh Apr 12, 2022
adcdddc
background
richvdh Apr 12, 2022
fc2a690
More clarifications on applying edits
richvdh Apr 12, 2022
80c467b
Clarify behaviour of redactions
richvdh Apr 12, 2022
6cea76a
Minor grammar fixes
richvdh May 17, 2022
dac2399
Move the section on `msgtype` down
richvdh May 17, 2022
b8a7745
Clarify how edits are ordered
richvdh May 17, 2022
79a362e
Spec the behaviour for encrypted events
richvdh May 17, 2022
bb96694
Requirements for an edit event to be considered valid
richvdh May 17, 2022
dd1ca71
Collect "client behaviour" and "sever behaviour" together
richvdh May 17, 2022
eba4753
Clarify permalinks section
richvdh May 17, 2022
78550a2
Notes on edits of replies
richvdh May 17, 2022
e58715c
Clarify that `m.relates_to` within `m.new_content` is ignored
richvdh May 19, 2022
4c77c01
Clarifications from review
richvdh Jun 28, 2022
1850fb5
event ids are sorted lexicographically
richvdh Jun 28, 2022
c9e6652
Clarify aggregation section
richvdh Jun 28, 2022
1e63094
minor clarifications
richvdh Jul 12, 2022
2373873
Clarify which endpoints support edits
richvdh Jul 12, 2022
8ec4cf3
move definition of latest edit
richvdh Jul 12, 2022
08489e8
Apply suggestions from code review
richvdh Jul 13, 2022
f3d328d
fix typo
richvdh Jul 13, 2022
b245761
Attempt to clarify encrypted events
richvdh Jul 13, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Clarify that m.relates_to within m.new_content is ignored
  • Loading branch information
richvdh committed May 19, 2022
commit e58715cfa7e940e58dcd4ecde08283db02f9ee85
5 changes: 4 additions & 1 deletion proposals/2676-message-editing.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,10 @@ example, an encrypted replacement event might look like this:

When applying a replacement, the `content` property of the original event is
Copy link
Contributor

@benkuly benkuly Jul 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When the original content is replaced, what happens, when the edit is deleted? Where does the original content come from, when it already has been replaced? Wouldn't it be more consistent to keep the original content and the client just uses the aggregation for the latest content?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. please see the background: we are not in the business of making significant changes to the design as part of this MSC.
  2. what do you mean by "when the edit is deleted" ? Why would it be deleted? The matrix protocol does not support deleting events.

Copy link
Contributor

@benkuly benkuly Jul 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. I don't think that my opinion will change anything, but to cite this MSC "Hopefully, processes have improved over the last three years". I don't think that merging an immature MSC just because Element does implement it is an "improvement". Element should implement the matrix spec and not the matrix spec should specify Elements implementation ;)
  2. I meant redacted. According to this MSC, events with rel_type of m.replace can be redacted. Therefore you first have event1 with content1, then with an edit you have event1 with content2 (from event2) and with a redaction of event2 you should have event1 with content1.

The section "Applying m.new_content" is from my viewpoint of a SDK developer far more complicated then it needs to be.

replaced entirely by the `m.new_content`, with the exception of `m.relates_to`,
which is left *unchanged*. For example, given a pair of events:
which is left *unchanged*. Any `m.relates_to` property within `m.new_content`
is ignored.

For example, given a pair of events:

```json
{
Expand Down