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

Sliding Sync timeline events and extensions #1054

Merged
merged 29 commits into from
Oct 25, 2022
Merged
Show file tree
Hide file tree
Changes from 26 commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
80d2dd5
feat(sliding-sync): Update to sliding-sync extension system
gnunicorn Sep 19, 2022
51c756e
feat: Adding support for e2ee, account-data and to-device-message ext…
gnunicorn Sep 19, 2022
e1f4e00
feat(sliding-sync): Extension configuration on the SlidingSync builder
gnunicorn Sep 19, 2022
7a9eec5
feat(sliding-sync): timeline event items support
gnunicorn Sep 19, 2022
37e4374
fix(sliding-sync): minor fixes for common extensions
gnunicorn Sep 19, 2022
a892e79
feat(sliding-sync): expose common extensions builder over ffi
gnunicorn Sep 19, 2022
ee15ef5
fix(sliding-sync): Update to latest ruma
gnunicorn Sep 20, 2022
97d66f7
fix(sliding-sync): proper e2ee encryption requests sending and handling
gnunicorn Sep 20, 2022
f763fad
fix(sliding-sync): process even if no room-data is present
gnunicorn Sep 21, 2022
2391093
fix(sliding-sync): switch to ruma 0.7.4
gnunicorn Sep 22, 2022
030b10c
fix: code simplification
gnunicorn Sep 22, 2022
cb191c9
fix: update styles, clippy and tests for api changes
gnunicorn Sep 22, 2022
5bd9ad9
test(crypto-js): `receive_sync_changes` has changed its signature.
Hywan Sep 22, 2022
8df3472
Merge remote-tracking branch 'origin/main' into ben-sliding-sync-exte…
gnunicorn Sep 22, 2022
3c86d44
Merge remote-tracking branch 'Hywan/pr/1054-errata' into ben-sliding-…
gnunicorn Sep 22, 2022
7e4e390
feat(jack-in): login and permanent storage support
gnunicorn Sep 27, 2022
3caf083
Merge remote-tracking branch 'origin/main' into ben-sliding-sync-exte…
gnunicorn Oct 12, 2022
87e641e
fix: post-merge error reverted
gnunicorn Oct 12, 2022
f77a66e
refactor: reuse to_device events preprocessing
gnunicorn Oct 12, 2022
38decab
feat(jack-in): runtime log configuration support via -l
gnunicorn Oct 13, 2022
a69fee3
Merge remote-tracking branch 'origin/main' into ben-sliding-sync-exte…
gnunicorn Oct 13, 2022
f8031e2
docs: fix CLI docs
gnunicorn Oct 13, 2022
be2bd63
Merge remote-tracking branch 'origin/main' into ben-sliding-sync-exte…
gnunicorn Oct 17, 2022
46ebc48
test(crypto): update to latest API
gnunicorn Oct 17, 2022
d2cd7c9
style(jack-in): fix minor formatting issues
gnunicorn Oct 17, 2022
b6d1429
style(jack-in): improve code quality
gnunicorn Oct 17, 2022
ea15c2e
fix(jack-in): file-logging feature builds again
gnunicorn Oct 20, 2022
9616653
Merge remote-tracking branch 'origin/main' into ben-sliding-sync-exte…
gnunicorn Oct 25, 2022
773b587
feat: Handle decrypted and deserialized timeline events in sliding sync
gnunicorn Oct 25, 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
109 changes: 109 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions bindings/matrix-sdk-crypto-ffi/src/machine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ impl OlmMachine {
key_counts: HashMap<String, i32>,
unused_fallback_keys: Option<Vec<String>>,
) -> Result<String, CryptoStoreError> {
let events: ToDevice = serde_json::from_str(events)?;
let to_device: ToDevice = serde_json::from_str(events)?;
let device_changes: RumaDeviceLists = device_changes.into();
let key_counts: BTreeMap<DeviceKeyAlgorithm, UInt> = key_counts
.into_iter()
Expand All @@ -436,7 +436,7 @@ impl OlmMachine {
unused_fallback_keys.map(|u| u.into_iter().map(DeviceKeyAlgorithm::from).collect());

let events = self.runtime.block_on(self.inner.receive_sync_changes(
events,
to_device.events,
&device_changes,
&key_counts,
unused_fallback_keys.as_deref(),
Expand Down
2 changes: 1 addition & 1 deletion bindings/matrix-sdk-crypto-ffi/src/responses.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ use ruma::{
},
},
message::send_message_event::v3::Response as RoomMessageResponse,
sync::sync_events::v3::DeviceLists as RumaDeviceLists,
sync::sync_events::DeviceLists as RumaDeviceLists,
to_device::send_event_to_device::v3::Response as ToDeviceResponse,
},
assign,
Expand Down
4 changes: 2 additions & 2 deletions bindings/matrix-sdk-crypto-js/src/sync_events.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use crate::{identifiers, js::downcast};
#[wasm_bindgen]
#[derive(Debug)]
pub struct DeviceLists {
pub(crate) inner: ruma::api::client::sync::sync_events::v3::DeviceLists,
pub(crate) inner: ruma::api::client::sync::sync_events::DeviceLists,
gnunicorn marked this conversation as resolved.
Show resolved Hide resolved
}

#[wasm_bindgen]
Expand All @@ -19,7 +19,7 @@ impl DeviceLists {
/// `changed` and `left` must be an array of `UserId`.
#[wasm_bindgen(constructor)]
pub fn new(changed: Option<Array>, left: Option<Array>) -> Result<DeviceLists, JsError> {
let mut inner = ruma::api::client::sync::sync_events::v3::DeviceLists::default();
let mut inner = ruma::api::client::sync::sync_events::DeviceLists::default();

inner.changed = changed
.unwrap_or_default()
Expand Down
Loading