Benjamin Bouvier
dd3cab9409
fix: don't try /context when a notification has been filtered out
2023-08-04 17:41:47 +02:00
Benjamin Bouvier
aea0b00ac2
chore: add comments to get_notification about the return type
2023-08-04 17:41:47 +02:00
Benjamin Bouvier
e1c928f121
fix: compute whether a room is a DM before joining it
...
If we were invited and joined a room, then the computation of is_direct() was happening after
joining, and depended on the presence of a global account event of type "m.direct". This event
is added by the "set_is_direct()" call thereafter, so this couldn't ever happen.
This fixes it by computing the is_direct field *before* joining the room, and then marking the
room as a DM based on that.
2023-08-04 17:41:47 +02:00
Benjamin Bouvier
7676ff509f
nit: remove else after return
2023-08-04 17:41:47 +02:00
Benjamin Bouvier
10f709450e
tests(notification): add integration tests for notification events
2023-08-04 17:41:47 +02:00
Jonas Platte
4ebc3d70ad
Hide test helpers from documentation
2023-08-03 21:39:56 +02:00
Jonas Platte
1679669376
Remove the 'testing' feature from matrix-sdk-ui
...
At the expense of slightly increasing our public API, but we can always
deprecate things.
2023-08-03 21:39:56 +02:00
Jonas Platte
edc6428e69
Fix clippy warnings
2023-08-03 21:39:56 +02:00
Kévin Commaille
a434b97c54
sdk: Don't derive (De)serialize for AuthSession
...
It turns out not all authentication API sessions (i.e. OIDC) are fully (de)serializable.
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-08-03 20:47:30 +02:00
Ivan Enderlin
6c0f24b657
chore: Update UniFFI fork
...
chore: Update UniFFI fork
2023-08-03 15:42:30 +02:00
Ivan Enderlin
2481e1f97e
chore: Update UniFFI fork.
2023-08-03 15:36:52 +02:00
Benjamin Bouvier
bf754667d9
chore: get rid of Client::inherit_session
...
It does the same as `restore_session` now. Thanks @zecakeh for finding this out!
2023-08-03 14:10:32 +02:00
Nicolas Mauri
61d4d5b096
Fix an arithmetic overflow
2023-08-02 18:25:35 +02:00
Jonas Platte
ea03b821fd
ffi: Use UniFFI fork with future cancellation support
...
Upstream PR: https://github.com/mozilla/uniffi-rs/pull/1684
2023-08-02 16:16:24 +02:00
Jonas Platte
f1b4b80460
ffi: Don't spawn tokio tasks for add_timeline_listener, send_attachment
2023-08-02 16:16:24 +02:00
Jonas Platte
b39d06353a
Revert "ffi: Spawn tokio tasks for the remaining async fns"
...
This reverts commit eb4dab138e .
2023-08-02 16:16:24 +02:00
Jonas Platte
34be01ecf2
Revert "ffi: Remove async from a few functions"
...
This reverts commit fc3883d08e .
2023-08-02 16:16:24 +02:00
Jonas Platte
0f6dd644b5
Upgrade async-rx
2023-08-01 17:31:29 +02:00
Jonas Platte
7d9d600eda
ui: Only lock TimelineInnerState once per back-pagination response
2023-08-01 17:31:29 +02:00
Jonas Platte
8ac0f099f6
ui: Exclude Debug implementation from coverage
2023-08-01 17:31:29 +02:00
Jonas Platte
640e5fbacf
ffi: Use batched timeline subscription
2023-08-01 17:31:29 +02:00
Jonas Platte
9a8c6249bb
ui: Add Timeline::subscribe_batched
2023-08-01 17:31:29 +02:00
Jonas Platte
a65cff01f7
ui: Create subscribe integration test sub-module
2023-08-01 17:31:29 +02:00
Benjamin Bouvier
80243615c4
chore(test): make the clear_with_echoes test more deterministic
2023-08-01 15:57:12 +02:00
Benjamin Bouvier
a6aaf164aa
chore(sliding sync): add logs for the limited flag computation
...
This should help us debug issues with false negatives.
2023-08-01 15:57:12 +02:00
Benjamin Bouvier
ace282126f
ffi(notifications): include full timeline event again in the NotificationEvent
...
The full timeline event contains both the timestamp (requested in #2361 ) and the sender id;
now the sender id for the invite can also be contained in there, minimizing the amount of copying we're doing in the
FFI code.
Fixes #2361 .
2023-08-01 15:09:18 +02:00
Nicolas Mauri
6961a7fb36
Fix is_user_mention_enabled and is_room_mention_enabled ( #2357 )
...
* Fix is_user_mention_enabled, is_room_mention_enabled
* Fix: XXX comments in UnitTests
* Update comments
* UnitTests: code refactoring
2023-08-01 14:43:32 +02:00
Jonas Platte
f6d4357d52
Update Cargo.lock
2023-08-01 10:59:40 +02:00
Jonas Platte
d05bd4bf2d
ui: Deduplicate in-reply-to fetching
2023-08-01 09:29:18 +02:00
Benjamin Bouvier
a00ff293f1
chore: apply code review suggestions again
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
505267503b
chore: add a comment explaining why we need a mutex
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
c6f00cb633
chore(clippy): use an async mutex
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
6cc4364684
chore: move comment around
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
d165ec8646
feat: sequentialize calls to get_notification_with_sliding_sync
...
There must be at most one sliding sync notification per connection id. While we could use multiple ids, it seems bad
to do so, in terms of proxy performance; so this makes it so that there is at most once notification being handled
at a time.
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
30a662fdc8
chore: slim down the enum variants of NotificationEvent according to popular request
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
9126937901
feat: use /context query if sliding sync failed
2023-07-31 15:02:04 +02:00
Benjamin Bouvier
dec5c6bc2d
feat(sliding sync): save the to-device token in OlmMachine::receive_sync_changes
2023-07-31 12:24:55 +02:00
Benjamin Bouvier
719683d284
feat: allow storing a next_batch_token in the crypto stores
2023-07-31 12:24:55 +02:00
Benjamin Bouvier
e3f7b9676d
chore: fix Changes::is_empty()
2023-07-31 12:24:55 +02:00
Benjamin Bouvier
745bb09e38
chore: remove unused token in KeysQueryRequest
2023-07-31 12:24:55 +02:00
Benjamin Bouvier
4c4a77da34
chore: group all the arguments to receive_sync_changes in a single struct
2023-07-31 12:24:55 +02:00
Jonas Platte
33629833bd
ui: Keep local echoes when clearing timeline
...
This is especially important for ones that failed to send (or ones that
fail post timeline clearing), since there is no way to retry them
otherwise.
2023-07-31 12:12:35 +02:00
Benjamin Bouvier
4c7e10cbf3
chore: add messages for base-client processing
2023-07-31 11:31:12 +02:00
Benjamin Bouvier
dcfea138ea
chore: tweak sliding sync tracing context
...
- include the conn_id at the stream level, not the sync_once level (that's a child scope of the stream)\
- also include whether e2ee is enabled at this level
- shorten most static logs
- remove duplicate "sending request" logs
2023-07-31 11:31:12 +02:00
Benjamin Bouvier
eb7e01e8b1
chore: lower log-levels when processing sliding sync in sdk-base
2023-07-31 11:31:12 +02:00
Damir Jelić
c22f6da909
Add a js feature to the qrcode crate
2023-07-31 10:08:53 +02:00
Damir Jelić
4eba72774f
Bump vodozemac
2023-07-31 10:08:53 +02:00
Jonas Platte
d149782e6a
ui: Reuse ID when replacing UTD after retrying decryption
2023-07-31 09:53:58 +02:00
Jonas Platte
0c3d46eb1e
ui: Move some functions into new timeline::util module
2023-07-31 09:53:58 +02:00
Jonas Platte
7dfe8cedbb
ui: Move timeline item creation helpers into TimelineInnerState
2023-07-31 09:53:58 +02:00