-
Notifications
You must be signed in to change notification settings - Fork 362
feat: Add forwarder: ForwarderInfo to EncryptionInfo.
#5945
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
Conversation
ae1d3b3 to
b99aba0
Compare
CodSpeed Performance ReportMerging #5945 will not alter performanceComparing Summary
|
b99aba0 to
78a9811
Compare
c26b078 to
040681b
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #5945 +/- ##
=======================================
Coverage 88.58% 88.59%
=======================================
Files 364 364
Lines 104323 104341 +18
Branches 104323 104341 +18
=======================================
+ Hits 92412 92437 +25
+ Misses 7546 7538 -8
- Partials 4365 4366 +1 ☔ View full report in Codecov by Sentry. |
b58ef8d to
04f17ae
Compare
04f17ae to
abc80ff
Compare
andybalaam
left a comment
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.
Nice, thanks. A couple of minor questions and comments.
| /// The device ID of the device that sent us the event, note this is | ||
| /// untrusted data unless `verification_state` is `Verified` as well. | ||
| pub sender_device: Option<OwnedDeviceId>, | ||
| /// If the keys for this message shared-on-invite as part of an |
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.
| /// If the keys for this message shared-on-invite as part of an | |
| /// If the keys for this message were shared-on-invite as part of an |
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.
Addressed in 0ee914e
| /// sent. | ||
| /// | ||
| /// [MSC4268]: https://github.com/matrix-org/matrix-spec-proposals/pull/4268 | ||
| pub forwarder_device: Option<OwnedDeviceId>, |
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.
I think I would prefer a single Option that contains a struct containing these 2 values, since it sounds like they will both be either None or Some in lockstep. I am persuadable though.
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.
Changed in #5980
| known_sender_data.device_id.clone() | ||
| } | ||
| _ => { | ||
| // TODO: Should this return an error? |
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.
I don't know. Should this never happen? If so, printing and continuing is probably OK. I think it should be an error rather than a warning though, if we're confident it shouldn't happen.
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 new changes in #5980 let us avoid this, but we still have some optional chaining shenanigans to get around KnownSenderData::device_id being Optional for backwards compatibility.
a9d9036 to
0ee914e
Compare
forwarder and forwarder_device to EncryptionInfo.forwarder: ForwarderInfo to EncryptionInfo.
andybalaam
left a comment
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.
Great, thanks!
0904b0d to
b85fc0d
Compare
Depends on #5943, #5980